Improved the adapter pattern example. Updated the class diagram.
This commit is contained in:
@@ -3,14 +3,15 @@ package com.iluwatar;
|
||||
/**
|
||||
*
|
||||
* Adapter (GnomeEngineer) converts the interface of the
|
||||
* target class (GoblinGlider) into suitable one.
|
||||
* target class (GoblinGlider) into suitable one expected
|
||||
* by the client (GnomeEngineeringManager).
|
||||
*
|
||||
*/
|
||||
public class App
|
||||
{
|
||||
public static void main( String[] args )
|
||||
{
|
||||
GnomeEngineer engineer = new GnomeEngineer();
|
||||
engineer.operateDevice();
|
||||
GnomeEngineeringManager manager = new GnomeEngineeringManager();
|
||||
manager.operateDevice();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user