|
Voyager ORB | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.objectspace.voyager.Proxy
A proxy represents another object. A proxy implements the same interfaces as its object, and method calls made to the proxy are forwarded to its object even if the object is in a different VM.
Method Summary | |
boolean |
equals(java.lang.Object object)
Return true if the specified object is a proxy that refers to the same object as myself. |
static Proxy |
export(java.lang.Object object)
Export the object on any local URL that is accepting connections and return a proxy to the exported object. |
static Proxy |
export(java.lang.Object object,
java.lang.String url)
Export the object on the specified URL and return a proxy to the exported object. |
java.lang.Object |
getLocal()
If I'm in the same VM as my object, return a regular Java reference to my object, otherwise return null. |
java.lang.String |
getURL()
Return my object's URL. |
int |
hashCode()
Return my hashcode. |
boolean |
isExported()
Return true if my object is exported. |
boolean |
isLocal()
Return true if I'm in the same VM as my associated object. |
static Proxy |
of(java.lang.Object object)
Return a proxy to the specified object. |
boolean |
remoteEquals(java.lang.Object object)
Return true if my associated object is equal to the specified object. |
int |
remoteHashCode()
Return the result of sending hashCode() to my associated object. |
java.lang.String |
toExternalForm()
Return a string that may be used as a parameter to Namespace.lookup() for obtaining a proxy to my object. |
java.lang.String |
toString()
Return the result of sending toString() to my associated object. |
static void |
unexport(java.lang.Object object)
Unexport the specified object. |
Method Detail |
public java.lang.String toString()
public int hashCode()
public boolean equals(java.lang.Object object)
object
- The object to compare against.public boolean remoteEquals(java.lang.Object object)
object
- The object to compare against.public int remoteHashCode()
public boolean isLocal()
public boolean isExported()
public java.lang.String getURL()
public java.lang.String toExternalForm()
public java.lang.Object getLocal()
public static Proxy export(java.lang.Object object) throws java.io.IOException
object
- The object to exportpublic static Proxy export(java.lang.Object object, java.lang.String url) throws java.io.IOException
object
- The object to exporturl
- The URL on which the object should be exported.public static void unexport(java.lang.Object object) throws java.io.IOException
object
- The object to unexport.public static Proxy of(java.lang.Object object)
object
- The object.
|
ObjectSpace Inc. | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |