title: What is best practice for serializing Java enums to XML?
body: <p>Hi I have a Java enum and I want serialize a variable containing an enum value back and forth from XML for persistence.  My enum is defined like this...</p>
  
  <pre><code>public enum e_Type
  {
      e_Unknown,
      e_Categoric,
      e_Numeric
  }
  </code></pre>
  
  <p>My variable is declared like this...</p>
  
  <pre><code>private e_Type type;
  </code></pre>
  
  <p>I want it to go into an XML tag like this...</p>
  
  <pre><code>&lt;type&gt;value&lt;/type&gt;
  </code></pre>
  
  <p>What's the best practice for persisting values of enums in XML?</p>