How to correctly use HashMap?
HashMap<String, Object> savedStuff = new HashMap<String, Object>();
Of course, you will still have to be careful to use the right type when extracting elements.
You need to use generics as shown below :
Map<String, Object> savedStuff = new HashMap<String, Object>();