The question has mostly to do with how inheritance and extension works.
I currently have the following:
public class Client extends BaseClient { ... }
and
public class BaseClient extends MinimalisticClient { ... }
The main difference between them is the amount of parameters (data) they hold (fetched from a database).
What I want to do is create an interface for each individual one that would contain only the getters.
so, it would be something like:
public interface IMinimalisticClient { getters }
public class MinimalisticClient implements IMinimalisticClient { ... }
public interface IBaseClient extends IMinimalisticClient { the extra getters }
public class BaseClient extends MinimalisticClient implements IBaseClient { ... }
public interface IClient extends IBaseClient { the extra extra getters }
public class Client extends BaseClient implements IClient { ... }
Taking BaseClient as an example. When I extent MinimalisticClient, I implement the IMinimalisticClient into BaseClient by default. But then, I also implement IBaseClient which extends IMinimalisticClient as well. Is this acceptable? Am I doing something completely stupid?
Just as a mention, I am doing the way I presented it only because the software will run on cheap android devices and I have to manage the memory usage as much as possible.