说我有这个代码 -
public interface ParentInterface1 {
public List<? extends ChildInterface1> getChildren();
public void setChildren(List<? extends ChildInterface1> children);
}
public interface ParentInterface2 {
public List<? extends ChildInterface2> getChildren();
public void setChildren(List<? extends ChildInterface2> children);
}
public interface ChildInterface1 {
public String getField();
public void setField(String field);
}
public interface ChildInterface2 {
public String getField();
public void setField(String field);
}
public class LParentImpl implements ParentInterface1, ParentInterface2 {
private List<ChildImpl> list;
public List<ChildImpl> getChildren() {
return list;
}
public void setChildren(List<... wants to …Run Code Online (Sandbox Code Playgroud)