Override given overload given overwrite in java

First of all, there is no overwrite in java, so there is no need to entangle the difference between overwrite and override.

Override, which can be translated as "override" or "override", refers to the method in which the subclass overrides the parent class or the method in which the class implements the interface. Java implements polymorphism through override.

Overload, translated as "overload", the requirement of overload is that the method name is the same, the method parameters are different, and the method return value can be the same or different. Overloading has nothing to do with polymorphism.

Guess you like

Origin blog.csdn.net/kitahiragawa/article/details/112342863