SE450: The ADAPTER Pattern [7/55] |
Name in
Design Pattern |
Actual Name
(Icon->Component) |
Adaptee |
Icon |
Target |
JComponent |
Adapter |
IconAdapter |
Client |
The class that wants to add
icons into a container |
targetMethod() |
paintComponent(), getPreferredSize() |
adapteeMethod() |
paintIcon(), getIconWidth(), getIconHeight() |