Lets say I have class
public class ParentClass {
private String field1;
private String field2;
private String field3;
private List<AnotherParentPojo> evses;
}
public class AnotherChildPojo extends AnotherParentPojo {
private String fieldA;
private String fieldB;
private String fieldC;
}
public class ChildClass extends ParentClass {
private List<AnotherChildPojo> evses;
}
However this leads to the error "both methods have same erasure, yet neither overrides the other" in the ChildClass. I am aware its not possible to override a field but is there any way to achieve this without having to change ParentClass or AnotherParentPojo? I only have control over the ChildClass and AnotherChildPojo