How can I Identify Elements in Objects?
There is a complete science behind your question called Analytical Chemistry. However the goal is not to identify what a given object is made of, people usually look for targeted compounds or elements of interest. Take chocolate for example, there are thousands of compounds there. Analyzing it completely from scratch may take more than a year! There you will learn plenty of techniques to identify elements. If you just wish to know what this glass is made of, one may use a technique called X-ray fluorescence, it is good for quickly detecting most of the elements except the lighter ones.