I want to store certain objects in a HashMap. The problem is, usually you just use a single object as a key. (You can, for example, use a String.) What I want to do it to us
You could create a holder class that contains the class and string that you want as the keys.
public class Key { public MyClass key_class; public String key_string; public Key(){ key_class = new MyClass(); key_string = ""; } }
Probably not the best solution, but a possibility.