Package com.evolveum.midpoint.prism
Interface ItemDefinition<I extends Item>
- 
- All Superinterfaces:
- Cloneable,- DebugDumpable,- Definition,- Freezable,- PrismContextSensitive,- PrismItemAccessDefinition,- Revivable,- Serializable,- SmartVisitable<Definition>,- Visitable<Definition>
 - All Known Subinterfaces:
- AttributeContainerDefinitionDelegator,- AttributeDefinitionDelegator<T>,- ContainerDefinitionDelegator<C>,- ItemDefinitionDelegator<I>,- ItemWrapper<I,VW>,- MutableItemDefinition<I>,- MutablePrismContainerDefinition<C>,- MutablePrismObjectDefinition<O>,- MutablePrismPropertyDefinition<T>,- MutablePrismReferenceDefinition,- MutableRawResourceAttributeDefinition<T>,- ObjectDefinitionDelegator<O>,- PrismContainerDefinition<C>,- PrismContainerWrapper<C>,- PrismObjectDefinition<O>,- PrismObjectWrapper<O>,- PrismPropertyDefinition<T>,- PrismPropertyWrapper<T>,- PrismReferenceDefinition,- PrismReferenceWrapper<R>,- PropertyDefinitionDelegator<T>,- RawResourceAttributeDefinition<T>,- ReferenceDefinitionDelegator,- RefinedAttributeDefinitionDelegator<T>,- ResourceAttributeContainerDefinition,- ResourceAttributeDefinition<T>,- ResourceAttributeWrapper<T>,- ShadowWrapper
 - All Known Implementing Classes:
- CaseWorkItemTypeWrapper,- ExpressionWrapper,- com.evolveum.midpoint.prism.impl.ItemDefinitionImpl,- ItemWrapperImpl,- com.evolveum.midpoint.prism.impl.PrismContainerDefinitionImpl,- PrismContainerWrapperImpl,- PrismObjectWrapperImpl,- com.evolveum.midpoint.prism.impl.PrismPropertyDefinitionImpl,- PrismPropertyWrapperImpl,- PrismReferenceWrapperImpl,- ProfilingClassLoggerContainerWrapperImpl,- ProtectedStringTypeWrapperImpl,- RawResourceAttributeDefinitionImpl,- ResourceAttributeContainerDefinitionImpl,- ResourceAttributeDefinitionImpl,- ResourceAttributeMappingWrapper,- ResourceAttributeWrapperImpl,- ResourceWrapper,- ShadowAssociationWrapperImpl,- ShadowWrapperImpl,- ValueMetadataWrapperImpl
 
 public interface ItemDefinition<I extends Item> extends Definition, PrismItemAccessDefinition A definition of a specific item (as opposed to a type).- See Also:
- TypeDefinition
 
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinitionPrismItemAccessDefinition.Mutable
 
- 
 - 
Field Summary- 
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpableINDENT_STRING
 
