Java Enums: Implementing methods After Declaration?
<p>Consider the simple example below of implementing a method in an Enum.  One problem with this method is that, when you have a lot of enum instances, you visually can no longer see them all at once, as a list.  That is, if we had many toys, I would like to see "DOLL, SOLDIER, TEDDYBEAR, TRAIN, ETC", together, in one long list, and then after that list I could implement any needed methods, e.g. methods that are abstract in the enum itself.</p>

<p>Is there any way to do this?  Or do you have to implement the methods when you declare the individual enum instances, as in the example below?</p>

<pre class="lang-java prettyprint-override"><code>public enum Toy {
     DOLL() {
          @Override public void execute() { 
               System.out.println("I'm a doll."); 
          }
     },
     SOLDIER() {
          @Override public void execute() { 
               System.out.println("I'm a soldier."); 
          }
     };
     //abstract method
     public abstract void execute();
}
</code></pre>
