title: java copy constructor and inheritance
body: <p>After some searching I didn't found any good answer to my question regarding copy constructor and inheritance.
  I have two classes: User and Trainee. Trainee inherits from User and two String parameters are added to Trainee.
  Now I managed to make a copy constructor of User but I am not satisfied with my copy constructor of Trainee.
  The code of the User copy constructor is like this:</p>
  
  <pre><code>public User (User clone) {
      this(clone.getId(), 
           clone.getCivilite(),
           clone.getNom(), 
           clone.getPrenom(), 
           clone.getEmail(), 
           clone.getLogin(), 
           clone.getTel(), 
           clone.getPortable(), 
           clone.getInscription(), 
           clone.getPw()
      );
  }
  </code></pre>
  
  <p>I tried to use super in my Trainee copy constructor:</p>
  
  <pre><code>public Trainee (Trainee clone) {
      super (clone);
      this (clone.getOsia(), clone.getDateNaiss());
  }
  </code></pre>
  
  <p>But it didn't work and I was forced to code a full version of the copy constructor:</p>
  
  <pre><code>public Trainee (Trainee clone) {
      this(clone.getId(), 
           clone.getCivilite(),
           clone.getNom(),
           clone.getPrenom(), 
           clone.getEmail(), 
           clone.getLogin(), 
           clone.getTel(), 
           clone.getPortable(), 
           clone.getInscription(), 
           clone.getPw(), 
           clone.getOsia(), 
           clone.getDateNaiss()
      );
  }
  </code></pre>
  
  <p>Because of the construction of my main I have to cast my new instance like this:</p>
  
  <pre><code>  User train = new Trainee();
    User train2 = new Trainee((Trainee) train);
  </code></pre>
  
  <p>So my question is: Is there a cleaner way to do this? Can't I use a super?</p>
  
  <p>Thank you in advance for your answers and assistance.</p>