Package com.evolveum.midpoint.prism.util
Class ItemDeltaItem<V extends PrismValue,D extends ItemDefinition<?>> 
java.lang.Object
com.evolveum.midpoint.prism.util.ItemDeltaItem<V,D> 
- Type Parameters:
- V- type of value that the item holds
- D- type of definition of the item
- All Implemented Interfaces:
- AbstractItemDeltaItem<D>,- DebugDumpable,- Serializable
public class ItemDeltaItem<V extends PrismValue,D extends ItemDefinition<?>> 
extends Object
implements AbstractItemDeltaItem<D>
A class defining old item state (before change), delta (change) and new item state (after change). This is a useful
 class used to describe how the item has changed or is going to be changed without the need to re-apply the delta
 several times. The delta can be applied once, and then all the rest of the code will have all the data
 available. This is mostly just a convenience class that groups those three things together.
 There is only a very little logic on top of that.
- Author:
- Radovan Semancik
- See Also:
- 
Field SummaryFields inherited from interface com.evolveum.midpoint.util.DebugDumpableINDENT_STRING
- 
Constructor SummaryConstructorsModifierConstructorDescriptionItemDeltaItem(@NotNull Item<V, D> item) ItemDeltaItem(@Nullable Item<V, D> itemOld, @Nullable ItemDelta<V, D> delta, @Nullable Item<V, D> itemNew, D explicitDefinition) protectedItemDeltaItem(@Nullable Item<V, D> itemOld, @Nullable ItemDelta<V, D> delta, @Nullable Item<V, D> itemNew, D definition, @NotNull ItemPath resolvePath, @Nullable ItemPath residualPath, @Nullable Collection<? extends ItemDelta<?, ?>> subItemDeltas) For internal use (e.g., cloning); we do not do any checks here.ItemDeltaItem(@Nullable Item<V, D> item, D definition) ItemDeltaItem(@Nullable Item<V, D> item, D definition, @NotNull ItemPath resolvePath, @Nullable Collection<? extends ItemDelta<?, ?>> subItemDeltas) protectedItemDeltaItem(D definition) ForObjectDeltaObject.
- 
Method SummaryModifier and TypeMethodDescriptionvoidapplyDefinition(D def, boolean force) clone()debugDump(int indent) protected static <V extends PrismValue,D extends ItemDefinition<?>> 
 DdetermineDefinition(Item<V, D> itemOld, ItemDelta<V, D> delta, Item<V, D> itemNew, D explicitDefinition) boolean<IV extends PrismValue,ID extends ItemDefinition<?>> 
 ItemDeltaItem<IV,ID> findIdi(@NotNull ItemPath path, @Nullable DefinitionResolver<D, ID> additionalDefinitionResolver) As #findIdi(ItemPath) but with additional definition resolver that provides definitions for sub-items found.static <V extends PrismValue,D extends ItemDefinition<?>> 
 ItemDeltaItem<V,D> Presumably for "value creation" delta.static ItemDeltaItem<?,?> forUnchanged(@NotNull Item<?, ?> item) The definition of the item/object in question.getDelta()Returns new item that is a result of delta application.@NotNull ItemPathgetSingleValue(boolean old) Collection<? extends ItemDelta<?,?>> inthashCode()booleanIs the item in question a prism container?booleanisNull()Is the IDI empty, i.e.booleanIs the item in question a prism property?booleanIs the item in question a structured property -Structured? I.e.voidRecomputes the new state of the IDI.resolveStructuredProperty(ItemPath resolvePath, PrismPropertyDefinition<X> outputDefinition) Assumes that this IDI represents structured propertytoString()Methods inherited from class java.lang.Objectfinalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.evolveum.midpoint.prism.util.AbstractItemDeltaItemfindIdiMethods inherited from interface com.evolveum.midpoint.util.DebugDumpabledebugDump, debugDumpLazily, debugDumpLazily
