org.caleigo.core
Interface IProxyController

All Superinterfaces:
java.lang.Comparable, IDataConsumer, IDataProvider, IDistributable, IEntity, IProxyEntity, java.io.Serializable
All Known Implementing Classes:
ProxyEntity

public interface IProxyController
extends IProxyEntity

Version:
1.00
Author:
Dennis Zikovic

Field Summary
 
Fields inherited from interface org.caleigo.core.IEntity
DIRTY, EMPTY, PERSISTENT
 
Method Summary
 java.util.Iterator getControlledProxies()
          Returns an Iterator with all proxies currently controlled by the called controller.
 IControlledProxy getControlledProxy(IEntityDescriptor entityDescriptor, IEntityRelationPath relationPath)
          Returns an IControlledProxy object controlled by the called controller.
 void initializeEntity(IEntity entity, IEntityRelationPath relationPath)
          Help method that initializes the data in an entity object based on its relation to the controller.
 boolean isDirty()
          Should return true if any of the controlled proxies are dirty.
 void prepareControlledLoad(IDataTransaction transaction)
          Prepares an transaction to load the proxy-chain structure that is controlled by the called IProxyController.
 void prepareControlledStore(IDataTransaction transaction)
          Prepares an transaction to store any changes made to the proxy-chain structure that is controlled by the called IProxyController.
 void releaseControlledProxy(IControlledProxy proxy)
          Used to inform the controller that a controlled proxy instance will be discarded and gives the controller a chance to deallocate resources connected to it.
 
Methods inherited from interface org.caleigo.core.IProxyEntity
addProxyListener, getRemoteEntity, getSourceEntity, hasRemoteEntity, hasSourceEntity, removeProxyListener, setRemoteEntity
 
Methods inherited from interface org.caleigo.core.IEntity
addEntityChangeListener, addEntityListener, clear, clearStatusFlag, copyData, delete, equals, equalsExactly, getData, getDataSource, getEntityDescriptor, getOriginQualifier, isDataNull, isEmpty, isFieldDirty, isPersistent, refresh, removeEntityChangeListener, removeEntityListener, setData, setStatusFlag, store, validateData
 
Methods inherited from interface org.caleigo.core.IDataProvider
getData
 
Methods inherited from interface org.caleigo.core.IDataConsumer
setData, setData
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Method Detail

getControlledProxy

public IControlledProxy getControlledProxy(IEntityDescriptor entityDescriptor,
                                           IEntityRelationPath relationPath)
Returns an IControlledProxy object controlled by the called controller. Implementing classes may cache the controlled proxies and return the same physical proxy object as long as the relationPath matches. The controller may refuse to controll a proxy and should then cast an IllegalArgumentException.


releaseControlledProxy

public void releaseControlledProxy(IControlledProxy proxy)
Used to inform the controller that a controlled proxy instance will be discarded and gives the controller a chance to deallocate resources connected to it.


getControlledProxies

public java.util.Iterator getControlledProxies()
Returns an Iterator with all proxies currently controlled by the called controller.


isDirty

public boolean isDirty()
Should return true if any of the controlled proxies are dirty.

Specified by:
isDirty in interface IEntity

prepareControlledLoad

public void prepareControlledLoad(IDataTransaction transaction)
Prepares an transaction to load the proxy-chain structure that is controlled by the called IProxyController.


prepareControlledStore

public void prepareControlledStore(IDataTransaction transaction)
Prepares an transaction to store any changes made to the proxy-chain structure that is controlled by the called IProxyController.


initializeEntity

public void initializeEntity(IEntity entity,
                             IEntityRelationPath relationPath)
Help method that initializes the data in an entity object based on its relation to the controller.



Copyright © 2005 Caleigo. All Rights Reserved.