I have the follow classes:
public abstract class MyAbstractClass {
     protected int x;
     protected int number;
     public MyAbstractClass(int x) {
         this.x = x;
         this.number = this.generateNumber();
     }
     public abstract int generateNumber(); // This class is called in the super constructor and elsewhere
}
public class MySubClass extends MyAbstractClass {
     private int y;
     public MySubClass(int x, int y) {
          super(x);
          this.y = y;
     }
     @Override
     public int generateNumber() {
         return this.x + this.y; // this.y has not been initialized!
     }
}
My issue is that MySubClass's y property has to be initialized before the super constructor is run, because a method using y is run in the super constructor.
I am aware that this may not be possible even with some sneaky workaround, but I am yet to find an alternative solution.
Also please keep in mind that I will have many more derived classes, with different values being passed into their constructors.
 
     
    