I know that Java does not allow us to extend more than one class. I know that interfaces also exist and I don\'t want to use them this time. Is there some kind of trick or w
To avoid diamond problem Java does not support Multiple Inheritance through classes but it supports using interfaces.
So you may use Association Relationship. e.g.
Class A {}
Class B {}
Class C implements SomeInterface {
A a;
B b;
// setter getter for a and b and other methods
}