|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.evolveum.midpoint.schema.processor.Item
com.evolveum.midpoint.schema.processor.Property
public class Property
Property is a specific characteristic of an object. It may be considered object "attribute" or "field". For example User has fullName property that contains string value of user's full name.
Properties may be single-valued or multi-valued Properties may contain primitive types or complex types (defined by XSD schema) Property values are unordered, implementation may change the order of values Duplicate values of properties should be silently removed by implementations, but clients must be able tolerate presence of duplicate values. Operations that modify the objects work with the granularity of properties. They add/remove/replace the values of properties, but do not "see" inside the property. Property is mutable.
Field Summary |
---|
Fields inherited from class com.evolveum.midpoint.schema.processor.Item |
---|
definition, element, name, parentPath |
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable |
---|
INDENT_STRING |
Constructor Summary | |
---|---|
Property(javax.xml.namespace.QName name,
PropertyDefinition definition,
java.lang.Object element,
PropertyPath parentPath)
|
Method Summary | ||
---|---|---|
void |
addValue(PropertyValue<java.lang.Object> pValueToAdd)
|
|
void |
addValues(java.util.Collection<PropertyValue<java.lang.Object>> pValuesToAdd)
|
|
void |
applyValueToElement()
|
|
Property |
clone()
|
|
PropertyDelta |
compareRealValuesTo(Property other)
This method compares "this" property with other property. |
|
PropertyDelta |
compareTo(Property other)
This method compares "this" property with other property. |
|
protected void |
copyValues(Property clone)
|
|
PropertyModification |
createModification(PropertyModification.ModificationType modificationType,
PropertyValue<java.lang.Object> modifyValue)
|
|
PropertyModification |
createModification(PropertyModification.ModificationType modificationType,
java.util.Set<PropertyValue<java.lang.Object>> modifyValues)
|
|
java.lang.String |
debugDump(int indent)
|
|
boolean |
deleteValue(PropertyValue<java.lang.Object> pValueToDelete)
|
|
boolean |
deleteValues(java.util.Collection<PropertyValue<java.lang.Object>> pValuesToDelete)
|
|
boolean |
equals(java.lang.Object obj)
|
|
protected java.lang.String |
getDebugDumpClassName()
Return a human readable name of this class suitable for logs. |
|
PropertyDefinition |
getDefinition()
Returns applicable property definition. |
|
|
getRealValues(java.lang.Class<T> type)
|
|
PropertyValue<java.lang.Object> |
getValue()
|
|
|
getValue(java.lang.Class<T> T)
Returns value of a single-valued property. |
|
java.util.Set<PropertyValue<java.lang.Object>> |
getValues()
Returns property values. |
|
|
getValues(java.lang.Class<T> T)
Returns property values. |
|
int |
hashCode()
|
|
boolean |
hasRealValue(PropertyValue<java.lang.Object> value)
|
|
boolean |
hasValue(PropertyValue<java.lang.Object> value)
|
|
boolean |
isEmpty()
|
|
void |
replaceValues(java.util.Collection<PropertyValue<java.lang.Object>> valuesToReplace)
|
|
void |
serializeToDom(org.w3c.dom.Node parentNode)
Serializes property to DOM or JAXB element(s). |
|
void |
serializeToDom(org.w3c.dom.Node parentNode,
PropertyDefinition propDef,
java.util.Set<PropertyValue<java.lang.Object>> alternateValues,
boolean recordType)
|
|
java.util.List<java.lang.Object> |
serializeToJaxb(org.w3c.dom.Document doc)
Serializes property to DOM or JAXB element(s). |
|
void |
setDefinition(PropertyDefinition definition)
Sets applicable property definition. |
|
void |
setValue(PropertyValue value)
Means as a short-hand for setting just a value for single-valued attributes. |
|
java.lang.String |
toString()
|
Methods inherited from class com.evolveum.midpoint.schema.processor.Item |
---|
copyValues, debugDump, dump, getDisplayName, getElement, getHelp, getName, getParentPath, getPath, setElement, setName, setParentPath |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Property(javax.xml.namespace.QName name, PropertyDefinition definition, java.lang.Object element, PropertyPath parentPath)
Method Detail |
---|
public PropertyDefinition getDefinition()
getDefinition
in class Item
public void setDefinition(PropertyDefinition definition)
setDefinition
in class Item
definition
- the definition to setpublic java.util.Set<PropertyValue<java.lang.Object>> getValues()
public <T> java.util.Set<PropertyValue<T>> getValues(java.lang.Class<T> T)
T
- Target class for property valuesT
- Target class for property values
java.lang.ClassCastException
- if the values cannot be cast to "T"public <T> java.util.Collection<T> getRealValues(java.lang.Class<T> type)
public <T> PropertyValue<T> getValue(java.lang.Class<T> T)
T
- Target class for property valuesT
- Target class for property values
java.lang.ClassCastException
java.lang.IllegalStateException
- more than one value is presentpublic PropertyValue<java.lang.Object> getValue()
public void setValue(PropertyValue value)
public void addValues(java.util.Collection<PropertyValue<java.lang.Object>> pValuesToAdd)
public void addValue(PropertyValue<java.lang.Object> pValueToAdd)
public boolean deleteValues(java.util.Collection<PropertyValue<java.lang.Object>> pValuesToDelete)
public boolean deleteValue(PropertyValue<java.lang.Object> pValueToDelete)
public void replaceValues(java.util.Collection<PropertyValue<java.lang.Object>> valuesToReplace)
public boolean hasValue(PropertyValue<java.lang.Object> value)
public boolean hasRealValue(PropertyValue<java.lang.Object> value)
public boolean isEmpty()
public PropertyModification createModification(PropertyModification.ModificationType modificationType, java.util.Set<PropertyValue<java.lang.Object>> modifyValues)
public PropertyModification createModification(PropertyModification.ModificationType modificationType, PropertyValue<java.lang.Object> modifyValue)
public void serializeToDom(org.w3c.dom.Node parentNode) throws SchemaException
Item
serializeToDom
in class Item
parentNode
- DOM Document
SchemaException
- No definition or inconsistent definitionpublic void serializeToDom(org.w3c.dom.Node parentNode, PropertyDefinition propDef, java.util.Set<PropertyValue<java.lang.Object>> alternateValues, boolean recordType) throws SchemaException
SchemaException
public java.util.List<java.lang.Object> serializeToJaxb(org.w3c.dom.Document doc) throws SchemaException
doc
- DOM Document
SchemaException
- No definition or inconsistent definitionpublic void applyValueToElement() throws SchemaException
SchemaException
public Property clone()
clone
in class Item
protected void copyValues(Property clone)
public int hashCode()
hashCode
in class Item
public boolean equals(java.lang.Object obj)
equals
in class Item
public PropertyDelta compareRealValuesTo(Property other)
PropertyValue
.
other
- can be null, property delta will be add all values from "this" property.
PropertyDelta
which represents differences between them. That means when
resulting property delta is applied on other property then other property and "this" property
will be equal.public PropertyDelta compareTo(Property other)
other
- can be null, property delta will be add all values from "this" property.
PropertyDelta
which represents differences between them. That means when
resulting property delta is applied on other property then other property and "this" property
will be equal.public java.lang.String toString()
toString
in class Item
public java.lang.String debugDump(int indent)
debugDump
in interface DebugDumpable
debugDump
in class Item
protected java.lang.String getDebugDumpClassName()
getDebugDumpClassName
in class Item
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |