Top Description Fields Methods
org.glassfish.hk2.runlevel

public @Interface RunLevel

extends Annotation
Known Direct Implementers
org.glassfish.hk2.runlevel.RunLevelServiceUtilities.RunLevelImpl
Annotations
@Scope
@Retention:RUNTIME
@Target:TYPE, ANNOTATION_TYPE, METHOD
@Documented
@Inherited
@Contract
Imports
org.glassfish.hk2.api.Metadata, org.jvnet.hk2.annotations.Contract, jakarta.inject.Scope, java.lang.annotation.Documented, .Inherited, .Retention, .Target

Defines a run/start level.
Author
jdochez, jtrent, tbeerbower

Field Summary

Modifier and TypeField and Description
public static final String
RUNLEVEL_MODE_META_TAG

The metadata key for run level mode.

public static final int
RUNLEVEL_MODE_NON_VALIDATING

Services set to have a non-validating run level mode will be activated by their associated run level service or through injection into another service.

public static final int
RUNLEVEL_MODE_VALIDATING

Services set to have a validating run level mode will be activated and deactivated by their associated run level service but may also be activated through injection into another service.

public static final int
RUNLEVEL_VAL_IMMEDIATE

The immediate run level.

public static final int
RUNLEVEL_VAL_INITIAL

The initial run level.

public static final String
RUNLEVEL_VAL_META_TAG

The metadata key for run level value.

Method Summary

Modifier and TypeMethod and Description
public int

Returns:

the mode
mode
()

Defines the run level mode.

public int

Returns:

the run level
value
()

Defines the run level.

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Field Detail

RUNLEVEL_MODE_META_TAGback to summary
public static final String RUNLEVEL_MODE_META_TAG

The metadata key for run level mode. If this value is present is MUST match the mode of this annotation. If this value is set then the system will not have to reify the descriptor in order to determine its mode

RUNLEVEL_MODE_NON_VALIDATINGback to summary
public static final int RUNLEVEL_MODE_NON_VALIDATING

Services set to have a non-validating run level mode will be activated by their associated run level service or through injection into another service. These services will not be checked during activation which means that the service can be activated prior to the run level service reaching the run level. The run level serves only as a fail safe for activation.

RUNLEVEL_MODE_VALIDATINGback to summary
public static final int RUNLEVEL_MODE_VALIDATING

Services set to have a validating run level mode will be activated and deactivated by their associated run level service but may also be activated through injection into another service. The current run level of the associated run level service will be checked during activation of these services to ensure that the service is being activated in at an appropriate run level.

RUNLEVEL_VAL_IMMEDIATEback to summary
public static final int RUNLEVEL_VAL_IMMEDIATE

The immediate run level. Services set to this run level will be activated immediately.

RUNLEVEL_VAL_INITIALback to summary
public static final int RUNLEVEL_VAL_INITIAL

The initial run level.

RUNLEVEL_VAL_META_TAGback to summary
public static final String RUNLEVEL_VAL_META_TAG

The metadata key for run level value. If this value is present it MUST match the value of this annotation. If this value is set then the system will not have to reify the descriptor in order to determine its level

Method Detail

modeback to summary
public int mode()

Defines the run level mode.

Returns:int

the mode

Annotations
@Metadata:runLevelMode
valueback to summary
public int value()

Defines the run level.

Returns:int

the run level

Annotations
@Metadata:runLevelValue