org.caleigo.core
Interface ICompositeEntityDescriptor

All Superinterfaces:
IEntityDescriptor, java.io.Serializable
All Known Implementing Classes:
CompositeEntityDescriptor

public interface ICompositeEntityDescriptor
extends IEntityDescriptor

The ICompositeEntityDescriptor interface defines how multiple entity types can be joined and handled as a single new entity type. A common use would also be to do a selection from only one base entity descriptor for performance reasons, another to make a join-tree of field groups with selections from different base entity descriptors.

Version:
1.00
Author:
Dennis Zikovic, Niklas Norberg

Nested Class Summary
static interface ICompositeEntityDescriptor.ICompositeFieldDescriptor
          The ICompositeFieldDescriptor wraps another field descriptor and in many ways acts as a proxy for it.
static interface ICompositeEntityDescriptor.ICompositeFieldGroup
          The IFieldGroup is used to group sets of fields belonging to a single entitydescriptor together and to define their relation to each other within the composite entity descriptor.
 
Field Summary
 
Fields inherited from interface org.caleigo.core.IEntityDescriptor
CUSTOM_ENTITY, DELETE_ACTION, LINK_ENTITY, MASTER_ENTITY, NO_TIME_LIMIT, SLAVE_ENTITY, STATIC_ENTITY, STORE_ACTION
 
Method Summary
 Qualifier getDefaultQualifier()
          Returns a qualifier that defineas the default filter for this entity.
 ICompositeEntityDescriptor.ICompositeFieldGroup getRootFieldGroup()
          Returns the root field group that is used as the base for the tree of field groups that defines the called ICompositeEntityDescriptor.
 void setDefaultQualifier(Qualifier defaultQualifier)
          This method sets the default qualifer for this composite entity descriptor.
 
Methods inherited from interface org.caleigo.core.IEntityDescriptor
contains, createEntity, createEntity, getAction, getAction, getActionCount, getActions, getCacheTime, getCodeName, getDataFieldCount, getDataSourceDescriptor, getDisplayName, getEntityClass, getEntityRelation, getEntityRelationCount, getEntityRelationIndex, getEntityRelations, getEntityType, getFieldCount, getFieldDescriptor, getFieldDescriptor, getFieldDescriptors, getFieldIndex, getFieldIndex, getHomeClass, getJNDIName, getNaturalOrder, getRemoteClass, getSourceName, isCacheable, isCreatable, isDeletable, isEditable, isListable, isScanable, isSelectable, loadEntity, loadSelection
 

Method Detail

getRootFieldGroup

public ICompositeEntityDescriptor.ICompositeFieldGroup getRootFieldGroup()
Returns the root field group that is used as the base for the tree of field groups that defines the called ICompositeEntityDescriptor.


setDefaultQualifier

public void setDefaultQualifier(Qualifier defaultQualifier)
This method sets the default qualifer for this composite entity descriptor. The default value is null i.e. don't discard any of the entities. It's maybe not nice to have a set method in an interface but it's the solution for now. A better way would be to set the default qualifier in the implementing class constructor, this however means a lot of work to transform and validate and the choices of parameters are not obvious either!

Parameters:
defaultQualifier - the qualifer that directly qualifies this composite entity descriptor should be validated.

getDefaultQualifier

public Qualifier getDefaultQualifier()
Returns a qualifier that defineas the default filter for this entity. Setting is done with a set method. The default value is null i.e. don't discard any of the entities. It might make sence e.g. to filter out all orders older than a discontinued date.



Copyright © 2005 Caleigo. All Rights Reserved.