Package com.evolveum.midpoint.prism.util
Class ObjectDeltaObject<O extends Objectable>
- java.lang.Object
-
- com.evolveum.midpoint.prism.util.ItemDeltaItem<PrismContainerValue<O>,PrismObjectDefinition<O>>
-
- com.evolveum.midpoint.prism.util.ObjectDeltaObject<O>
-
- All Implemented Interfaces:
DebugDumpable
,Serializable
public class ObjectDeltaObject<O extends Objectable> extends ItemDeltaItem<PrismContainerValue<O>,PrismObjectDefinition<O>> implements DebugDumpable
A class defining old object state (before change), delta (change) and new object state (after change). This is a useful class used to describe how the object has 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:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING
-
-
Constructor Summary
Constructors Constructor Description ObjectDeltaObject(PrismObject<O> oldObject, ObjectDelta<O> delta, PrismObject<O> newObject, PrismObjectDefinition<O> definition)
-
Method Summary
-
Methods inherited from class com.evolveum.midpoint.prism.util.ItemDeltaItem
applyDefinition, copyValues, findIdi, getAnyItem, getElementName, getItemNew, getItemOld, getResidualPath, getResolvePath, getSingleValue, getSubItemDeltas, isNull, isProperty, isStructuredProperty, resolveStructuredProperty, setItemNew, setItemOld, setResidualPath, setResolvePath, setSubItemDeltas, toDeltaSetTriple
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazily
-
-
-
-
Constructor Detail
-
ObjectDeltaObject
public ObjectDeltaObject(PrismObject<O> oldObject, ObjectDelta<O> delta, PrismObject<O> newObject, PrismObjectDefinition<O> definition)
-
-
Method Detail
-
getOldObject
public PrismObject<O> getOldObject()
-
getObjectDelta
public ObjectDelta<O> getObjectDelta()
-
getNewObject
public PrismObject<O> getNewObject()
-
hasAnyObject
public boolean hasAnyObject()
-
update
public void update(ItemDelta<?,?> itemDelta) throws SchemaException
- Throws:
SchemaException
-
getAnyObject
public PrismObject<O> getAnyObject()
-
getDelta
public ItemDelta<PrismContainerValue<O>,PrismObjectDefinition<O>> getDelta()
- Overrides:
getDelta
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
setDelta
public void setDelta(ItemDelta<PrismContainerValue<O>,PrismObjectDefinition<O>> delta)
- Overrides:
setDelta
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
isContainer
public boolean isContainer()
- Overrides:
isContainer
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
getDefinition
public PrismObjectDefinition<O> getDefinition()
- Overrides:
getDefinition
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
findIdi
public <IV extends PrismValue,ID extends ItemDefinition<?>> ItemDeltaItem<IV,ID> findIdi(@NotNull @NotNull ItemPath path, @Nullable @Nullable DefinitionResolver<PrismObjectDefinition<O>,ID> additionalDefinitionResolver) throws SchemaException
- Overrides:
findIdi
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
- Throws:
SchemaException
-
recompute
public void recompute() throws SchemaException
- Overrides:
recompute
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
- Throws:
SchemaException
-
recomputeIfNeeded
public void recomputeIfNeeded(boolean deep) throws SchemaException
- Throws:
SchemaException
-
create
public static <T extends Objectable> ObjectDeltaObject<T> create(PrismObject<T> oldObject, ObjectDelta<T> delta) throws SchemaException
- Throws:
SchemaException
-
create
public static <T extends Objectable> ObjectDeltaObject<T> create(PrismObject<T> oldObject, ItemDelta<?,?>... itemDeltas) throws SchemaException
- Throws:
SchemaException
-
equals
public boolean equals(Object o)
- Overrides:
equals
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
debugDump
public String debugDump(int indent)
- Specified by:
debugDump
in interfaceDebugDumpable
- Overrides:
debugDump
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
toString
public String toString()
- Overrides:
toString
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
clone
public ObjectDeltaObject<O> clone()
- Overrides:
clone
in classItemDeltaItem<PrismContainerValue<O extends Objectable>,PrismObjectDefinition<O extends Objectable>>
-
normalizeValuesToDelete
public ObjectDeltaObject<O> normalizeValuesToDelete(boolean doClone)
-
-