Class relationships: Correct Solution


Consider the follow class declarations:

public class Bloosfor extends Ziogloss {
    public int getIbza() {
        ...
    }
}

public class Chiang {
    public List<JalUmor> getErwals() {
        ...
    }

    public List<Bloosfor> getAstes() {
        ...
    }
}

public class EiaAsm extends WeoLau {
    public Pror getEsMe() {
        ...
    }
}

public class JalUmor {
    public File getCaEp() {
        ...
    }
}

public class Montpesm {
    public byte[] getSolba() {
        ...
    }
}

public class Pror {
    public Montpesm getAnto() {
        ...
    }

    public File getAdEron() {
        ...
    }
}

public class WeoLau {
    public int getPra() {
        ...
    }

    public int getIsiss() {
        ...
    }
}

public class Ziogloss {
    public int getIdi() {
        ...
    }

    public EiaAsm getEador() {
        ...
    }
}
  1. Draw a diagram showing the class relationships.

    You only need to diagram the classes listed above. You only need to show the name of each class; do not show their methods or properties.

    Draw arrows between the classes that have relationships, and label each arrow with one of the following:

    Make sure your arrows point in the correct direction!

    Solution

  2. Given the following variable:

    Chiang vi

    ...and the following method:

    public void process(int item)

    ...write code to process the isiss of each aste of vi.

    Solution

    process(vi.getAstes().get(0).getZiogloss().getEador().getWeoLau().getIsiss());

Related puzzles: