|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.guiseframework.platform.AbstractPlatform
public abstract class AbstractPlatform
The platform on which Guise objects are being depicted.
| Constructor Summary | |
|---|---|
AbstractPlatform(GuiseApplication application)
Application constructor. |
|
| Method Summary | ||
|---|---|---|
long |
generateDepictID()
Generates a new depict ID unique to this session platform. |
|
GuiseApplication |
getApplication()
|
|
DepictedObject |
getDepictedObject(long depictedObjectID)
Retrieves a depicted object that has been registered with the platform by the ID of the depicted object. |
|
java.util.concurrent.locks.Lock |
getDepictLock()
|
|
|
getDepictor(O depictedObject)
Determines the depictor appropriate for the given depicted object. |
|
protected
|
getDepictorClass(java.lang.Class<O> depictedObjectClass)
Determines the depictor class appropriate for the given depicted object class. |
|
protected
|
getRegisteredDepictorClass(java.lang.Class<? extends DepictedObject> depictedObjectClass)
Determines the depictor class registered for the given depicted object class. |
|
java.util.Queue<? extends PlatformMessage> |
getSendMessageQueue()
|
|
void |
registerDepictedObject(DepictedObject depictedObject)
Registers a depicted object so that it can interact with the platform. |
|
protected
|
registerDepictorClass(java.lang.Class<O> depictedObjectClass,
java.lang.Class<?> depictorClass)
Registers the class of a depictor to depict an object of the given class (and by default subclasses). |
|
void |
unregisterDepictedObject(DepictedObject depictedObject)
Unregisters a depicted object so that no longer interacts with the platform. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.guiseframework.platform.Platform |
|---|
getClientProduct, getDepictContext, getEnvironment, selectPlatformFiles, sendResource, sendResource, sendResource, sendResource |
| Constructor Detail |
|---|
public AbstractPlatform(GuiseApplication application)
application - The Guise application running on this platform.environment - The initial environment of the session.
java.lang.NullPointerException - if the given application and/or environment is null.| Method Detail |
|---|
public GuiseApplication getApplication()
getApplication in interface Platformpublic java.util.concurrent.locks.Lock getDepictLock()
getDepictLock in interface Platform
protected <O extends DepictedObject> java.lang.Class<? extends Depictor<? super O>> registerDepictorClass(java.lang.Class<O> depictedObjectClass,
java.lang.Class<?> depictorClass)
O - The type of registered depicted object class.depictedObjectClass - The class of the depicted object for which the depictor should be registered.depictorClass - The class of depictor to use for depicting the objects.
null if there was no previous registration.protected <O extends DepictedObject> java.lang.Class<? extends Depictor<? super O>> getRegisteredDepictorClass(java.lang.Class<? extends DepictedObject> depictedObjectClass)
O - The type of registered depicted object class.depictedObjectClass - The class of depicted object that may be registered.
null if no depictor is registered.protected <O extends DepictedObject> java.lang.Class<? extends Depictor<? super O>> getDepictorClass(java.lang.Class<O> depictedObjectClass)
O - The type of registered depicted object class.depictedObjectClass - The class of depicted object for which a depictor should be returned.allowDefault - Whether a default depictor for the depicted object class should be accepted.
null if no depictor is registered.public <O extends DepictedObject> Depictor<? super O> getDepictor(O depictedObject)
getDepictor in interface PlatformO - The type of depicted object.depictedObject - The depicted object for which a depictor should be returned.
null if no depictor is registered.
java.lang.IllegalStateException - if the registered depictor could not be instantiated for some reason.public void registerDepictedObject(DepictedObject depictedObject)
registerDepictedObject in interface PlatformdepictedObject - The depicted object to register.
java.lang.NullPointerException - if the given depicted object is null.public void unregisterDepictedObject(DepictedObject depictedObject)
unregisterDepictedObject in interface PlatformdepictedObject - The depicted object to unregister.
java.lang.NullPointerException - if the given depicted object is null.public DepictedObject getDepictedObject(long depictedObjectID)
getDepictedObject in interface PlatformdepictedObjectID - The ID of the depicted object to retrieve.
null if there is no depicted object registered with this platform with the given ID.public long generateDepictID()
generateDepictID in interface Platformpublic java.util.Queue<? extends PlatformMessage> getSendMessageQueue()
getSendMessageQueue in interface Platform
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||