|
Evaluating Software Design Patterns — the "Gang of Four" patterns implemented in Java 6 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectdk.rode.thesis.meta.reflect.proxy.ProxyFactory.Key
private static final class ProxyFactory.Key
A key adapts a proxy to ensure consistent hashCode()
and equals(Object) behaviour when proxies are stored
internally by proxy factories, because proxies
may override hashCode and equals(Object)
in unpredictable ways.
| Field Summary | |
|---|---|
private ProxyFactory.Proxy |
proxy
The actual proxy object. |
| Constructor Summary | |
|---|---|
private |
ProxyFactory.Key(ProxyFactory.Proxy proxy)
Constructor. |
| Method Summary | |
|---|---|
boolean |
equals(Object object)
True if object is a key representing the
same exact proxy instance as the proxy represented
by this key. |
int |
hashCode()
Returns the hash code of this key. |
String |
toString()
Returns the string representation of this key. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private final ProxyFactory.Proxy proxy
Never null.
| Constructor Detail |
|---|
private ProxyFactory.Key(ProxyFactory.Proxy proxy)
proxy - The proxy to store; never null.| Method Detail |
|---|
public boolean equals(Object object)
object is a key representing the
same exact proxy instance as the proxy represented
by this key.
equals in class Objectobject - The object to test; can be null.
public int hashCode()
hashCode in class Objectpublic String toString()
toString in class Object
|
Gunni Rode / rode.dk | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||