1. Formal Parameters:
Class Name: An object that requires this class
Abstract class Name: A subclass object that requires this class
Interface Name: An implementation class object that requires this interface
Case one:
Case TWO:
Case THREE:
2. Return value type:
Class Name: Returns the object of the class
Abstract class Name: Returns the subclass object of the class
Interface Name: An object that returns an implementation class for the interface
Case one:
Case TWO:
Case THREE:
3. Chain-Type programming
Object. Method 1 (). Method 2 () .... Method N ();
This usage: In fact, after the invocation of Method 1 (), an object should be used;
After Method 2 () is called, an object should be returned.
After the method n () call is complete, the object may or might not be an object.
Case one:
Java_ class and Object 08_ form parameter and return value problem