Class SynchronizationContext<F extends FocusType>
- java.lang.Object
-
- com.evolveum.midpoint.model.impl.sync.SynchronizationContext<F>
-
- Type Parameters:
F
- Type of the matching focus object
- All Implemented Interfaces:
PreInboundsContext<F>
,ResourceObjectProcessingContext
,DebugDumpable
- Direct Known Subclasses:
SynchronizationContext.Complete
public abstract class SynchronizationContext<F extends FocusType> extends Object implements PreInboundsContext<F>, ResourceObjectProcessingContext
Context of the synchronization operation. It is created in the early stages ofResourceObjectShadowChangeDescription
progressing inSynchronizationServiceImpl
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SynchronizationContext.Complete<F extends FocusType>
Synchronization context ready for the synchronization, i.e.
-
Field Summary
-
Fields inherited from interface com.evolveum.midpoint.util.DebugDumpable
INDENT_STRING
-
-
Constructor Summary
Constructors Constructor Description SynchronizationContext(@NotNull ResourceObjectShadowChangeDescription change, @NotNull ResourceObjectProcessingContextImpl processingContext, @Nullable ResourceObjectTypeIdentification typeIdentification, @Nullable ResourceObjectDefinition objectDefinition, @Nullable SynchronizationPolicy synchronizationPolicy, @Nullable ObjectSynchronizationDiscriminatorType sorterResult, @Nullable String tag)
-
Method Summary
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.evolveum.midpoint.util.DebugDumpable
debugDump, debugDumpLazily, debugDumpLazily
-
Methods inherited from interface com.evolveum.midpoint.model.impl.ResourceObjectProcessingContext
createDefaultVariablesMap
-
-
-
-
Constructor Detail
-
SynchronizationContext
public SynchronizationContext(@NotNull @NotNull ResourceObjectShadowChangeDescription change, @NotNull @NotNull ResourceObjectProcessingContextImpl processingContext, @Nullable @Nullable ResourceObjectTypeIdentification typeIdentification, @Nullable @Nullable ResourceObjectDefinition objectDefinition, @Nullable @Nullable SynchronizationPolicy synchronizationPolicy, @Nullable @Nullable ObjectSynchronizationDiscriminatorType sorterResult, @Nullable @Nullable String tag)
-
-
Method Detail
-
isProtected
public boolean isProtected()
-
getTypeIdentification
@Nullable public @Nullable ResourceObjectTypeIdentification getTypeIdentification()
Returns the identification of the (determined) type definition - or null if the type is not known. Note that it's not necessary to look at the shadow kind/intent if this method returns `null`, because this type is derived directly from the values in the shadow. It can be even more precise, because the shadow may be unclassified when this context is created.
-
getCorrelationContext
public CorrelationContext getCorrelationContext()
-
setCorrelationContext
public void setCorrelationContext(CorrelationContext correlationContext)
-
getObjectDefinitionRequired
@NotNull public @NotNull ResourceObjectDefinition getObjectDefinitionRequired()
- Specified by:
getObjectDefinitionRequired
in interfacePreInboundsContext<F extends FocusType>
-
getTag
public String getTag()
-
createVariablesMap
@NotNull public @NotNull VariablesMap createVariablesMap()
Description copied from interface:ResourceObjectProcessingContext
ReturnsVariablesMap
relevant for the current context.- Specified by:
createVariablesMap
in interfaceResourceObjectProcessingContext
-
getSynchronizationPolicyRequired
@NotNull public @NotNull SynchronizationPolicy getSynchronizationPolicyRequired()
-
getShadowedResourceObject
@NotNull public @NotNull ShadowType getShadowedResourceObject()
Description copied from interface:ResourceObjectProcessingContext
Returns shadowed resource object, or - at least - so-called "combined object" in the sense used in ResourceObjectClassifier FIXME- Specified by:
getShadowedResourceObject
in interfaceResourceObjectProcessingContext
-
getShadowOid
public String getShadowOid()
Normally should be non-null, but we are not sure enough to mark as NotNull.
-
getResourceObjectDelta
@Nullable public @Nullable ObjectDelta<ShadowType> getResourceObjectDelta()
- Specified by:
getResourceObjectDelta
in interfacePreInboundsContext<F extends FocusType>
- Specified by:
getResourceObjectDelta
in interfaceResourceObjectProcessingContext
-
getResource
@NotNull public @NotNull ResourceType getResource()
- Specified by:
getResource
in interfaceResourceObjectProcessingContext
-
getResourceOid
@NotNull public @NotNull String getResourceOid()
-
getFocusClass
@NotNull public @NotNull Class<F> getFocusClass() throws SchemaException
- Throws:
SchemaException
-
getArchetypeOid
@Nullable public @Nullable String getArchetypeOid()
Description copied from interface:PreInboundsContext
Returns the archetype OID bound to the object type. Archetypes determined from the focus itself are not returned here.- Specified by:
getArchetypeOid
in interfacePreInboundsContext<F extends FocusType>
-
getPreFocus
@NotNull public F getPreFocus()
- Specified by:
getPreFocus
in interfacePreInboundsContext<F extends FocusType>
-
getPreFocusAsPrismObject
@NotNull public @NotNull PrismObject<F> getPreFocusAsPrismObject()
- Specified by:
getPreFocusAsPrismObject
in interfacePreInboundsContext<F extends FocusType>
-
getLinkedOwner
public F getLinkedOwner()
-
getCorrelatedOwner
public F getCorrelatedOwner()
-
getSituation
public SynchronizationSituationType getSituation()
-
getSystemConfiguration
@Nullable public @Nullable SystemConfigurationType getSystemConfiguration()
- Specified by:
getSystemConfiguration
in interfaceResourceObjectProcessingContext
-
getChannel
public String getChannel()
Description copied from interface:ResourceObjectProcessingContext
Returns the channel relevant to the current operation. It may be a channel fromResourceObjectShadowChangeDescription
or from a task.- Specified by:
getChannel
in interfaceResourceObjectProcessingContext
-
getExpressionProfile
public ExpressionProfile getExpressionProfile()
-
getTask
@NotNull public @NotNull Task getTask()
- Specified by:
getTask
in interfaceResourceObjectProcessingContext
-
isShadowExistsInRepo
public boolean isShadowExistsInRepo()
-
setShadowExistsInRepo
public void setShadowExistsInRepo(boolean shadowExistsInRepo)
-
getItemProcessingIdentifier
public String getItemProcessingIdentifier()
-
debugDump
public String debugDump(int indent)
- Specified by:
debugDump
in interfaceDebugDumpable
-
setSkipMaintenanceCheck
public static void setSkipMaintenanceCheck(boolean skipMaintenanceCheck)
-
getBeans
@NotNull public @NotNull ModelBeans getBeans()
Description copied from interface:ResourceObjectProcessingContext
Useful Spring beans.- Specified by:
getBeans
in interfaceResourceObjectProcessingContext
-
getExecutionMode
@NotNull public @NotNull ExecutionModeType getExecutionMode()
-
isDryRun
public boolean isDryRun()
-
getChange
@NotNull public @NotNull ResourceObjectShadowChangeDescription getChange()
-
isComplete
public abstract boolean isComplete()
-
isVisible
public boolean isVisible()
-
-