title: Can I add and remove elements of enumeration at runtime in Java
body: <p>It is possible to add and remove elements from an enum in Java at runtime?</p>
  
  <p>For example, could I read in the labels and constructor arguments of an enum from a file?</p>
  
  <hr>
  
  <p>@saua, it's just a question of whether it can be done out of interest really. I was hoping there'd be some neat way of altering the running bytecode, maybe using <a href="http://bcel.sourceforge.net/" rel="noreferrer">BCEL</a> or something. I've also followed up with <a href="https://stackoverflow.com/questions/481068/when-to-use-enum-or-collection-in-java">this question</a> because I realised I wasn't totally sure when an enum should be used.</p>
  
  <p>I'm pretty convinced that the right answer would be to use a collection that ensured uniqueness instead of an enum if I want to be able to alter the contents safely at runtime.</p>