- 
Constructor Details- 
ItemDeltaItemprotected ItemDeltaItem(@Nullable @Nullable Item<V, D> itemOld, @Nullable @Nullable ItemDelta<V, D> delta, @Nullable @Nullable Item<V, D> itemNew, @NotNull D definition, @NotNull @NotNull ItemPath resolvePath, @Nullable @Nullable ItemPath residualPath, @Nullable @Nullable Collection<? extends ItemDelta<?, ?>> subItemDeltas) For internal use (e.g., cloning); we do not do any checks here.
- 
ItemDeltaItemForObjectDeltaObject.
- 
ItemDeltaItem
- 
ItemDeltaItem
- 
ItemDeltaItem
- 
ItemDeltaItem
 
- 
- 
Method Details- 
forUnchanged
- 
forDeltapublic static <V extends PrismValue,D extends ItemDefinition<?>> ItemDeltaItem<V,D> forDelta(@NotNull @NotNull ItemDelta<V, D> delta) Presumably for "value creation" delta. The object must be recomputed after returning from the method.
- 
determineDefinition@NotNull protected static <V extends PrismValue,D extends ItemDefinition<?>> D determineDefinition(Item<V, D> itemOld, ItemDelta<V, D> delta, Item<V, D> itemNew, D explicitDefinition) 
- 
getItemOld
- 
getDelta
- 
getItemNewReturns new item that is a result of delta application. May return null if there is no new item. WARNING: Output of this method should be used for preview only. It should NOT be placed into prism structures. Not even cloned. This method may return dummy items or similar items that are not usable. Values in the items should be OK, but they may need cloning.
- 
getAnyItem
- 
getResidualPath
- 
getResolvePath
- 
getSubItemDeltas
- 
isNullpublic boolean isNull()Description copied from interface:AbstractItemDeltaItemIs the IDI empty, i.e. is everything null? FIXME the implementation of this method may not be 100% precise. Should be reviewed.- Specified by:
- isNullin interface- AbstractItemDeltaItem<V extends PrismValue>
 
- 
getElementName
- 
getDefinitionDescription copied from interface:AbstractItemDeltaItemThe definition of the item/object in question.- Specified by:
- getDefinitionin interface- AbstractItemDeltaItem<V extends PrismValue>
 
- 
recomputeDescription copied from interface:AbstractItemDeltaItemRecomputes the new state of the IDI.- Specified by:
- recomputein interface- AbstractItemDeltaItem<V extends PrismValue>
- Throws:
- SchemaException
 
- 
findIdipublic <IV extends PrismValue,ID extends ItemDefinition<?>> ItemDeltaItem<IV,ID> findIdi(@NotNull @NotNull ItemPath path, @Nullable @Nullable DefinitionResolver<D, ID> additionalDefinitionResolver) throws SchemaExceptionDescription copied from interface:AbstractItemDeltaItemAs #findIdi(ItemPath) but with additional definition resolver that provides definitions for sub-items found.- Specified by:
- findIdiin interface- AbstractItemDeltaItem<V extends PrismValue>
- Throws:
- SchemaException
 
- 
toDeltaSetTriple- Throws:
- SchemaException
 
- 
isContainerpublic boolean isContainer()Description copied from interface:AbstractItemDeltaItemIs the item in question a prism container?- Specified by:
- isContainerin interface- AbstractItemDeltaItem<V extends PrismValue>
 
- 
isPropertypublic boolean isProperty()Description copied from interface:AbstractItemDeltaItemIs the item in question a prism property?- Specified by:
- isPropertyin interface- AbstractItemDeltaItem<V extends PrismValue>
 
- 
isStructuredPropertypublic boolean isStructuredProperty()Description copied from interface:AbstractItemDeltaItemIs the item in question a structured property -Structured? I.e. a prism property that has visible components. (E.g., aPolyString.) SeeresolveStructuredProperty(ItemPath, PrismPropertyDefinition).- Specified by:
- isStructuredPropertyin interface- AbstractItemDeltaItem<V extends PrismValue>
 
- 
resolveStructuredPropertypublic <X> ItemDeltaItem<PrismPropertyValue<X>,PrismPropertyDefinition<X>> resolveStructuredProperty(ItemPath resolvePath, PrismPropertyDefinition<X> outputDefinition) Assumes that this IDI represents structured property
- 
applyDefinition- Throws:
- SchemaException
 
- 
clone
- 
equals
- 
hashCodepublic int hashCode()
- 
toString
- 
debugDump- Specified by:
- debugDumpin interface- DebugDumpable
 
- 
getSingleValue
 
-