title: How to call a different constructor conditionally in Java?
body: <p>Let's say someone gives you a class, <code>Super</code>, with the following constructors:</p>
  
  <pre><code>public class Super
  {
      public Super();
      public Super(int arg);
      public Super(String arg);
      public Super(int[] arg);
  }
  </code></pre>
  
  <p>And let's say you want to create a subclass <code>Derived</code>. How do you conditionally call a constructor in <code>Super</code>?</p>
  
  <p>In other words, what is the "proper" way to make something like this work?</p>
  
  <pre><code>public class Derived extends Super
  {
      public Derived(int arg)
      {
          if (some_condition_1)
              super();
          else if (some_condition_2)
              super("Hi!");
          else if (some_condition_3)
              super(new int[] { 5 });
          else
              super(arg);
      }
  }
  </code></pre>