Mplements is also a keyword that implements inheritance relationships between parent classes and subclasses, such as Class A inheriting class B written as Class A implements b{}.
This is Baidu encyclopedia on the Interpretation:
Implements is a class that implements an interface keyword that is used to implement an abstract method defined in an interface. For example: People is an interface, he has say this method. public Interface People () {public say ();} However, the interface has no method body. The method body can only be implemented through a specific class. Such as Chinese this class, the implementation of the People interface. Public class Chinese implements people{public say () {System.out.println ("hello.") ");}}
Different from the extends
Extends, you can implement the parent class, or you can invoke the parent class to initialize This.parent (). The variables or functions defined by the parent class are overwritten. The benefit is that the architect defines the interface so that the engineer can implement it. The overall project development efficiency and development costs are greatly reduced.
Implements, implements the parent class, which cannot overwrite the parent class's methods or variables. Even if the subclass defines the same variable or function as the parent class, it is replaced by the parent class.
The specific use of these two implementations is to see the actual situation of the project, need to implement, can not modify the implements, only the definition of interface needs to be specific implementation, or can be modified to extend good, with extends.
Remember Mr. Zhang's video that said: If you use extends and implements at the same time, extends must be placed before the Implements keyword. such as: Class A extends B implements C.
Further understanding will continue to improve in the future.