I'm working on a Java EE project, but there are methods which return a List of interfaces. Don't know the purpose for this or if it is a bad practice. Tried to look for list of interfaces but all the information appears like interface List.
public List<SomeInterfaceRO> getAttribute() {
return (List<SomeInterfaceRO>)someInterfaceBO
}
public interface SomeInterfaceRO {
public String getName();
public String getComment();
// More methods ...
}
The someInterfaceBO is a Java class which implements that interface.