Constructor in Inheritance something goes wrong : <p>I am doing something wrong on constructor what it is.I cant understand.I know you may not understand the code because is another language.I have done an abstract class Metafores and subclasses,Aerio,Meikto,Stereo.Please check my code i have done something wrong on my constructors but i dont know what it is.How should it be?</p>

<pre><code>    package eksetash1;


    public class Aerio extends Metafores {
        private int SyskeuasiasAeriou;

         public Aerio(){

        }
        public Aerio(int SyskeuasiaAeriou,int gettyposProiontos,int gettyposMetaforas,int gettyposMetrisis,String getonomaProiontos,double gettimiMonadas){
            super(gettyposProiontos,gettyposMetaforas,gettyposMetrisis,getonomaProiontos,gettimiMonadas);
            this.SyskeuasiasAeriou=SyskeuasiasAeriou;
        }

        @Override
        int gettyposProiontos() {
            return 3;
        }
    @Override
        int gettyposMetaforas() {
            return 0;
        }
        @Override
       int gettyposMetrisis(){
           return 0;
       }


      @Override
       double gettimiMonadas(){
           return 0;
       }
       @Override
       String getonomaProiontos(){
           return  null;
       }
    } //end 

    package eksetash1;


    public class Eksetash1 {
     static int N; //apo to plhktrologio
     static String Typos;
        public static void main(String[] args) {

       Metafores[] pin = new Metafores[N];
        for (int i = 0; i &lt; 10; i++) {
            pin[i] = new Stereo();
            pin[i+10] = new Ygro();
            pin[i+20] = new Aerio();
            pin[i+30]=new Meikto();
        }


        // exceptions
        System.out.println("An einai Ygro,aeria,meiktou barous tha exoume eksairesh-grapste analoga");
                  if ((Typos = UserInput.getString()).equalsIgnoreCase("Ygro"))  {
            throw new IllegalExceptionMetaforas("Ta ygra dn metaferontai me aeroplano ");

       }
    System.out.println("An einai aeria tha exoume eksairesh");
         if ((Typos = UserInput.getString()).equalsIgnoreCase("aeria"))  {
            throw new IllegalExceptionMetaforas("Ta aeria dn metaferontai me to aeroplano");

       }
         System.out.println("An einai meiktou barous");
         if ((Typos = UserInput.getString()).equalsIgnoreCase("meiktou barous"))  {
            throw new IllegalExceptionMetaforas("Meiktou barous dn metaferontai me to aeroplano");

       }
    }
        }//end main


    package eksetash1;

    //class exception
    public class IllegalExceptionMetaforas extends RuntimeException{
        public  IllegalExceptionMetaforas (String s){
                          super(s);
    }
    }//end exception illegal

    package eksetash1;

    //another class Meikto
    public class Meikto extends Metafores {

        private String perigrafhSyskeuasias;
         public Meikto(){

        }
//constructor 
        public Meikto(String perigrafhSyskeuasias,int gettyposProiontos,int gettyposMetaforas,int gettyposMetrisis,String getonomaProiontos,double gettimiMonadas){
            super(gettyposProiontos,gettyposMetaforas,gettyposMetrisis,getonomaProiontos,gettimiMonadas);
            this.perigrafhSyskeuasias=perigrafhSyskeuasias;
        }

        @Override
        int gettyposProiontos() {
            return 4;
        }
    @Override
        int gettyposMetaforas() {
            return 0;
        }
        @Override
       int gettyposMetrisis(){
           return 0;
       }


      @Override
       double gettimiMonadas(){
           return 0;
       }
       @Override
       String getonomaProiontos(){
           return perigrafhSyskeuasias ;
       }
    }
    //end
    package eksetash1;

    // class Stereo
    public class Stereo extends Metafores {
    private String perigrafhYlikou;

        public Stereo(){

        }
// consructor
        public Stereo(String perigrafhYlikou,int gettyposProiontos,int gettyposMetaforas,int gettyposMetrisis,String getonomaProiontos,double gettimiMonadas){
            super(gettyposProiontos,gettyposMetaforas,gettyposMetrisis,getonomaProiontos,gettimiMonadas);
            this.perigrafhYlikou=perigrafhYlikou;
        }
        public void settyposProiontos(String typos){
            typos=typos;
        }


        @Override
        int gettyposProiontos() {
            return 1;
        }

    @Override
        int gettyposMetaforas() {
            return 0;
        }
        @Override
       int gettyposMetrisis(){
           return 0;
       }


      @Override
       double gettimiMonadas(){
           return 0;
       }
       @Override
       String getonomaProiontos(){
           return perigrafhYlikou;
       }

    } //end stereo

    //abstract class Metafores
    package eksetash1;


    public abstract class Metafores {
       abstract int gettyposProiontos();
       abstract int gettyposMetaforas();
      abstract int gettyposMetrisis();
       abstract String getonomaProiontos();
      abstract double gettimiMonadas();
      static String Typos;
       public Metafores(){

       }

//constructor

       public Metafores(int gettyposProiontos,int gettyposMetaforas,int gettyposMetrisis,int getonomaProiontos,double gettimiMonadas){

       }

       public void getTyposProiontos(){
           System.out.println("Grapste Stereo");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Stereo")) {

                Stero.settyposProiontos(1);
               Stereo.gettyposProiontos(1);//stereo=1 
       }
             System.out.println("Grapste Ygro");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Ygro")) {
                Ygro.settyposProiontos(2);
                Ygro.gettyposProiontos(2);//ygro=2
       }
             System.out.println("Grapste Aerio");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Aerio")) {
                Aerio.settyposPriontos(3);
                Aerio.gettyposProiontos(3);//aerio=3 
       } System.out.println("Grapste Meikto");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Meikto")) {
                Meikto.settyposProiontos(4);
                Meikto.gettyposProiontos(4);//meikto=4 
       }

    }
       public void getTyposMetaforas(){
           System.out.println("Grapste Stereo");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Stereo")) {

                Stero.settyposMetaforas();
               Stereo.gettyposMetaforas();
       }
             System.out.println("Grapste Ygro");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Ygro")) {
                Ygro.settyposMetaforas();
                Ygro.gettyposMetaforas();
       }
             System.out.println("Grapste Aerio");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Aerio")) {
                Aerio.settyposMetaforas(3);
                Aerio.gettyposMetaforas(3);
       } System.out.println("Grapste Meikto");
            if ((Typos = UserInput.getString()).equalsIgnoreCase("Meikto")) {
                Meikto.settyposMetaforas(4);
                Meikto.gettyposProiontos(4);
       }
       }

    }
</code></pre>
