public abstract class AbstractAlbum implements Album {
protected final String id;
+ protected final String parentId;
protected String title;
protected String description;
protected String albumImage;
- protected AbstractAlbum(String id) {
+ protected AbstractAlbum(String id, String parentId) {
this.id = checkNotNull(id, "id must not be null");
+ this.parentId = parentId;
}
@Override
@Override
public boolean isRoot() {
- return getParent() == null;
+ return parentId == null;
}
@Override