Package com.evolveum.midpoint.prism.impl
Class PrismReferenceDefinitionImpl
java.lang.Object
com.evolveum.midpoint.prism.AbstractFreezable
com.evolveum.midpoint.prism.impl.schema.SchemaRegistryStateAware
com.evolveum.midpoint.prism.impl.DefinitionImpl
com.evolveum.midpoint.prism.impl.ItemDefinitionImpl<PrismReference>
com.evolveum.midpoint.prism.impl.PrismReferenceDefinitionImpl
- All Implemented Interfaces:
Definition,Definition.DefinitionBuilder,Definition.DefinitionMutator,DefinitionFragmentBuilder,Freezable,ItemDefinition<PrismReference>,ItemDefinition.ItemDefinitionLikeBuilder,ItemDefinition.ItemDefinitionMutator,LivePrismItemDefinition,PrismItemAccessDefinition,PrismItemAccessDefinition.Mutable,PrismItemBasicDefinition,PrismItemBasicDefinition.Mutable,PrismItemStorageDefinition,PrismItemStorageDefinition.Mutable,PrismLifecycleDefinition,PrismLifecycleDefinition.Mutable,PrismPresentationDefinition,PrismPresentationDefinition.Mutable,PrismReferenceDefinition,PrismReferenceDefinition.PrismReferenceDefinitionBuilder,PrismReferenceDefinition.PrismReferenceDefinitionMutator,Revivable,SchemaLookup.Aware,SerializableDefinition,SerializableItemDefinition,SerializableReferenceDefinition,SmartVisitable<Definition>,Visitable<Definition>,DebugDumpable,Serializable,Cloneable
public class PrismReferenceDefinitionImpl
extends ItemDefinitionImpl<PrismReference>
implements PrismReferenceDefinition, PrismReferenceDefinition.PrismReferenceDefinitionBuilder, SerializableReferenceDefinition
Object Reference Schema Definition.
Object Reference is a property that describes reference to an object. It is
used to represent association between objects. For example reference from
User object to Account objects that belong to the user. The reference is a
simple uni-directional link using an OID as an identifier.
This type should be used for all object references so the implementations can
detect them and automatically resolve them.
This class represents schema definition for object reference. See
Definition for more details.- Author:
- Radovan Semancik
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.evolveum.midpoint.prism.Definition
Definition.DefinitionBuilder, Definition.DefinitionMutatorNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.ItemDefinition
ItemDefinition.ItemDefinitionLikeBuilder, ItemDefinition.ItemDefinitionMutatorNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinition
PrismItemAccessDefinition.Data, PrismItemAccessDefinition.Delegable, PrismItemAccessDefinition.Info, PrismItemAccessDefinition.MutableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinition.Mutable
PrismItemAccessDefinition.Mutable.DelegableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemBasicDefinition
PrismItemBasicDefinition.Data, PrismItemBasicDefinition.Delegable, PrismItemBasicDefinition.MutableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemBasicDefinition.Mutable
PrismItemBasicDefinition.Mutable.DelegableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemStorageDefinition
PrismItemStorageDefinition.MutableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismLifecycleDefinition
PrismLifecycleDefinition.Data, PrismLifecycleDefinition.Delegable, PrismLifecycleDefinition.MutableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismLifecycleDefinition.Mutable
PrismLifecycleDefinition.Mutable.DelegableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismPresentationDefinition
PrismPresentationDefinition.Data, PrismPresentationDefinition.Delegable, PrismPresentationDefinition.MutableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismPresentationDefinition.Mutable
PrismPresentationDefinition.Mutable.DelegableNested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismReferenceDefinition
PrismReferenceDefinition.PrismReferenceDefinitionBuilder, PrismReferenceDefinition.PrismReferenceDefinitionMutator -
Field Summary
Fields inherited from class com.evolveum.midpoint.prism.impl.ItemDefinitionImpl
heterogeneousListItem, itemName, processing, substitutionHeadFields inherited from class com.evolveum.midpoint.prism.impl.DefinitionImpl
deprecated, deprecatedSince, displayHint, displayName, displayOrder, documentation, elaborate, emphasized, experimental, help, isAbstract, isRuntimeSchema, plannedRemoval, removed, removedSince, typeNameFields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING -
Constructor Summary
ConstructorsConstructorDescriptionPrismReferenceDefinitionImpl(QName elementName, QName typeName) PrismReferenceDefinitionImpl(QName elementName, QName typeName, QName definedInType) -
Method Summary
Modifier and TypeMethodDescription@NotNull PrismReferenceDefinitionclone()@NotNull PrismReferenceDefinitioncloneWithNewName(@NotNull ItemName itemName) Returns a clone of this definition, but with name changed to the provided one.protected void@NotNull ReferenceDeltacreateEmptyDelta(ItemPath path) Creates an empty delta (with appropriate implementation class), pointing to this item definition, with a given path.protected void<T extends ItemDefinition<?>>
TfindItemDefinition(@NotNull ItemPath path, @NotNull Class<T> clazz) Used to find a matching item definition _within_ this definition.Return a human-readable name of this class suitable for logs.Returns human-readable name of this class suitable for documentation.@Nullable SchemaContextDefinition@Nullable PrismObjectDefinition<?>Returns a definition applicable to the target of this reference.Returns valid XSD object types whose may be the targets of the reference.Returns a compile-time class that is used to represent items.@NotNull PrismReferenceCreate an item instance.@NotNull PrismReferenceinstantiate(QName name) Create an item instance.booleanmutator()Returns an interface to mutate this definition.voidsetComposite(boolean isComposite) voidsetTargetObjectDefinition(PrismObjectDefinition<?> targetObjectDefinition) voidsetTargetTypeName(QName targetTypeName) Returns complex type definition of item, if underlying value is possible structured.Methods inherited from class com.evolveum.midpoint.prism.impl.ItemDefinitionImpl
canAdd, canModify, canRead, copyDefinitionDataFrom, debugDisplayOrder, debugDumpShortToString, debugFlags, debugMultiplicity, deepClone, equals, getItemName, getMaxOccurs, getMergerInstance, getMinOccurs, getObjectBuilt, getProcessing, getSubstitutionHead, getValueEnumerationRef, hashCode, isAlwaysUseForEquals, isDynamic, isHeterogeneousListItem, isIndexed, isIndexOnly, isInherited, isOperational, isSearchable, isValidFor, revive, setAlwaysUseForEquals, setCanAdd, setCanModify, setCanRead, setDynamic, setHeterogeneousListItem, setIndexed, setIndexOnly, setInherited, setMaxOccurs, setMinOccurs, setOperational, setProcessing, setReadOnly, setSearchable, setSubstitutionHead, setValueEnumerationRef, toString, useSerializationProxy, writeReplaceMethods inherited from class com.evolveum.midpoint.prism.impl.DefinitionImpl
accept, accept, addSchemaMigration, copyDefinitionDataFrom, debugDump, extendDumpHeader, getAnnotation, getAnnotation, getAnnotations, getDeprecatedSince, getDiagrams, getDisplayHint, getDisplayName, getDisplayOrder, getDocumentation, getDocumentationPreview, getHelp, getMergerIdentifier, getNaturalKeyConstituents, getNaturalKeyInstance, getPlannedRemoval, getRemovedSince, getSchemaMigrations, getTypeName, isAbstract, isDeprecated, isElaborate, isEmphasized, isExperimental, isOptionalCleanup, isRemoved, isRuntimeSchema, setAbstract, setAnnotation, setDeprecated, setDeprecatedSince, setDiagrams, setDisplayHint, setDisplayName, setDisplayOrder, setDocumentation, setElaborate, setEmphasized, setExperimental, setHelp, setMergerIdentifier, setNaturalKeyConstituents, setOptionalCleanup, setPlannedRemoval, setRemoved, setRemovedSince, setRuntimeSchema, setSchemaContextDefinition, setSchemaMigrationsMethods inherited from class com.evolveum.midpoint.prism.impl.schema.SchemaRegistryStateAware
performFreeze, schemaLookup, setSchemaLookupMethods inherited from class com.evolveum.midpoint.prism.AbstractFreezable
freeze, freeze, freezeAll, freezeNullableList, isImmutable, isMutableMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDump, debugDumpLazily, debugDumpLazilyMethods inherited from interface com.evolveum.midpoint.prism.Definition
checkMutableOnExposing, debugDump, getAnnotation, getAnnotations, getMergerIdentifier, getMergerInstance, getMutabilityFlag, getNaturalKeyConstituents, getNaturalKeyInstance, getTypeName, isAbstract, isElaborate, isOptionalCleanup, isRuntimeSchemaMethods inherited from interface com.evolveum.midpoint.prism.Definition.DefinitionMutator
setAnnotation, setMergerIdentifier, setNaturalKeyConstituents, setOptionalCleanup, setRuntimeSchema, setSchemaContextDefinitionMethods inherited from interface com.evolveum.midpoint.prism.DefinitionFragmentBuilder
getObjectBuiltMethods inherited from interface com.evolveum.midpoint.prism.Freezable
checkImmutable, checkMutable, freeze, isImmutableMethods inherited from interface com.evolveum.midpoint.prism.ItemDefinition
debugDumpShortToString, deepClone, getProcessing, getSubstitutionHead, getValueEnumerationRef, isAlwaysUseForEquals, isDynamic, isHeterogeneousListItem, isIgnored, isInherited, isOperationalMethods inherited from interface com.evolveum.midpoint.prism.ItemDefinition.ItemDefinitionLikeBuilder
getExtraFeaturesToParseMethods inherited from interface com.evolveum.midpoint.prism.ItemDefinition.ItemDefinitionMutator
setAlwaysUseForEquals, setDeprecatedSince, setDynamic, setElaborate, setHeterogeneousListItem, setIgnored, setIndexOnly, setInherited, setOperational, setPlannedRemoval, setProcessing, setReadOnly, setSearchable, setSubstitutionHead, setValueEnumerationRefMethods inherited from interface com.evolveum.midpoint.prism.LivePrismItemDefinition
isValidForMethods inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinition
canAdd, canModify, canRead, getInfoMethods inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinition.Mutable
setCanAdd, setCanModify, setCanRead, setInfoMethods inherited from interface com.evolveum.midpoint.prism.PrismItemBasicDefinition
getItemName, getMaxOccurs, getMinOccurs, getTypeName, isMandatory, isMultiValue, isOptional, isSingleValueMethods inherited from interface com.evolveum.midpoint.prism.PrismItemBasicDefinition.Mutable
setMaxOccurs, setMinOccursMethods inherited from interface com.evolveum.midpoint.prism.PrismItemStorageDefinition
isIndexed, isIndexOnly, isSearchableMethods inherited from interface com.evolveum.midpoint.prism.PrismItemStorageDefinition.Mutable
setIndexedMethods inherited from interface com.evolveum.midpoint.prism.PrismLifecycleDefinition
getDeprecatedSince, getPlannedRemoval, getRemovedSince, getSchemaMigrations, isDeprecated, isExperimental, isRemovedMethods inherited from interface com.evolveum.midpoint.prism.PrismLifecycleDefinition.Mutable
addSchemaMigration, setDeprecated, setExperimental, setRemoved, setRemovedSince, setSchemaMigrationsMethods inherited from interface com.evolveum.midpoint.prism.PrismPresentationDefinition
getDiagrams, getDisplayHint, getDisplayName, getDisplayOrder, getDocumentation, getDocumentationPreview, getHelp, isEmphasizedMethods inherited from interface com.evolveum.midpoint.prism.PrismPresentationDefinition.Mutable
setDiagrams, setDisplayHint, setDisplayName, setDisplayOrder, setDocumentation, setEmphasized, setHelpMethods inherited from interface com.evolveum.midpoint.prism.PrismReferenceDefinition
migrateIfNeededMethods inherited from interface com.evolveum.midpoint.prism.schema.SchemaLookup.Aware
schemaLookupMethods inherited from interface com.evolveum.midpoint.prism.schema.SerializableDefinition
getDisplayHint, getDisplayName, getDisplayOrder, getDocumentation, getExtraFeaturesToSerialize, getHelp, isEmphasizedMethods inherited from interface com.evolveum.midpoint.prism.schema.SerializableItemDefinition
getItemName, getMaxOccurs, getMinOccurs, getProcessing, getTypeName, isIndexed, isOperationalMethods inherited from interface com.evolveum.midpoint.prism.SmartVisitable
accept
-
Constructor Details
-
PrismReferenceDefinitionImpl
-
PrismReferenceDefinitionImpl
-
-
Method Details
-
getTargetTypeName
Returns valid XSD object types whose may be the targets of the reference. Corresponds to "targetType" XSD annotation. Returns empty set if not specified. Must not return null.- Specified by:
getTargetTypeNamein interfacePrismReferenceDefinition- Specified by:
getTargetTypeNamein interfaceSerializableReferenceDefinition- Returns:
- set of target type names
-
setTargetTypeName
- Specified by:
setTargetTypeNamein interfacePrismReferenceDefinition.PrismReferenceDefinitionMutator
-
getTargetObjectDefinition
Description copied from interface:PrismReferenceDefinitionReturns a definition applicable to the target of this reference. Introduced to support shadow association definitions in midPoint: it applies to `ShadowAssociationValueType.shadowRef`.- Specified by:
getTargetObjectDefinitionin interfacePrismReferenceDefinition
-
setTargetObjectDefinition
- Specified by:
setTargetObjectDefinitionin interfacePrismReferenceDefinition.PrismReferenceDefinitionMutator
-
isComposite
public boolean isComposite()- Specified by:
isCompositein interfacePrismReferenceDefinition- Specified by:
isCompositein interfaceSerializableReferenceDefinition
-
setComposite
public void setComposite(boolean isComposite) - Specified by:
setCompositein interfacePrismReferenceDefinition.PrismReferenceDefinitionMutator
-
findItemDefinition
public <T extends ItemDefinition<?>> T findItemDefinition(@NotNull @NotNull ItemPath path, @NotNull @NotNull Class<T> clazz) Description copied from interface:LivePrismItemDefinitionUsed to find a matching item definition _within_ this definition. Treats e.g. de-referencing in prism references.- Specified by:
findItemDefinitionin interfaceLivePrismItemDefinition- Overrides:
findItemDefinitionin classItemDefinitionImpl<PrismReference>
-
instantiate
Description copied from interface:ItemDefinitionCreate an item instance. Definition name or default name will be used as an element name for the instance. The instance will otherwise be empty.- Specified by:
instantiatein interfaceItemDefinition<PrismReference>- Specified by:
instantiatein interfacePrismReferenceDefinition
-
instantiate
Description copied from interface:ItemDefinitionCreate an item instance. Definition name will use provided name. for the instance. The instance will otherwise be empty.- Specified by:
instantiatein interfaceItemDefinition<PrismReference>- Specified by:
instantiatein interfacePrismReferenceDefinition
-
createEmptyDelta
Description copied from interface:ItemDefinitionCreates an empty delta (with appropriate implementation class), pointing to this item definition, with a given path.- Specified by:
createEmptyDeltain interfaceItemDefinition<PrismReference>
-
getTypeClass
Description copied from interface:DefinitionReturns a compile-time class that is used to represent items. E.g. returns String, Integer, subclasses of Objectable and Containerable and so on.- Specified by:
getTypeClassin interfaceDefinition
-
mutator
Description copied from interface:DefinitionReturns an interface to mutate this definition.- Specified by:
mutatorin interfaceDefinition- Specified by:
mutatorin interfaceItemDefinition<PrismReference>- Specified by:
mutatorin interfacePrismReferenceDefinition
-
clone
- Specified by:
clonein interfaceDefinition- Specified by:
clonein interfaceItemDefinition<PrismReference>- Specified by:
clonein interfacePrismReferenceDefinition- Specified by:
clonein classItemDefinitionImpl<PrismReference>
-
cloneWithNewName
@NotNull public @NotNull PrismReferenceDefinition cloneWithNewName(@NotNull @NotNull ItemName itemName) Description copied from interface:ItemDefinitionReturns a clone of this definition, but with name changed to the provided one.- Specified by:
cloneWithNewNamein interfaceItemDefinition<PrismReference>- See Also:
-
copyDefinitionDataFrom
-
getDebugDumpClassName
Return a human-readable name of this class suitable for logs.- Specified by:
getDebugDumpClassNamein classDefinitionImpl
-
getDocClassName
Description copied from class:DefinitionImplReturns human-readable name of this class suitable for documentation. (e.g. "property")- Specified by:
getDocClassNamein classDefinitionImpl
-
extendToString
- Overrides:
extendToStringin classItemDefinitionImpl<PrismReference>
-
structuredType
Description copied from interface:ItemDefinitionReturns complex type definition of item, if underlying value is possible structured. NOTE: This seems weird, since properties and references are simple values, but actually object reference is serialized as structured value and some of properties are also.- Specified by:
structuredTypein interfaceItemDefinition<PrismReference>
-
getSchemaContextDefinition
- Specified by:
getSchemaContextDefinitionin interfaceDefinition- Overrides:
getSchemaContextDefinitionin classDefinitionImpl
-