org.elkoserver.server.context
Class BasicInternalObject

java.lang.Object
  extended by org.elkoserver.server.context.BasicInternalObject
All Implemented Interfaces:
Referenceable, InternalObject

public abstract class BasicInternalObject
extends Object
implements InternalObject

Utitlity base class for internal objects, providing a general implementation of the InternalObject interface that should be suitable for most uses.


Constructor Summary
BasicInternalObject()
           
 
Method Summary
 void activate(String ref, Contextor contextor)
          Make this object live inside the context server.
 Contextor contextor()
          Obtain the contextor for this server.
 String ref()
          Obtain this object's reference string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicInternalObject

public BasicInternalObject()
Method Detail

activate

public void activate(String ref,
                     Contextor contextor)
Make this object live inside the context server.

Specified by:
activate in interface InternalObject
Parameters:
ref - Reference string identifying this object in the static object table.
contextor - The contextor for this server.

contextor

public Contextor contextor()
Obtain the contextor for this server.

Specified by:
contextor in interface InternalObject
Returns:
the Contextor object for this server.

ref

public String ref()
Obtain this object's reference string.

Specified by:
ref in interface Referenceable
Returns:
a string that can be used to refer to this object in JSON messages, either as the message target or as a parameter value.