Package com.day.cq.commons
Class RunModeUtil
java.lang.Object
com.day.cq.commons.RunModeUtil
Deprecated.
RunMode utilities.
Instead of directly using the run mode service, it is better to make
the component in question require a configuration (see OSGI Declarative
Services Spec: configuration policy). In this case, a component gets
only active if a configuration is available. Such a configuration can
be put into the repository for the specific run mode.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
Deprecated.Name to use for the property that configures the run modes of a component -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
disableIfNoRunModeActive
(RunMode rm, String[] componentRunModes, ComponentContext ctx, Logger log) Deprecated.Use this to disable a component if none of its run modes are active
-
Field Details
-
RUN_MODES_PROPERTY
Deprecated.Name to use for the property that configures the run modes of a component- See Also:
-
-
Constructor Details
-
RunModeUtil
public RunModeUtil()Deprecated.
-
-
Method Details
-
disableIfNoRunModeActive
public static boolean disableIfNoRunModeActive(RunMode rm, String[] componentRunModes, ComponentContext ctx, Logger log) Deprecated.Use this to disable a component if none of its run modes are active- Parameters:
rm
-RunMode
componentRunModes
- component run modesctx
- component contextlog
- logger- Returns:
- true if component was disabled
-