|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.evolveum.midpoint.schema.delta.PropertyDelta
public class PropertyDelta
Relative difference (delta) of a property values.
This class describes what values are to be added, removed or replaced in the property. The delta can be either add+delete or replace, but not both. It either describes what values to add and delete from the property (add+delete) or what is the new set of values (replace). Add+delete deltas can be merged without a loss. There are ideal for multi-value properties. If replace deltas are merged, only the last value will be present. These are better suited for single-value properties.
ObjectDelta
Field Summary |
---|
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable |
---|
INDENT_STRING |
Constructor Summary | |
---|---|
PropertyDelta(PropertyPath propertyPath)
|
|
PropertyDelta(PropertyPath parentPath,
javax.xml.namespace.QName name)
|
|
PropertyDelta(javax.xml.namespace.QName name)
|
Method Summary | ||
---|---|---|
void |
addValuesToAdd(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
|
|
void |
addValuesToDelete(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
|
|
void |
addValueToAdd(PropertyValue<java.lang.Object> newValue)
|
|
void |
addValueToDelete(PropertyValue<java.lang.Object> newValue)
|
|
void |
applyTo(Property property)
Apply this delta (path) to a property. |
|
void |
applyTo(PropertyContainer propertyContainer)
Apply this delta (path) to a property container. |
|
void |
clear()
|
|
static PropertyDelta |
createDelta(PropertyModificationType propMod,
PropertyContainerDefinition pcDef)
|
|
static PropertyDelta |
createDelta(PropertyModificationType propMod,
Schema schema,
java.lang.Class<? extends ObjectType> objectType)
Creates delta from PropertyModificationType (XML). |
|
java.lang.String |
debugDump()
Show the content of the object intended for diagnostics by system administrator. |
|
java.lang.String |
debugDump(int indent)
|
|
java.lang.String |
dump()
Show the content of the object intended for diagnostics by developer. |
|
javax.xml.namespace.QName |
getName()
|
|
PropertyPath |
getParentPath()
|
|
PropertyPath |
getPath()
|
|
Property |
getPropertyNew(PropertyDefinition propertyDefinition,
PropertyPath parentPath)
Returns the "new" state of the property - the state that would be after the delta is applied. |
|
java.lang.Class<?> |
getValueClass()
|
|
|
getValues(java.lang.Class<T> type)
Returns all values regardless of whether they are added or removed or replaced. |
|
java.util.Collection<PropertyValue<java.lang.Object>> |
getValuesToAdd()
|
|
java.util.Collection<PropertyValue<java.lang.Object>> |
getValuesToDelete()
|
|
java.util.Collection<PropertyValue<java.lang.Object>> |
getValuesToReplace()
|
|
boolean |
isEmpty()
|
|
boolean |
isRealValueToAdd(PropertyValue<?> value)
|
|
boolean |
isRealValueToDelete(PropertyValue<?> value)
|
|
boolean |
isReplace()
|
|
boolean |
isValueToAdd(PropertyValue<?> value)
|
|
boolean |
isValueToDelete(PropertyValue<?> value)
|
|
void |
merge(PropertyDelta deltaToMerge)
Merge specified delta to this delta. |
|
void |
setName(javax.xml.namespace.QName name)
|
|
void |
setParentPath(PropertyPath parentPath)
|
|
void |
setValuesToReplace(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
|
|
java.util.Collection<PropertyModificationType> |
toPropertyModificationTypes()
Converts this delta to PropertyModificationType (XML). |
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public PropertyDelta(javax.xml.namespace.QName name)
public PropertyDelta(PropertyPath parentPath, javax.xml.namespace.QName name)
public PropertyDelta(PropertyPath propertyPath)
Method Detail |
---|
public javax.xml.namespace.QName getName()
public void setName(javax.xml.namespace.QName name)
public PropertyPath getParentPath()
public void setParentPath(PropertyPath parentPath)
public PropertyPath getPath()
public boolean isReplace()
public java.util.Collection<PropertyValue<java.lang.Object>> getValuesToAdd()
public java.util.Collection<PropertyValue<java.lang.Object>> getValuesToDelete()
public void clear()
public java.util.Collection<PropertyValue<java.lang.Object>> getValuesToReplace()
public <T> java.util.Collection<PropertyValue<T>> getValues(java.lang.Class<T> type)
public void merge(PropertyDelta deltaToMerge)
public void applyTo(PropertyContainer propertyContainer)
public java.lang.Class<?> getValueClass()
public void applyTo(Property property)
public void addValuesToAdd(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
public void addValueToAdd(PropertyValue<java.lang.Object> newValue)
public void addValuesToDelete(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
public void addValueToDelete(PropertyValue<java.lang.Object> newValue)
public void setValuesToReplace(java.util.Collection<PropertyValue<java.lang.Object>> newValues)
public boolean isEmpty()
public boolean isValueToAdd(PropertyValue<?> value)
public boolean isRealValueToAdd(PropertyValue<?> value)
public boolean isValueToDelete(PropertyValue<?> value)
public boolean isRealValueToDelete(PropertyValue<?> value)
public static PropertyDelta createDelta(PropertyModificationType propMod, Schema schema, java.lang.Class<? extends ObjectType> objectType) throws SchemaException
SchemaException
public static PropertyDelta createDelta(PropertyModificationType propMod, PropertyContainerDefinition pcDef) throws SchemaException
SchemaException
public java.util.Collection<PropertyModificationType> toPropertyModificationTypes() throws SchemaException
SchemaException
public Property getPropertyNew(PropertyDefinition propertyDefinition, PropertyPath parentPath)
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String debugDump()
DebugDumpable
debugDump
in interface DebugDumpable
public java.lang.String debugDump(int indent)
debugDump
in interface DebugDumpable
public java.lang.String dump()
Dumpable
dump
in interface Dumpable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |