GRASP mode:
Five basic modes: Information Expert, Creat, High Cohesion, Low Coupling, And Controller
Four extending modes: Polymorphism, Indirection, Pure Fabranation, Protected Variations
l High Cohesion, low coupling - High polymerization, low coupling is the highest principle of object-oriented!
l Polymorphism --Adapter, Command, Composite, Proxy, State, And Strategy model actually uses polymorphism.
l Pure FabRication - Behavior object, function-centric object. Adapter, Strategy, Command is a specific implementation of this mode.
l Indirection - "Most of the problems in the computer can be resolved by introducing intermediate layers" Adapter, Bridge, Facade, Observer, Mediator, is specific.
l Protected Variations - Isolation package changes. Change changes, uncertain things are protected with a stable unchanging interface package. Information hidden and opening and closing principles and PVs have the same meaning
Don't talk to stranger - Don't talk to strangers.
Public void morefragilemethod () {
Accountholder Holder =
Get Acorder (). getaccountholder (); getaccounender ();
}
Excessive access paths increase the coupling of the program for the object structure.