Class LensFocusContext<O extends ObjectType>
java.lang.Object
com.evolveum.midpoint.model.impl.lens.LensElementContext<O>
com.evolveum.midpoint.model.impl.lens.LensFocusContext<O>
- All Implemented Interfaces:
ModelElementContext<O>,DebugDumpable,Serializable,Cloneable
- Author:
- semancik
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.evolveum.midpoint.model.impl.lens.LensElementContext
LensElementContext.DeltaModifier<O extends Objectable> -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanTrue if the focus object was deleted by our processing.Fields inherited from class com.evolveum.midpoint.model.impl.lens.LensElementContext
lensContextFields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcheckConsistence(String desc) voidcleanup()Cleans up the contexts by removing some of the working state.clone(LensContext<O> lensContext) debugDump(int indent) voidTODO is this method ever used?TODO is this method ever used?@NotNull AssignmentIdStoreprotected String@NotNull String@NotNull IdentityManagementConfiguration@NotNull IndexingConfiguration@NotNull PathKeyedMap<ObjectTemplateItemDefinitionType>@NotNull LensContext<O>@NotNull ObjectDeltaObject<O>@NotNull ObjectDeltaObject<O>Returns object-delta-object structure based on the current state.getSourceLinkTypeDefinition(@NotNull String linkTypeName, LinkManager linkManager, OperationResult result) The "object old" represents the state "before operation" for focus objects precisely.Precondition: context is "complete" i.e.Returns all secondary deltas, merged together.getTargetLinkTypeDefinition(@NotNull String linkTypeName, LinkManager linkManager, OperationResult result) booleanReturns true if there is any change in organization membership.booleanisAdd()Be cautious when using this method forLensProjectionContext.booleanisDelete()See also limitations forLensElementContext.isAdd().booleanbooleanbooleanDifferent fromisAdd()just to have a clear meaning.voidvoidsetArchetypes(List<ArchetypeType> archetypes) voidvoidsetExpandedFocusTemplate(ObjectTemplateType expandedFocusTemplate) voidsetFocusTemplate(ObjectTemplateType focusTemplate) voidsetItemDefinitionsMap(@NotNull PathKeyedMap<ObjectTemplateItemDefinitionType> itemDefinitionsMap) voidsetLoadedObject(@NotNull PrismObject<O> object) Sets current and possibly also old object.voidOnly for internal use!voidswallowToWave0SecondaryDelta(ItemDelta<?, ?> itemDelta) Deprecated.toString()Methods inherited from class com.evolveum.midpoint.model.impl.lens.LensElementContext
addToExecutedDeltas, addToPendingAssignmentPolicyStateModifications, addToPendingObjectPolicyStateModifications, addToPrimaryDelta, adopt, checkConsistence, checkEncrypted, clearCurrentObject, clearPendingPolicyStateModifications, deleteNonTransientComputationResults, forEachDelta, forEachObject, getAllConsideredEventMarksOids, getCredentialsPolicy, getCurrentDelta, getElementDesc, getExecutedDeltas, getItemChangeApplicationModeConfiguration, getIteration, getIterationToken, getMatchingEventMarksOids, getModelContext, getObjectCurrent, getObjectCurrentOrNew, getObjectCurrentOrOld, getObjectDefinition, getObjectNew, getObjectNewOrCurrentOrOld, getObjectNewOrCurrentRequired, getObjectNewRequired, getObjectOld, getObjectPolicyRules, getObjectReadVersion, getObjectTypeClass, getOid, getOperation, getPendingAssignmentPolicyStateModifications, getPendingObjectPolicyStateModifications, getPolicyRuleCounter, getPrimaryDelta, getSecondaryDelta, getSecurityPolicy, getSummaryDelta, getSummaryExecutedDelta, getTemporaryContainerId, initializeElementState, isFresh, isModifiedInCurrentDelta, isModify, isOfType, modifyPrimaryDelta, normalize, operationMatches, recompute, rememberElementState, replaceOldAndCurrentObject, represents, resolveTemporaryContainerIds, restoreElementState, rot, setCurrentObject, setCurrentObjectAndOid, setEstimatedOldValuesInPrimaryDelta, setFresh, setInitialObject, setIteration, setIterationToken, setObjectPolicyRules, setOid, setPolicyRuleCounter, setPrimaryDelta, setPrimaryDeltaAfterStart, setSecurityPolicy, setupLastChangeExecutionResult, simulateDeltaExecution, swallowToPrimaryDelta, swallowToSecondaryDelta, swallowToSecondaryDelta, swallowToSecondaryDeltaUnchecked, wasAddExecutedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazilyMethods inherited from interface com.evolveum.midpoint.model.api.context.ModelElementContext
getObjectAny, getObjectAnyRequired, getObjectOldOrCurrent
-
Field Details
-
deleted
protected boolean deletedTrue if the focus object was deleted by our processing. (Note we do not currently provide this kind of flag on the projection contexts, because of not being sure if deleted projection cannot be somehow "resurrected" during the processing. For focal objects nothing like this should happen.) Used to clarify context (re)loading for deleted focus situations. See MID-4856.
-
-
Constructor Details
-
LensFocusContext
-
-
Method Details
-
setLoadedObject
Description copied from class:LensElementContextSets current and possibly also old object. This method is used with freshly loaded object. The object is set as current object. If the old object should be initialized, then the object is also set as old object. Should be used only from the context loader!- Specified by:
setLoadedObjectin classLensElementContext<O extends ObjectType>
-
setRewriteOldObject
public void setRewriteOldObject()Only for internal use! -
getArchetypePolicy
-
setArchetypePolicy
-
getArchetype
Description copied from interface:ModelElementContextTODO is this method ever used?- Returns:
- Determined archetype of the object. Currently not supported for projections. Since 4.4 structural archetype is returned
-
getArchetypes
Description copied from interface:ModelElementContextTODO is this method ever used?- Returns:
- All archetypes (structural and auxiliary)
-
setArchetypes
-
getStructuralArchetypeRef
Precondition: context is "complete" i.e.archetypesare filled in.- Throws:
SchemaException
-
getFocusTemplate
-
setFocusTemplate
-
setExpandedFocusTemplate
-
isFocusTemplateSetExplicitly
public boolean isFocusTemplateSetExplicitly() -
getIdentityManagementConfiguration
@NotNull public @NotNull IdentityManagementConfiguration getIdentityManagementConfiguration() throws ConfigurationException- Throws:
ConfigurationException
-
getIndexingConfiguration
@NotNull public @NotNull IndexingConfiguration getIndexingConfiguration() throws ConfigurationException- Throws:
ConfigurationException
-
getLifecycleModel
-
isDelete
public boolean isDelete()Description copied from class:LensElementContextSee also limitations forLensElementContext.isAdd().- Specified by:
isDeletein interfaceModelElementContext<O extends ObjectType>- Specified by:
isDeletein classLensElementContext<O extends ObjectType>
-
getSummarySecondaryDelta
Description copied from interface:ModelElementContextReturns all secondary deltas, merged together. (Can take some time to compute. So use with care.) The returned object is (kind of) immutable. Changing it may do strange things, but most likely the changes will be lost. -
isAdd
public boolean isAdd()Description copied from class:LensElementContextBe cautious when using this method forLensProjectionContext. The projection may be called into existence because a construction is assigned - i.e., no primary delta exists in this case. But the policy decision can also be null: untilActivationProcessor.processProjectionsActivation(LensContext, String, XMLGregorianCalendar, Task, OperationResult)is started - e.g. during the whole focus projection! See also MID-8569. Other problems: If there's no focus, then we don't compute theLensProjectionContext.synchronizationPolicyDecisionat all. See MID-8608 and its fix. It is very unclear and should be clarified.- Specified by:
isAddin interfaceModelElementContext<O extends ObjectType>- Specified by:
isAddin classLensElementContext<O extends ObjectType>
-
isPrimaryAdd
public boolean isPrimaryAdd()Different fromisAdd()just to have a clear meaning. -
isDeleted
public boolean isDeleted() -
setDeleted
public void setDeleted() -
getObjectDeltaObjectRelative
Returns object-delta-object structure based on the current state. I.e. objectCurrent - currentDelta - objectNew. -
getObjectDeltaObjectAbsolute
-
swallowToWave0SecondaryDelta
@Deprecated public void swallowToWave0SecondaryDelta(ItemDelta<?, ?> itemDelta) throws SchemaExceptionDeprecated.- Throws:
SchemaException
-
cleanup
public void cleanup()Description copied from class:LensElementContextCleans up the contexts by removing some of the working state. TODO describe more precisely, see alsoLensElementContext.rot(),updateDeltasAfterExecution(), andLensContext.updateAfterExecution()- Specified by:
cleanupin classLensElementContext<O extends ObjectType>
-
hasOrganizationalChange
public boolean hasOrganizationalChange()Returns true if there is any change in organization membership. I.e. in case that there is a change in parentOrgRef. -
clone
-
debugDump
-
getElementDefaultDesc
- Specified by:
getElementDefaultDescin classLensElementContext<O extends ObjectType>
-
toString
-
getHumanReadableName
- Specified by:
getHumanReadableNamein classLensElementContext<O extends ObjectType>
-
checkConsistence
- Specified by:
checkConsistencein classLensElementContext<O extends ObjectType>
-
setItemDefinitionsMap
public void setItemDefinitionsMap(@NotNull @NotNull PathKeyedMap<ObjectTemplateItemDefinitionType> itemDefinitionsMap) -
getItemDefinitionsMap
-
getSourceLinkTypeDefinition
public LinkTypeDefinitionType getSourceLinkTypeDefinition(@NotNull @NotNull String linkTypeName, LinkManager linkManager, OperationResult result) throws SchemaException, ConfigurationException -
getTargetLinkTypeDefinition
public LinkTypeDefinitionType getTargetLinkTypeDefinition(@NotNull @NotNull String linkTypeName, LinkManager linkManager, OperationResult result) throws SchemaException, ConfigurationException -
deleteEmptyPrimaryDelta
public void deleteEmptyPrimaryDelta() -
getLensContext
- Overrides:
getLensContextin classLensElementContext<O extends ObjectType>
-
getStateBeforeSimulatedOperation
The "object old" represents the state "before operation" for focus objects precisely.- Specified by:
getStateBeforeSimulatedOperationin classLensElementContext<O extends ObjectType>
-
getAssignmentIdStore
-