title: Java Enum linking to another Enum
body: <p>I would like to have enumerator in Java having other enum as attribute.</p>
  
  <pre><code>public enum Direction {
      Up(Down),
      Down(Up),
      Left(Right),
      Right(Left);
  
      private Direction opposite;
  
      Direction(Direction opposite){
          this.opposite = opposite;
      }
  }
  </code></pre>
  
  <p>So I have different Direction, and for each I want to know the opposite.
  It is working fine for Down and Right, but I can't initialize Up because Down is not known yet (same fort Left).</p>
  
  <p>How can I edit enum variables after initialisation ?</p>