Top Description Fields Constructors Methods
org.osgi.service.component.annotations

public final Enum ReferenceScope

extends Enum<ReferenceScope>
Class Inheritance

Reference scope for the Reference annotation.
Author
$Id: 5e1452931946cc89b397a4081bd9592d405b1961 $
Since
1.3

Field Summary

Modifier and TypeField and Description
public static final ReferenceScope
BUNDLE

A single service object is used for all references to the service in this bundle.

public static final ReferenceScope
PROTOTYPE

If the bound service has prototype service scope, then each instance of the component with this reference can receive a unique instance of the service.

public static final ReferenceScope
PROTOTYPE_REQUIRED

Bound services must have prototype service scope.

private final String

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public String
toString()

Overrides java.lang.Enum.toString.

Returns the name of this enum constant, as contained in the declaration.

public static ReferenceScope
public static ReferenceScope[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinalvalueOf

Field Detail

BUNDLEback to summary
public static final ReferenceScope BUNDLE

A single service object is used for all references to the service in this bundle.

PROTOTYPEback to summary
public static final ReferenceScope PROTOTYPE

If the bound service has prototype service scope, then each instance of the component with this reference can receive a unique instance of the service. If the bound service does not have prototype service scope, then this reference scope behaves the same as BUNDLE.

PROTOTYPE_REQUIREDback to summary
public static final ReferenceScope PROTOTYPE_REQUIRED

Bound services must have prototype service scope. Each instance of the component with this reference can receive a unique instance of the service.

valueback to summary
private final String value

Constructor Detail

ReferenceScopeback to summary
private ReferenceScope(String value)

Method Detail

toStringback to summary
public String toString()

Overrides java.lang.Enum.toString.

Doc from java.lang.Enum.toString.

Returns the name of this enum constant, as contained in the declaration. This method may be overridden, though it typically isn't necessary or desirable. An enum class should override this method when a more "programmer-friendly" string form exists.

Returns:String

the name of this enum constant

Annotations
@Override
valueOfback to summary
public static ReferenceScope valueOf(String name)
valuesback to summary
public static ReferenceScope[] values()