Issue
I have 8 classes inheriting from a superclass, they all have ImageViews in them and I want to implement drag and drop on all of them, they will be used all at once in a single scene. Is there any way to do that for the superclass, so that it get inherited to all the subclasses?
Solution
Make a new interface defining a methods for that event type (exampleEvent() addExampleEvent() removeExampleEventListener()). Implement this interface in the concrete class which generates these events. It is better to use interfaces ,don't use inheritence, it will lead to some problems that you surely dont want them.
Answered By - user13500899
Answer Checked By - Timothy Miller (JavaFixing Admin)