title: Which data structure in Java should I use for storing key value pairs in ordered form? No duplicates
body: <p>I am working on a project and I need to store key value pairs (one-to-one mapping) in an ordered fashion. Then I should be able to retrieve the key using the value and value using the key. I have looked at Maps, Sets and Hash Tables, but they aren't ordered.</p>
  
  <p>Also, though trivial, it would be great if we could DS retrieve the keys and values at once i.e., the interface supports such functions.</p>
  
  <p>EDIT: The keys and values are all unique. Maintaining the inserted order is good enough.</p>