title: When to use enum in java?
body: <p>I have approximately 30 resources each having approximately 10 attributes. I want to store some information about each attribute. </p>
  
  <p>Example: </p>
  
  <ul>
  <li>It's multiplicity</li>
  <li>It RW (Read/Write) RO (Read only)</li>
  <li>longName</li>
  <li>shortname</li>
  </ul>
  
  <p>So I was thinking of storing it in a Enum like this:</p>
  
  <pre><code>public enum Attributes {
  
      U_RESOURCETYPE(true, "RW", "resourceType", "rt"),
      U_RESOURCEID(false, "RO", "resourceID","ri"),
      //...
  }
  </code></pre>
  
  <p>But this lead to 300 constants (30 resources * 10 attributes).</p>
  
  <p>I could also use a config file or a Singleton Enum with a Map as member.</p>
  
  <p>What is the best possible way to achieve this?</p>