Note
If this works nicely the merge manager, remote traversals, and maybe even aspects of the commit manager could be converted to use this class.
| Modifier and Type | Class and Description |
|---|---|
| public class |
| Modifier and Type | Field and Description |
|---|---|
| public static final int | |
| protected DescriptorIterator. | |
| protected int | |
| public static final int | |
| protected ClassDescriptor | |
| protected AttributeGroup | |
| protected AttributeItem | |
| protected DatabaseMapping | |
| protected boolean | |
| public static final int | |
| protected Object | |
| protected AbstractSession | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected boolean | |
| protected Map | |
| protected Stack |
| Access | Constructor and Description |
|---|---|
| protected | DescriptorIterator()
Construct a typical iterator: iterate over all the objects process the objects contained by "value holders"... |
| Modifier and Type | Method and Description |
|---|---|
| public int | |
| public ClassDescriptor | |
| public AttributeGroup | |
| public AttributeItem | |
| public DatabaseMapping | |
| protected ClassDescriptor | |
| public Object | |
| public AbstractSession | |
| public Object | |
| public Map | |
| public Object | |
| public Stack | |
| protected void | internalIterateAggregateObject(Object aggregateObject)
Iterate an aggregate object (i.e. an object that is the target of an AggregateMapping). |
| protected void | internalIterateIndirectContainer(IndirectContainer<C> container)
Iterate an indirect container (IndirectList or IndirectMap). |
| protected void | internalIteratePrimitive(Object primitiveValue)
Iterate a primitive object (String, Date, Integer, etc.). |
| protected void | |
| protected void | |
| protected void | |
| public boolean | |
| protected abstract void | |
| public void | iterateForAggregateMapping(Object aggregateObject, DatabaseMapping mapping, ClassDescriptor descriptor)
Iterate on the mapping's reference object and recursively iterate on the reference object's reference objects. |
| public void | iterateIndirectContainerForMapping(IndirectContainer<C> container, DatabaseMapping mapping)
Iterate on the indirection object for its mapping. |
| public void | iteratePrimitiveForMapping(Object primitiveValue, DatabaseMapping mapping)
Iterate on the primitive value for its mapping. |
| public void | iterateReferenceObjectForMapping(Object referenceObject, DatabaseMapping mapping)
Iterate on the mapping's reference object and recursively iterate on the reference object's reference objects. |
| protected void | iterateReferenceObjects(Object sourceObject)
Iterate over the sourceObject's reference objects, updating the visited stack appropriately. |
| public void | iterateValueHolderForMapping(ValueHolderInterface<T> valueHolder, DatabaseMapping mapping)
Iterate on the value holder for its mapping. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | setShouldIterateOnAggregates(boolean shouldIterateOnAggregates)
Set whether the aggregate reference objects themselves should be processed. |
| public void | setShouldIterateOnFetchGroupAttributesOnly(boolean shouldIterateOnFetchGroupAttributesOnly)
Set whether the attributes outside fetch group should be processed. |
| public void | setShouldIterateOnIndirectionObjects(boolean shouldIterateOnIndirectionObjects)
Set whether the indirection objects themselves (e.g. the ValueHolders) should be processed. |
| public void | setShouldIterateOnPrimitives(boolean shouldIterateOnPrimitives)
Set whether to process primitive reference objects (e.g. Strings, Dates, ints). |
| public void | setShouldIterateOverIndirectionObjects(boolean shouldIterateOverIndirectionObjects)
Set whether to process the objects contained by indirection objects (e.g. a ValueHolder's value) - but *without* instantiating them. |
| public void | setShouldIterateOverUninstantiatedIndirectionObjects(boolean shouldIterateOverUninstantiatedIndirectionObjects)
Set whether to *instantiate* and process the objects contained by indirection objects (e.g. a ValueHolder's value). |
| public void | |
| public void | |
| public void | |
| protected void | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | shouldIterateOnAggregates()
Return whether the aggregate reference objects themselves should be processed. |
| public boolean | shouldIterateOnFetchGroupAttributesOnly()
If true then if object has a FetchGroup then iterations not performed on mappings that are outside of the FetchGroup. |
| public boolean | shouldIterateOnIndirectionObjects()
Return whether the indirection objects themselves (e.g. the ValueHolders) should be processed. |
| public boolean | shouldIterateOnPrimitives()
Return whether to process primitive reference objects (e.g. Strings, Dates, ints). |
| public boolean | shouldIterateOverIndirectionObjects()
Return whether to process the objects contained by indirection objects (e.g. a ValueHolder's value) - but *without* instantiating them. |
| public boolean | shouldIterateOverUninstantiatedIndirectionObjects()
Return whether to *instantiate* and process the objects contained by indirection objects (e.g. a ValueHolder's value). |
| public boolean | |
| public boolean | |
| public void | |
| public void | |
| public boolean |
| CascadeAllParts | back to summary |
|---|---|
| public static final int CascadeAllParts | |
| cascadeCondition | back to summary |
|---|---|
| protected DescriptorIterator. | |
| cascadeDepth | back to summary |
|---|---|
| protected int cascadeDepth | |
| CascadePrivateParts | back to summary |
|---|---|
| public static final int CascadePrivateParts | |
| currentDescriptor | back to summary |
|---|---|
| protected ClassDescriptor currentDescriptor | |
| currentGroup | back to summary |
|---|---|
| protected AttributeGroup currentGroup | |
| currentItem | back to summary |
|---|---|
| protected AttributeItem currentItem | |
| currentMapping | back to summary |
|---|---|
| protected DatabaseMapping currentMapping | |
| forDetach | back to summary |
|---|---|
| protected boolean forDetach | |
| NoCascading | back to summary |
|---|---|
| public static final int NoCascading | |
| result | back to summary |
|---|---|
| protected Object result | |
| session | back to summary |
|---|---|
| protected AbstractSession session | |
| shouldBreak | back to summary |
|---|---|
| protected boolean shouldBreak | |
| shouldIterateOnAggregates | back to summary |
|---|---|
| protected boolean shouldIterateOnAggregates | |
| shouldIterateOnFetchGroupAttributesOnly | back to summary |
|---|---|
| protected boolean shouldIterateOnFetchGroupAttributesOnly | |
| shouldIterateOnIndirectionObjects | back to summary |
|---|---|
| protected boolean shouldIterateOnIndirectionObjects | |
| shouldIterateOnPrimitives | back to summary |
|---|---|
| protected boolean shouldIterateOnPrimitives | |
| shouldIterateOverIndirectionObjects | back to summary |
|---|---|
| protected boolean shouldIterateOverIndirectionObjects | |
| shouldIterateOverUninstantiatedIndirectionObjects | back to summary |
|---|---|
| protected boolean shouldIterateOverUninstantiatedIndirectionObjects | |
| shouldIterateOverWrappedObjects | back to summary |
|---|---|
| protected boolean shouldIterateOverWrappedObjects | |
| shouldTrackCurrentGroup | back to summary |
|---|---|
| protected boolean shouldTrackCurrentGroup | |
| usesGroup | back to summary |
|---|---|
| protected boolean usesGroup | |
| visitedObjects | back to summary |
|---|---|
| protected Map<K, V> visitedObjects | |
| visitedStack | back to summary |
|---|---|
| protected Stack<E> visitedStack | |
| DescriptorIterator | back to summary |
|---|---|
| protected DescriptorIterator() Construct a typical iterator: iterate over all the objects process the objects contained by "value holders"... ...but only if they have already been instantiated... ...and don't process the "value holders" themselves process "wrapped" objects skip aggregate objects skip primitives (Strings, Dates, Integers, etc.) | |
| getCascadeDepth | back to summary |
|---|---|
| public int getCascadeDepth() | |
| getCurrentDescriptor | back to summary |
|---|---|
| public ClassDescriptor getCurrentDescriptor() | |
| getCurrentGroup | back to summary |
|---|---|
| public AttributeGroup getCurrentGroup() | |
| getCurrentItem | back to summary |
|---|---|
| public AttributeItem getCurrentItem() | |
| getCurrentMapping | back to summary |
|---|---|
| public DatabaseMapping getCurrentMapping() | |
| getDescriptorFor | back to summary |
|---|---|
| protected ClassDescriptor getDescriptorFor(Object object) Fetch and return the descriptor for the specified object. | |
| getResult | back to summary |
|---|---|
| public Object getResult() | |
| getSession | back to summary |
|---|---|
| public AbstractSession getSession() | |
| getVisitedGrandparent | back to summary |
|---|---|
| public Object getVisitedGrandparent() Return the second-to-last object visited. | |
| getVisitedObjects | back to summary |
|---|---|
| public Map | |
| getVisitedParent | back to summary |
|---|---|
| public Object getVisitedParent() Return the last object visited. | |
| getVisitedStack | back to summary |
|---|---|
| public Stack | |
| internalIterateAggregateObject | back to summary |
|---|---|
| protected void internalIterateAggregateObject(Object aggregateObject) Iterate an aggregate object (i.e. an object that is the target of an AggregateMapping). Override this method if appropriate. | |
| internalIterateIndirectContainer | back to summary |
|---|---|
| protected void internalIterateIndirectContainer(IndirectContainer<C> container) Iterate an indirect container (IndirectList or IndirectMap). Override this method if appropriate. | |
| internalIteratePrimitive | back to summary |
|---|---|
| protected void internalIteratePrimitive(Object primitiveValue) Iterate a primitive object (String, Date, Integer, etc.). Override this method if appropriate. | |
| internalIterateReferenceObject | back to summary |
|---|---|
| protected void internalIterateReferenceObject(Object referenceObject) Iterate a (a non-Aggregate) reference object. Override this method if appropriate. | |
| internalIterateReferenceObjects | back to summary |
|---|---|
| protected void internalIterateReferenceObjects(Object sourceObject) | |
| internalIterateValueHolder | back to summary |
|---|---|
| protected void internalIterateValueHolder(ValueHolderInterface<T> valueHolder) Iterate a value holder. Override this method if appropriate. | |
| isForDetach | back to summary |
|---|---|
| public boolean isForDetach() | |
| iterate | back to summary |
|---|---|
| protected abstract void iterate(Object object) To define a new iterator create a subclass and define at least this method. Given an object or set of the objects, this method will be called on those objects and any object connected to them by using the descriptors to traverse the object graph. Override the assorted #internalIterate*() methods if appropriate. | |
| iterateForAggregateMapping | back to summary |
|---|---|
| public void iterateForAggregateMapping(Object aggregateObject, DatabaseMapping mapping, ClassDescriptor descriptor) Iterate on the mapping's reference object and recursively iterate on the reference object's reference objects. This is used for aggregate and aggregate collection mappings, which are not iterated on by default. | |
| iterateIndirectContainerForMapping | back to summary |
|---|---|
| public void iterateIndirectContainerForMapping(IndirectContainer<C> container, DatabaseMapping mapping) Iterate on the indirection object for its mapping. | |
| iteratePrimitiveForMapping | back to summary |
|---|---|
| public void iteratePrimitiveForMapping(Object primitiveValue, DatabaseMapping mapping) Iterate on the primitive value for its mapping. | |
| iterateReferenceObjectForMapping | back to summary |
|---|---|
| public void iterateReferenceObjectForMapping(Object referenceObject, DatabaseMapping mapping) Iterate on the mapping's reference object and recursively iterate on the reference object's reference objects. | |
| iterateReferenceObjects | back to summary |
|---|---|
| protected void iterateReferenceObjects(Object sourceObject) Iterate over the sourceObject's reference objects, updating the visited stack appropriately. | |
| iterateValueHolderForMapping | back to summary |
|---|---|
| public void iterateValueHolderForMapping(ValueHolderInterface<T> valueHolder, DatabaseMapping mapping) Iterate on the value holder for its mapping. | |
| setCascadeCondition | back to summary |
|---|---|
| public void setCascadeCondition(DescriptorIterator. | |
| setCascadeDepth | back to summary |
|---|---|
| public void setCascadeDepth(int cascadeDepth) | |
| setCurrentDescriptor | back to summary |
|---|---|
| public void setCurrentDescriptor(ClassDescriptor currentDescriptor) | |
| setCurrentGroup | back to summary |
|---|---|
| public void setCurrentGroup(AttributeGroup group) | |
| setCurrentItem | back to summary |
|---|---|
| public void setCurrentItem(AttributeItem item) | |
| setCurrentMapping | back to summary |
|---|---|
| public void setCurrentMapping(DatabaseMapping currentMapping) | |
| setForDetach | back to summary |
|---|---|
| public void setForDetach(boolean forDetach) | |
| setResult | back to summary |
|---|---|
| public void setResult(Object result) | |
| setSession | back to summary |
|---|---|
| public void setSession(AbstractSession session) | |
| setShouldBreak | back to summary |
|---|---|
| public void setShouldBreak(boolean shouldBreak) | |
| setShouldIterateOnAggregates | back to summary |
|---|---|
| public void setShouldIterateOnAggregates(boolean shouldIterateOnAggregates) Set whether the aggregate reference objects themselves should be processed. (The objects referenced by the aggregate objects will be processed either way.) | |
| setShouldIterateOnFetchGroupAttributesOnly | back to summary |
|---|---|
| public void setShouldIterateOnFetchGroupAttributesOnly(boolean shouldIterateOnFetchGroupAttributesOnly) Set whether the attributes outside fetch group should be processed. | |
| setShouldIterateOnIndirectionObjects | back to summary |
|---|---|
| public void setShouldIterateOnIndirectionObjects(boolean shouldIterateOnIndirectionObjects) Set whether the indirection objects themselves (e.g. the ValueHolders) should be processed. | |
| setShouldIterateOnPrimitives | back to summary |
|---|---|
| public void setShouldIterateOnPrimitives(boolean shouldIterateOnPrimitives) Set whether to process primitive reference objects (e.g. Strings, Dates, ints). | |
| setShouldIterateOverIndirectionObjects | back to summary |
|---|---|
| public void setShouldIterateOverIndirectionObjects(boolean shouldIterateOverIndirectionObjects) Set whether to process the objects contained by indirection objects (e.g. a ValueHolder's value) - but *without* instantiating them. | |
| setShouldIterateOverUninstantiatedIndirectionObjects | back to summary |
|---|---|
| public void setShouldIterateOverUninstantiatedIndirectionObjects(boolean shouldIterateOverUninstantiatedIndirectionObjects) Set whether to *instantiate* and process the objects contained by indirection objects (e.g. a ValueHolder's value). | |
| setShouldIterateOverWrappedObjects | back to summary |
|---|---|
| public void setShouldIterateOverWrappedObjects(boolean shouldIterateOverWrappedObjects) | |
| setShouldTrackCurrentGroup | back to summary |
|---|---|
| public void setShouldTrackCurrentGroup(boolean shouldTrackCurrentGroup) | |
| setVisitedObjects | back to summary |
|---|---|
| public void setVisitedObjects(Map<K, V> visitedObjects) | |
| setVisitedStack | back to summary |
|---|---|
| protected void setVisitedStack(Stack<E> visitedStack) | |
| shouldBreak | back to summary |
|---|---|
| public boolean shouldBreak() | |
| shouldCascadeAllParts | back to summary |
|---|---|
| public boolean shouldCascadeAllParts() | |
| shouldCascadeNoParts | back to summary |
|---|---|
| public boolean shouldCascadeNoParts() | |
| shouldCascadePrivateParts | back to summary |
|---|---|
| public boolean shouldCascadePrivateParts() | |
| shouldIterateOnAggregates | back to summary |
|---|---|
| public boolean shouldIterateOnAggregates() Return whether the aggregate reference objects themselves should be processed. (The objects referenced by the aggregate objects will be processed either way.) | |
| shouldIterateOnFetchGroupAttributesOnly | back to summary |
|---|---|
| public boolean shouldIterateOnFetchGroupAttributesOnly() If true then if object has a FetchGroup then iterations not performed on mappings that are outside of the FetchGroup. | |
| shouldIterateOnIndirectionObjects | back to summary |
|---|---|
| public boolean shouldIterateOnIndirectionObjects() Return whether the indirection objects themselves (e.g. the ValueHolders) should be processed. | |
| shouldIterateOnPrimitives | back to summary |
|---|---|
| public boolean shouldIterateOnPrimitives() Return whether to process primitive reference objects (e.g. Strings, Dates, ints). | |
| shouldIterateOverIndirectionObjects | back to summary |
|---|---|
| public boolean shouldIterateOverIndirectionObjects() Return whether to process the objects contained by indirection objects (e.g. a ValueHolder's value) - but *without* instantiating them. | |
| shouldIterateOverUninstantiatedIndirectionObjects | back to summary |
|---|---|
| public boolean shouldIterateOverUninstantiatedIndirectionObjects() Return whether to *instantiate* and process the objects contained by indirection objects (e.g. a ValueHolder's value). | |
| shouldIterateOverWrappedObjects | back to summary |
|---|---|
| public boolean shouldIterateOverWrappedObjects() | |
| shouldTrackCurrentGroup | back to summary |
|---|---|
| public boolean shouldTrackCurrentGroup() | |
| startIterationOn | back to summary |
|---|---|
| public void startIterationOn(Object sourceObject) This is the root method called to start the iteration. | |
| startIterationOn | back to summary |
|---|---|
| public void startIterationOn(Object sourceObject, AttributeGroup group) | |
| usesGroup | back to summary |
|---|---|
| public boolean usesGroup() | |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean |
| CascadeCondition | back to summary |
|---|---|
| public CascadeCondition() Default constructor. | |
| shouldNotCascade | back to summary |
|---|---|
| public boolean shouldNotCascade(DatabaseMapping mapping) | |