The predefined @Override annotation is used to detect logical errors during the compilation.
In this annotation is desirable to mark each method that will override a method from a superclass or implement a method from the interface.
If in a superclass or in the interface, there is no method with the same signature, there is a compilation error. This makes it easy to identify situations where a superclass or interface has been removed or altered signature overlapped method.
Login in to like
Login in to comment