public enum ServiceScope extends Enum<ServiceScope>
ActivationTemplateDTO.scope
.Enum Constant and Description |
---|
BUNDLE
This activation will register an OSGi service with
service.scope=bundle . |
PROTOTYPE
This activation will register an OSGi service with
service.scope=prototype . |
SINGLETON
This activation will only ever create one instance
|
Modifier and Type | Method and Description |
---|---|
static ServiceScope |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static ServiceScope[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final ServiceScope SINGLETON
The instance is created after the parent component becomes satisfied and is destroyed before the parent component becomes unsatisfied.
If ActivationTemplateDTO.serviceClasses
is not empty the instance
will be registered as an OSGi service with
service.scope=singleton
.
public static final ServiceScope BUNDLE
service.scope=bundle
.
The service is registered just after all SINGLETON
activations
are set up and just before all SINGLETON
activations are torn
down.
The ActivationTemplateDTO.serviceClasses
is not empty when this
scope is used.
public static final ServiceScope PROTOTYPE
service.scope=prototype
.
The service is registered just after all SINGLETON
activations
are set up and just before all SINGLETON
activations are torn
down.
The ActivationTemplateDTO.serviceClasses
is not empty when this
scope is used.
public static ServiceScope[] values()
for (ServiceScope c : ServiceScope.values()) System.out.println(c);
public static ServiceScope valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © Contributors to the Eclipse Foundation Licensed under the Eclipse Foundation Specification License – v1.0