Class DummyReferenceImpl
java.lang.Object
com.evolveum.midpoint.prism.impl.item.DummyItem<PrismReferenceValue,PrismReferenceDefinition,PrismReference>
com.evolveum.midpoint.prism.impl.item.DummyReferenceImpl
- All Implemented Interfaces:
ComplexCopyable<Item<PrismReferenceValue,,PrismReferenceDefinition>> Freezable,Item<PrismReferenceValue,,PrismReferenceDefinition> Itemable,ParentVisitable,PathVisitable,PrismReference,PrismVisitable,Revivable,Visitable,DebugDumpable,Serializable,Cloneable
public class DummyReferenceImpl
extends DummyItem<PrismReferenceValue,PrismReferenceDefinition,PrismReference>
implements PrismReference
- Author:
- semancik
- See Also:
-
Field Summary
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRINGFields inherited from interface com.evolveum.midpoint.prism.Item
KEY_NAMESPACE_CONTEXT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddIgnoringEquivalents(@NotNull PrismReferenceValue newValue) Adds a value, not looking for equivalent values.clone()Literal clone.@NotNull PrismReferencecloneComplex(@NotNull CloneStrategy strategy) Complex clone with different cloning strategies.Creates specific subclass of ItemDelta appropriate for type of item that this definition represents (e.g.createDelta(ItemPath path) <IV extends PrismValue,ID extends ItemDefinition<?>>
PartiallyResolvedItem<IV,ID> findPartial(ItemPath path) <I extends Item<?,?>>
IfindReferencedItem(ItemPath dereferencePath, Class<I> type) Tries to find referenced path (path starting with object derefence) in-memory.findValueByOid(String oid) getHelp()Returns help message defined for the item.getOid()Returns the "real value" (content) of this item: - value contained in PrismPropertyValue - Referencable in PrismReferenceValue - Containerable in PrismContainerValue - Objectable in PrismObjectValue Note that the real value can contain operational items.<X> XgetRealValue(Class<X> type) Type override, also for compatibility.@NotNull Collection<Referencable>Returns (potentially empty) collection of "real values".<X> X[]getRealValuesArray(Class<X> type) Type override, also for compatibility.getValue()Returns the value, if there is only one.booleanmerge(PrismReferenceValue value) Methods inherited from class com.evolveum.midpoint.prism.impl.item.DummyItem
accept, accept, acceptParentVisitor, add, addAll, addRespectingMetadataAndCloning, applyDefinition, assertDefinitions, assertDefinitions, assertDefinitions, checkConsistence, checkConsistence, checkConsistence, checkConsistence, checkConsistence, checkConsistenceInternal, clear, debugDump, delegate, diff, equals, equals, equals, find, freeze, getAllItems, getAllValues, getDefinition, getDisplayName, getElementName, getHighestId, getParent, getPath, getUserData, getUserData, getValues, hasCompleteDefinition, hashCode, hashCode, hashCode, isEmpty, isImmutable, isIncomplete, merge, normalize, recomputeAllValues, remove, removeAll, removeRespectingMetadata, replace, replaceAll, revive, setDefinition, setElementName, setIncomplete, setParent, setUserData, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazilyMethods inherited from interface com.evolveum.midpoint.prism.Freezable
checkImmutable, checkMutable, freeze, isImmutableMethods inherited from interface com.evolveum.midpoint.prism.Item
acceptParentVisitor, acceptVisitor, add, add, addAll, addAll, addRespectingMetadataAndCloning, applyDefinition, applyDefinition, applyDefinitionIfMissing, assertDefinitions, assertDefinitions, assertDefinitions, checkConsistence, checkConsistence, checkConsistence, checkConsistence, checkConsistence, checkConsistenceInternal, clear, contains, contains, diff, diff, equals, equals, equals, filterValues, filterYields, find, findValue, findValue, getAllItems, getAllValues, getAnyValue, getAnyValue, getClonedValues, getDefinition, getDisplayName, getElementName, getHighestId, getNamespaceContext, getParent, getPath, getRealValues, getRealValuesOrRawTypes, getUserData, getUserData, getValues, hasAnyValue, hasCompleteDefinition, hashCode, hashCode, hashCode, hasNoValues, hasRaw, isEmpty, isIncomplete, isOperational, isRaw, isSingleValue, isSingleValueByDefinition, merge, normalize, recomputeAllValues, remove, remove, removeAll, removeIf, removeRespectingMetadata, replace, replaceAll, setDefinition, setElementName, setIncomplete, setParent, setUserData, size, valuesStreamMethods inherited from interface com.evolveum.midpoint.prism.PathVisitable
acceptMethods inherited from interface com.evolveum.midpoint.prism.PrismReference
copy, debugDump, immutableCopy, mutableCopy, toString
-
Constructor Details
-
DummyReferenceImpl
-
-
Method Details
-
getRealValue
Description copied from interface:ItemReturns the "real value" (content) of this item: - value contained in PrismPropertyValue - Referencable in PrismReferenceValue - Containerable in PrismContainerValue - Objectable in PrismObjectValue Note that the real value can contain operational items. It can also contain container IDs (although they are not considered to be part of the real value). It does not contain information about item element name nor other metadata like origin, definition, etc. (Although e.g. Containerable can be converted back into PrismContainerValue that can be used to retrieve this information.)- Specified by:
getRealValuein interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
getRealValuein interfacePrismReference
-
getRealValue
Description copied from interface:ItemType override, also for compatibility.- Specified by:
getRealValuein interfaceItem<PrismReferenceValue,PrismReferenceDefinition>
-
getRealValuesArray
Description copied from interface:ItemType override, also for compatibility.- Specified by:
getRealValuesArrayin interfaceItem<PrismReferenceValue,PrismReferenceDefinition>
-
getRealValues
Description copied from interface:ItemReturns (potentially empty) collection of "real values". The list itself is detached, freely modifiable. (Note that the values can still embed a parent, e.g., for containers and references.)- Specified by:
getRealValuesin interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
getRealValuesin interfacePrismReference- See Also:
-
addIgnoringEquivalents
public ItemModifyResult<PrismReferenceValue> addIgnoringEquivalents(@NotNull @NotNull PrismReferenceValue newValue) throws SchemaException Description copied from interface:ItemAdds a value, not looking for equivalent values. (This means that the new value is always added, if possible.) Note that we check the cardinality of the item according to its definition, i.e. we do not allow single-valued item to contain more than one value.- Specified by:
addIgnoringEquivalentsin interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Throws:
SchemaException
-
merge
- Specified by:
mergein interfacePrismReference
-
getOid
- Specified by:
getOidin interfacePrismReference
-
getTargetName
- Specified by:
getTargetNamein interfacePrismReference
-
findValueByOid
- Specified by:
findValueByOidin interfacePrismReference
-
findPartial
public <IV extends PrismValue,ID extends ItemDefinition<?>> PartiallyResolvedItem<IV,ID> findPartial(ItemPath path) - Specified by:
findPartialin interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
findPartialin interfacePrismReference
-
createDelta
Description copied from interface:ItemCreates specific subclass of ItemDelta appropriate for type of item that this definition represents (e.g. PropertyDelta, ContainerDelta, ...)- Specified by:
createDeltain interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
createDeltain interfacePrismReference
-
createDelta
- Specified by:
createDeltain interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
createDeltain interfacePrismReference
-
clone
Description copied from interface:ItemLiteral clone.- Specified by:
clonein interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
clonein interfacePrismReference- Specified by:
clonein classDummyItem<PrismReferenceValue,PrismReferenceDefinition, PrismReference>
-
createImmutableClone
- Specified by:
createImmutableClonein interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
createImmutableClonein interfacePrismReference
-
cloneComplex
Description copied from interface:ItemComplex clone with different cloning strategies.- Specified by:
cloneComplexin interfaceComplexCopyable<Item<PrismReferenceValue,PrismReferenceDefinition>> - Specified by:
cloneComplexin interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Specified by:
cloneComplexin interfacePrismReference- See Also:
-
getValue
Description copied from interface:ItemReturns the value, if there is only one. Throws exception if there are more values. If there is no value, this method either: - returns null (for properties) - throws an exception (for items that can hold multiple values) - creates an empty value (for containers and references). TODO think again whether getOrCreateValue would not be better- Specified by:
getValuein interfaceItem<PrismReferenceValue,PrismReferenceDefinition>
-
getHelp
Description copied from interface:ItemReturns help message defined for the item.Returns null if the help message cannot be determined.
The help message is fetched from the definition. If no definition (schema) is available, the help message will not be returned.
- Specified by:
getHelpin interfaceItem<PrismReferenceValue,PrismReferenceDefinition> - Returns:
- help message for the item
-
findReferencedItem
Description copied from interface:PrismReferenceTries to find referenced path (path starting with object derefence) in-memory. This works only for single-value references, whose value also contains embedded object. The search is performed on embedded object.- Specified by:
findReferencedItemin interfacePrismReference
-