Class WebModelServiceUtils
java.lang.Object
com.evolveum.midpoint.gui.api.util.WebModelServiceUtils
Utility class that contains methods that interact with ModelService and other
midPoint components.
- Author:
- lazyman
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
checkExpressionInFilter
(ObjectFilter filter) static <C extends Containerable>
intcountContainers
(Class<C> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, PageBase page) static <T extends ObjectType>
intcountObjects
(Class<T> type, ObjectQuery query, PageBase page) static <T extends ObjectType>
ObjectDelta<T>createActivationAdminStatusDelta
(Class<T> type, String oid, boolean enabled, PrismContext context) static Collection<SelectorOptions<GetOperationOptions>>
createLookupTableRetrieveOptions
(SchemaService schemaService) static <O extends ObjectType>
List<ObjectReferenceType>createObjectReferenceListForObjects
(PageBase page, List<PrismObject<O>> objects, Map<String, String> referenceMap) static <O extends ObjectType>
List<ObjectReferenceType>static Collection<SelectorOptions<GetOperationOptions>>
static Task
createSimpleTask
(String operation, PrismObject<? extends FocusType> owner, TaskManager manager) static Task
createSimpleTask
(String operation, String channel, PrismObject<? extends FocusType> owner, TaskManager manager) static <T extends ObjectType>
voiddeleteObject
(Class<T> type, String oid, ModelExecuteOptions options, OperationResult result, PageBase page) static <T extends ObjectType>
voiddeleteObject
(Class<T> type, String oid, ModelExecuteOptions options, OperationResult result, PageBase page, PrismObject<UserType> principal) static <T extends ObjectType>
voiddeleteObject
(Class<T> type, String oid, OperationResult result, PageBase page) static void
dropPowerOfAttorney
(ModelInteractionService modelInteractionService, TaskManager taskManager, OperationResult parentResult) static ActivationStatusType
getAssignmentEffectiveStatus
(String lifecycleStatus, ActivationType activationType, PageBase pageBase) getCertificationConfiguration
(PageBase pageBase) static FocusType
static String
static TimeZone
static boolean
static boolean
isEnableExperimentalFeature
(ModelInteractionService modelInteractionService, Task task, OperationResult result) static boolean
isEnableExperimentalFeature
(Task task, ModelServiceLocator pageBase) static boolean
isNoFetch
(Collection<SelectorOptions<GetOperationOptions>> options) static LookupTableType
loadLookupTable
(String lookupTableOid, PageBase pageBase) static <O extends ObjectType>
PrismObject<O>loadObject
(PrismReferenceValue objectRef, QName expectedTargetType, PageBase pageBase, Task task, OperationResult result) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Referencable objectReference, boolean allowNull, PageAdminLTE page, Task task, OperationResult result) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Referencable objectReference, PageAdminLTE page) static <T extends ObjectType>
PrismObject<T>loadObject
(Referencable objectReference, PageAdminLTE page, Task task, OperationResult result) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Referencable objectReference, Collection<SelectorOptions<GetOperationOptions>> options, PageAdminLTE page) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Class<T> type, String oid, PageAdminLTE page, Task task, OperationResult result) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Class<T> type, String oid, Collection<SelectorOptions<GetOperationOptions>> options, boolean allowNotFound, PageAdminLTE page, Task task, OperationResult result) static <T extends ObjectType>
@Nullable PrismObject<T>loadObject
(Class<T> type, String oid, Collection<SelectorOptions<GetOperationOptions>> options, PageAdminLTE page, Task task, OperationResult result) static ResourceType
loadResource
(PrismObjectWrapper<ShadowType> shadowWrapper, PageBase pageBase) static PrismObject<SystemConfigurationType>
loadSystemConfigurationAsPrismObject
(PageBase pageBase, Task task, OperationResult result) static <O extends ObjectType>
PrismObject<O>reconstructObject
(Class<O> type, String oid, String eventIdentifier, Task task, OperationResult result) static String
resolveReferenceName
(Referencable ref, PageBase page) static String
resolveReferenceName
(Referencable ref, PageBase page, boolean translate) static String
resolveReferenceName
(Referencable ref, PageBase page, Task task, OperationResult result) static String
resolveReferenceName
(Referencable ref, PageBase page, Task task, OperationResult result, boolean translate) static <T extends ObjectType>
PrismObject<T>resolveReferenceNoFetch
(Referencable reference, PageAdminLTE page, Task task, OperationResult result) static void
save
(ObjectDelta delta, ModelExecuteOptions options, OperationResult result, Task task, PageAdminLTE page) static void
save
(ObjectDelta delta, OperationResult result, PageAdminLTE page) static void
save
(ObjectDelta delta, OperationResult result, Task task, PageAdminLTE page) static void
save
(Collection<ObjectDelta<? extends ObjectType>> deltas, ModelExecuteOptions options, OperationResult result, Task task, PageAdminLTE page) static <C extends Containerable>
List<C>searchContainers
(Class<C> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageBase page) static <T extends ObjectType>
@NotNull List<PrismObject<T>>searchObjects
(Class<T> type, ObjectQuery query, OperationResult result, PageAdminLTE page) static <T extends ObjectType>
@NotNull List<PrismObject<T>>searchObjects
(Class<T> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageAdminLTE page) static <T extends ObjectType>
@NotNull List<PrismObject<T>>searchObjects
(Class<T> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageAdminLTE page, PrismObject<UserType> principal) static String
translateMessage
(OperationResult result, ModelServiceLocator page)
-
Field Details
-
OPERATION_LOAD_OBJECT
-
-
Constructor Details
-
WebModelServiceUtils
public WebModelServiceUtils()
-
-
Method Details
-
resolveReferenceName
-
resolveReferenceName
-
resolveReferenceName
public static String resolveReferenceName(Referencable ref, PageBase page, Task task, OperationResult result) -
resolveReferenceName
public static String resolveReferenceName(Referencable ref, PageBase page, Task task, OperationResult result, boolean translate) -
resolveReferenceNoFetch
public static <T extends ObjectType> PrismObject<T> resolveReferenceNoFetch(Referencable reference, PageAdminLTE page, Task task, OperationResult result) -
createObjectReferenceListForType
public static <O extends ObjectType> List<ObjectReferenceType> createObjectReferenceListForType(Class<O> type, PageBase page, Map<String, String> referenceMap) -
createObjectReferenceListForObjects
public static <O extends ObjectType> List<ObjectReferenceType> createObjectReferenceListForObjects(PageBase page, List<PrismObject<O>> objects, Map<String, String> referenceMap) -
loadObject
public static <O extends ObjectType> PrismObject<O> loadObject(PrismReferenceValue objectRef, QName expectedTargetType, PageBase pageBase, Task task, OperationResult result) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Referencable objectReference, PageAdminLTE page) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Referencable objectReference, Collection<SelectorOptions<GetOperationOptions>> options, PageAdminLTE page) -
loadObject
public static <T extends ObjectType> PrismObject<T> loadObject(Referencable objectReference, PageAdminLTE page, Task task, OperationResult result) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Referencable objectReference, boolean allowNull, PageAdminLTE page, Task task, OperationResult result) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Class<T> type, String oid, PageAdminLTE page, Task task, OperationResult result) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Class<T> type, String oid, Collection<SelectorOptions<GetOperationOptions>> options, PageAdminLTE page, Task task, OperationResult result) -
loadObject
@Nullable public static <T extends ObjectType> @Nullable PrismObject<T> loadObject(Class<T> type, String oid, Collection<SelectorOptions<GetOperationOptions>> options, boolean allowNotFound, PageAdminLTE page, Task task, OperationResult result) -
isNoFetch
-
searchObjects
@NotNull public static <T extends ObjectType> @NotNull List<PrismObject<T>> searchObjects(Class<T> type, ObjectQuery query, OperationResult result, PageAdminLTE page) -
searchObjects
@NotNull public static <T extends ObjectType> @NotNull List<PrismObject<T>> searchObjects(Class<T> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageAdminLTE page) -
searchObjects
@NotNull public static <T extends ObjectType> @NotNull List<PrismObject<T>> searchObjects(Class<T> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageAdminLTE page, PrismObject<UserType> principal) -
countObjects
public static <T extends ObjectType> int countObjects(Class<T> type, ObjectQuery query, PageBase page) -
deleteObject
public static <T extends ObjectType> void deleteObject(Class<T> type, String oid, OperationResult result, PageBase page) -
deleteObject
public static <T extends ObjectType> void deleteObject(Class<T> type, String oid, ModelExecuteOptions options, OperationResult result, PageBase page) -
deleteObject
public static <T extends ObjectType> void deleteObject(Class<T> type, String oid, ModelExecuteOptions options, OperationResult result, PageBase page, PrismObject<UserType> principal) -
createOptionsForParentOrgRefs
public static Collection<SelectorOptions<GetOperationOptions>> createOptionsForParentOrgRefs(GetOperationOptionsBuilder builder) -
save
-
save
-
save
public static void save(ObjectDelta delta, ModelExecuteOptions options, OperationResult result, Task task, PageAdminLTE page) -
save
public static void save(Collection<ObjectDelta<? extends ObjectType>> deltas, ModelExecuteOptions options, OperationResult result, Task task, PageAdminLTE page) -
searchContainers
public static <C extends Containerable> List<C> searchContainers(Class<C> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, OperationResult result, PageBase page) -
checkExpressionInFilter
public static void checkExpressionInFilter(ObjectFilter filter) throws ExpressionEvaluationException - Throws:
ExpressionEvaluationException
-
countContainers
public static <C extends Containerable> int countContainers(Class<C> type, ObjectQuery query, Collection<SelectorOptions<GetOperationOptions>> options, PageBase page) -
createActivationAdminStatusDelta
public static <T extends ObjectType> ObjectDelta<T> createActivationAdminStatusDelta(Class<T> type, String oid, boolean enabled, PrismContext context) -
getLoggedInFocus
-
getLoggedInFocusOid
-
getTimezone
-
createSimpleTask
public static Task createSimpleTask(String operation, PrismObject<? extends FocusType> owner, TaskManager manager) -
createSimpleTask
public static Task createSimpleTask(String operation, String channel, PrismObject<? extends FocusType> owner, TaskManager manager) -
reconstructObject
public static <O extends ObjectType> PrismObject<O> reconstructObject(Class<O> type, String oid, String eventIdentifier, Task task, OperationResult result) -
createLookupTableRetrieveOptions
public static Collection<SelectorOptions<GetOperationOptions>> createLookupTableRetrieveOptions(SchemaService schemaService) -
getAssignmentEffectiveStatus
public static ActivationStatusType getAssignmentEffectiveStatus(String lifecycleStatus, ActivationType activationType, PageBase pageBase) -
dropPowerOfAttorney
public static void dropPowerOfAttorney(ModelInteractionService modelInteractionService, TaskManager taskManager, OperationResult parentResult) -
isEnableExperimentalFeature
-
isEnableExperimentalFeature
public static boolean isEnableExperimentalFeature(ModelInteractionService modelInteractionService, Task task, OperationResult result) -
isEnableExperimentalFeature
-
getCertificationConfiguration
-
translateMessage
-
loadSystemConfigurationAsPrismObject
public static PrismObject<SystemConfigurationType> loadSystemConfigurationAsPrismObject(PageBase pageBase, Task task, OperationResult result) -
loadLookupTable
-
loadResource
public static ResourceType loadResource(PrismObjectWrapper<ShadowType> shadowWrapper, PageBase pageBase)
-