I have this class (let's call it A) and an inherited class (B), and I would like to create a constructor for B using an instance of A, something like :
public B(A a){
super = a;
...
}
Obviously the above code does not work, but is there a way to do it? I could create another instance of A with the same values for each field, but that seems really useless since I already have one, and I just need to add a few fields to make it of class B.