ya im agree with jane.
how can u have method abstract as well as final
when u say a method is abstract means that will be implement by subclass or class that implements interface.
and
when u say final method cannot be override.
so both are opposite so they cannot be used togather
Following are some rules will help u
It is a compile-time error for a private method to be declared abstract. It would be impossible for a subclass to implement a private abstract method, because private methods are not visible to subclasses; therefore such a method could never be used.
It is a compile-time error for a static method to be declared abstract.
It is a compile-time error to declare an abstract class type such that it is not possible to create a subclass that implements all of its abstract methods. This situation can occur if the class would have as members two abstract methods that have the same method signature but different return types.
Abstract classes have constructor.
Abstract Class can have Static method it can even have main().
Because a final class never has any subclasses, the methods of a final class are never overridden
A compile-time error occurs if a class is declared to be a subclass of itself. For example:
class Point extends ColoredPoint { int x, y; }
class ColoredPoint extends Point { int color; }
. If circularly declared classes are detected at run time, as classes are loaded then a ClassCircularityError is thrown.
u can Override method and can make it Final.
It is a compile-time error for a final method to be declared abstract.
An abstract class can override an abstract method by providing another abstract method declaration. This can provide a place to put a documentation comment , or to declare that the set of checked exceptions that can be thrown by that method, when it is implemented by its subclasses, is to be more limited.
An instance method that is not abstract can be overridden by an abstract method. For example, we can declare an abstract class Point that requires its subclasses to implement toString if they are to be complete, instantiable classes: calling Super.toString() in subclass Will be error as toString() in Point overrides that in Object.
if u have any doubt feel free to contact
