|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectmandala.jacob.remote.AbstractRemote
mandala.jacob.remote.AbstractLocalReferenceRetriever
Abstract base class for local reference retriever remote objects implementation.
This class manage the behaviour of the getLocalReference()
method through its constructors and its finalize()
method. Hence, subclasses must ensure that super.finalize()
is
called in order to prevent memory leak.
Field Summary |
Fields inherited from class mandala.jacob.remote.AbstractRemote |
defaultExceptionHandler, exceptionHandler, syslog |
Constructor Summary | |
protected |
AbstractLocalReferenceRetriever(java.lang.Object localReference)
Creates a new AbstractLocalReferenceRetriever . |
protected |
AbstractLocalReferenceRetriever(java.lang.Object localReference,
ExceptionHandler exceptionHandler)
Creates a new LocalReferenceRetriever . |
Method Summary | |
protected void |
finalize()
|
java.lang.Object |
getID()
Returns the global unique identifier of this remote instance. |
java.lang.Object |
getLocalReference()
Returns a local reference on the object this remote
reference is refering to. |
java.lang.String |
toString()
|
Methods inherited from class mandala.jacob.remote.AbstractRemote |
getDefaultExceptionHandler, getExceptionHandler, getSyslog, handleException, setDefaultExceptionHandler, setExceptionHandler, setSyslog |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface mandala.jacob.remote.Remote |
getExceptionHandler, setExceptionHandler |
Constructor Detail |
protected AbstractLocalReferenceRetriever(java.lang.Object localReference)
Creates a new AbstractLocalReferenceRetriever
.
The ExceptionHandler
to use when an exception occurs is
set to a new SyslogExceptionHandler
instance.
localReference
- the local reference this object is referring to
java.lang.IllegalArgumentException
- if localReference
is an
ExceptionHandler
or is null
SyslogExceptionHandler
protected AbstractLocalReferenceRetriever(java.lang.Object localReference, ExceptionHandler exceptionHandler)
Creates a new LocalReferenceRetriever
.
localReference
- the local reference this object is referring toexceptionHandler
- The ExceptionHandler
to use when a
remote exception occurs.ExceptionHandler
,
if localReference
is
null
Method Detail |
protected void finalize() throws java.lang.Throwable
java.lang.Throwable
public java.lang.Object getLocalReference()
LocalReferenceRetriever
Returns a local reference on the object
this remote
reference is refering to.
Note that the caller must be on the same JVM than the local object in
order to get a valid return, otherwise, null
is
returned.
getLocalReference
in interface LocalReferenceRetriever
public java.lang.Object getID()
LocalReferenceRetriever
Returns the global unique identifier of this remote instance.
getID
in interface LocalReferenceRetriever
public java.lang.String toString()
toString
in class AbstractRemote
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |