public class RunLevelServiceUtilities extends Object
Constructor and Description |
---|
RunLevelServiceUtilities() |
Modifier and Type | Method and Description |
---|---|
static void |
enableRunLevelService(ServiceLocator locator)
Enables the RunLevelService in the given
ServiceLocator . |
static RunLevel |
getRunLevelAnnotation(int value)
Returns a
RunLevel scope annotation with the
given value and RUNLEVEL_MODE_VALIDATING as the mode |
static RunLevel |
getRunLevelAnnotation(int value,
int mode)
Returns a
RunLevel scope annotation with the
given value and mode |
public static void enableRunLevelService(ServiceLocator locator)
ServiceLocator
.
If the RunLevelContext
is already registered then
this method does nothing.
All services needed by the
RunLevelService feature are marked with Service
and
hence would be automatically picked up in environments that
use automatic service discovery
locator
- the non-null service locator to add
the run-level service topublic static RunLevel getRunLevelAnnotation(int value)
RunLevel
scope annotation with the
given value and RUNLEVEL_MODE_VALIDATING as the modevalue
- The value this RunLevel should takeRunLevel
scope annotationpublic static RunLevel getRunLevelAnnotation(int value, int mode)
RunLevel
scope annotation with the
given value and modevalue
- The value this RunLevel should takemode
- The mode the RunLevel should take:RunLevel
scope annotationCopyright © 2009-2017, Oracle and/or its affiliates. All Rights Reserved.