org.caleigo.core
Interface IProxyEntity

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

public interface IProxyEntity
extends IEntity

A IProxyEntity is an extension of the IEntity interface for entity objects that act as proxies to other entity objects or may even be wrappers around other forms of property providers.

The proxy's remote object is the object that the proxy refers to. Proxy objects may be chained to other proxies in several layers and the first non proxy object in achain is defined as the source object. The remote/source object can be null in which case all access to field data in the proxy will return the default value defined by the proxy's descriptors.

Version:
1.00
Author:
Dennis Zikovic

Field Summary
 
Fields inherited from interface org.caleigo.core.IEntity
DIRTY, EMPTY, PERSISTENT
 
Method Summary
 void addProxyListener(IProxyListener listener)
          Adds IProxyListener to receive notifications of performed data operations on the entity object.
 IEntity getRemoteEntity()
          Access method that returns the remote entity of the proxy.
 IEntity getSourceEntity()
          Access method that returns the source entity of the proxy.
 boolean hasRemoteEntity()
          Boolean access method that returns true if the proxy has a remote entity if false then getRemoteEntity() will return null.
 boolean hasSourceEntity()
          Boolean access method that returns true if the proxy has a source entity if false then getSourceEntity() will return null.
 void removeProxyListener(IProxyListener listener)
          Removes the specified IProxyListener from the entity object.
 void setRemoteEntity(IEntity entity)
          Optional mutation method that throws an UnsupportedOperationException if the implementing class does not support the method.
 
Methods inherited from interface org.caleigo.core.IEntity
addEntityChangeListener, addEntityListener, clear, clearStatusFlag, copyData, delete, equals, equalsExactly, getData, getDataSource, getEntityDescriptor, getOriginQualifier, isDataNull, isDirty, 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

hasRemoteEntity

public boolean hasRemoteEntity()
Boolean access method that returns true if the proxy has a remote entity if false then getRemoteEntity() will return null.


getRemoteEntity

public IEntity getRemoteEntity()
Access method that returns the remote entity of the proxy. May return null if the proxy does not currently have a remote.


hasSourceEntity

public boolean hasSourceEntity()
Boolean access method that returns true if the proxy has a source entity if false then getSourceEntity() will return null.


getSourceEntity

public IEntity getSourceEntity()
Access method that returns the source entity of the proxy. May return null if the proxy does not currently have a source entity.


setRemoteEntity

public void setRemoteEntity(IEntity entity)
Optional mutation method that throws an UnsupportedOperationException if the implementing class does not support the method.


addProxyListener

public void addProxyListener(IProxyListener listener)
Adds IProxyListener to receive notifications of performed data operations on the entity object.


removeProxyListener

public void removeProxyListener(IProxyListener listener)
Removes the specified IProxyListener from the entity object.



Copyright © 2005 Caleigo. All Rights Reserved.