title: Using a HashMap as a Key for another HashMap
body: <p>I have a requirement where I need to map a set of configurations with a set of values, ideally denoted by a <code>Map&lt;Map&lt;String, Object&gt;, Map&lt;String, Object&gt;&gt;</code> structure.</p>
  
  <p>Both the configurations &amp; the values part of the main Map are arbitrary &amp; hence, I am unable to use a concrete class.</p>
  
  <p>Please provide some feedback on this structure. Can a Map be used as a key for another Map. Doing a bit of research, I was able to establish that the Map's equals method utilizes all underlying Keys &amp; Values to deem two Maps as equal. Also, the HashCode of a Map is based on the Hashcodes of the Map's Keys. This IMO should suffice the minimum requirements of using a Map as a key.</p>
  
  <p>I would still like someone to validate this before I go ahead with the implementation. In case there is a better solution / design that someone can suggest, please feel free to do so.</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I ended up using a simple tilde ('~') &amp; pipe ('|') separated String as the key &amp; deconstructed it whenever needed. Thanks to all who helped.</p>