Differents kind of classes inherit from an abstract class in android java -


I have two classes (class A and classbie), which should be ListFragment. They share the behavior of the two classes, thus I have created an abstract class (Eberclass). Then inherit from abstractclass ListFragment. So far, I have my class A and Classbie, which are received from my architecture class which are received from the listfrag. The problem occurs when I need any other class that should not be a fragragment, but it also requires behavior from Abstracts, but I can get the inheritance from it because classics should be fragmented only and My abstract list is listed. I want to get my classes, classes and classics from my abstract clauses, but class A, classbie listfraagment and class is just fragment.

I know that Java does not allow many heritage.

Many thanks

Can you remove general functionality in some supportive classes? Use Composition instead of Heritage


Comments