- 
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description voidadoptElementDefinitionFrom(ItemDefinition<?> otherDef)Transfers selected parts of the definition (currently item name, min/max occurs) from another definition.booleancanBeDefinitionOf(PrismValue pvalue)TODO documentbooleancanBeDefinitionOf(I item)TODO document@NotNull ItemDefinition<I>clone()@NotNull ItemDelta<?,?>createEmptyDelta(ItemPath path)Creates an empty delta (with appropriate implementation class), pointing to this item definition, with a given path.voiddebugDumpShortToString(StringBuilder sb)Used in debugDumping items.ItemDefinition<I>deepClone(@NotNull DeepCloneOperation operation)TODO document<T extends ItemDefinition<?>>
 TfindItemDefinition(@NotNull ItemPath path, @NotNull Class<T> clazz)Used to find a matching item definition _within_ this definition.@NotNull ItemNamegetItemName()Gets the "canonical" name of the item for the definition.intgetMaxOccurs()Return the number of maximal value occurrences.intgetMinOccurs()Return the number of minimal value occurrences.QNamegetSubstitutionHead()Returns the name of an element this one can be substituted for (e.g.PrismReferenceValuegetValueEnumerationRef()Reference to an object that directly or indirectly represents possible values for this item.Iinstantiate()Create an item instance.Iinstantiate(QName name)Create an item instance.booleanisDynamic()Returns true if definition was created during the runtime based on a dynamic information such as xsi:type attributes in XML.booleanisHeterogeneousListItem()Can be used in heterogeneous lists as a list item.booleanisIndexOnly()If true, this item is not stored in XML representation in repo.booleanisInherited()Whether the item is inherited from a supertype.default booleanisMandatory()default booleanisMultiValue()booleanisOperational()Marks operational item.default booleanisOptional()default booleanisSingleValue()booleanisValidFor(@NotNull QName elementQName, @NotNull Class<? extends ItemDefinition<?>> clazz, boolean caseInsensitive)Returns true if this definition is valid for given element name and definition class, in either case-sensitive (the default) or case-insensitive way.Optional<ComplexTypeDefinition>structuredType()Returns complex type definition of item, if underlying value is possible structured.MutableItemDefinition<I>toMutable()Returns an interface to mutate this definition.- 
Methods inherited from interface com.evolveum.midpoint.util.DebugDumpabledebugDump, debugDump, debugDumpLazily, debugDumpLazily
 - 
Methods inherited from interface com.evolveum.midpoint.prism.DefinitiondebugDump, getAnnotation, getAnnotations, getDeprecatedSince, getDiagrams, getDisplayName, getDisplayOrder, getDocumentation, getDocumentationPreview, getHelp, getMutabilityFlag, getPlannedRemoval, getProcessing, getSchemaMigrations, getSchemaRegistry, getTypeClass, getTypeName, isAbstract, isDeprecated, isElaborate, isEmphasized, isExperimental, isIgnored, isRuntimeSchema, setAnnotation
 - 
Methods inherited from interface com.evolveum.midpoint.prism.FreezablecheckImmutable, checkMutable, freeze, isImmutable
 - 
Methods inherited from interface com.evolveum.midpoint.prism.PrismContextSensitivegetPrismContext
 - 
Methods inherited from interface com.evolveum.midpoint.prism.PrismItemAccessDefinitioncanAdd, canModify, canRead
 - 
Methods inherited from interface com.evolveum.midpoint.prism.SmartVisitableaccept
 
- 
 
- 
- 
- 
Method Detail- 
getItemName@NotNull @NotNull ItemName getItemName() Gets the "canonical" name of the item for the definition. Should be qualified, if at all possible.
 - 
getMinOccursint getMinOccurs() Return the number of minimal value occurrences.
 - 
getMaxOccursint getMaxOccurs() Return the number of maximal value occurrences. Any negative number means "unbounded".
 - 
isSingleValuedefault boolean isSingleValue() 
 - 
isMultiValuedefault boolean isMultiValue() 
 - 
isMandatorydefault boolean isMandatory() 
 - 
isOptionaldefault boolean isOptional() 
 - 
isOperationalboolean isOperational() Marks operational item. Operational properties are auxiliary data (or meta-data) that are usually not modifiable by the end user. They are generated and maintained by the system. Operational items are also not usually displayed unless it is explicitly requested. The example of operational items are modification timestamps, create timestamps, user that made the last change, etc. They are also treated in a special way when comparing values. SeeParameterizedEquivalenceStrategy.
 - 
isIndexOnly@Experimental boolean isIndexOnly() If true, this item is not stored in XML representation in repo. TODO better name
 - 
isInheritedboolean isInherited() Whether the item is inherited from a supertype.
 - 
isDynamicboolean isDynamic() Returns true if definition was created during the runtime based on a dynamic information such as xsi:type attributes in XML. This means that the definition needs to be stored alongside the data to have a successful serialization "roundtrip". The definition is not part of any schema and therefore cannot be determined. It may even be different for every instance of the associated item (element name).
 - 
getSubstitutionHead@Experimental QName getSubstitutionHead() Returns the name of an element this one can be substituted for (e.g. c:user -> c:object, s:pipeline -> s:expression, etc). EXPERIMENTAL
 - 
isHeterogeneousListItem@Experimental boolean isHeterogeneousListItem() Can be used in heterogeneous lists as a list item. EXPERIMENTAL.
 - 
getValueEnumerationRefPrismReferenceValue getValueEnumerationRef() Reference to an object that directly or indirectly represents possible values for this item. We do not define here what exactly the object has to be. It can be a lookup table, script that dynamically produces the values or anything similar. The object must produce the values of the correct type for this item otherwise an error occurs.
 - 
isValidForboolean isValidFor(@NotNull @NotNull QName elementQName, @NotNull @NotNull Class<? extends ItemDefinition<?>> clazz, boolean caseInsensitive)Returns true if this definition is valid for given element name and definition class, in either case-sensitive (the default) or case-insensitive way. Used e.g. for "slow" path lookup where we iterate over all definitions in a complex type.
 - 
findItemDefinition<T extends ItemDefinition<?>> T findItemDefinition(@NotNull @NotNull ItemPath path, @NotNull @NotNull Class<T> clazz) Used to find a matching item definition _within_ this definition. Treats e.g. de-referencing in prism references.
 - 
adoptElementDefinitionFromvoid adoptElementDefinitionFrom(ItemDefinition<?> otherDef) Transfers selected parts of the definition (currently item name, min/max occurs) from another definition. TODO used only on few places, consider removing
 - 
instantiate@NotNull I instantiate() throws SchemaException Create an item instance. Definition name or default name will be used as an element name for the instance. The instance will otherwise be empty.- Throws:
- SchemaException
 
 - 
instantiate@NotNull I instantiate(QName name) throws SchemaException Create an item instance. Definition name will use provided name. for the instance. The instance will otherwise be empty.- Throws:
- SchemaException
 
 - 
createEmptyDelta@NotNull @NotNull ItemDelta<?,?> createEmptyDelta(ItemPath path) Creates an empty delta (with appropriate implementation class), pointing to this item definition, with a given path.
 - 
clone@NotNull @NotNull ItemDefinition<I> clone() - Specified by:
- clonein interface- Definition
 
 - 
deepCloneItemDefinition<I> deepClone(@NotNull @NotNull DeepCloneOperation operation) TODO document
 - 
debugDumpShortToStringvoid debugDumpShortToString(StringBuilder sb) Used in debugDumping items. Does not need to have name in it as item already has it. Does not need to have class as that is just too much info that is almost anytime pretty obvious anyway.
 - 
canBeDefinitionOfboolean canBeDefinitionOf(I item) TODO document
 - 
canBeDefinitionOfboolean canBeDefinitionOf(PrismValue pvalue) TODO document
 - 
toMutableMutableItemDefinition<I> toMutable() Description copied from interface:DefinitionReturns an interface to mutate this definition.- Specified by:
- toMutablein interface- Definition
 
 - 
structuredType@Experimental Optional<ComplexTypeDefinition> structuredType() Returns 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.
 
- 
 
-