Top Description Methods
org.osgi.service.resolver

public Interface HostedCapability

extends Capability
Annotations
@ProviderType
Imports
org.osgi.annotation.versioning.ProviderType, org.osgi.resource.Capability, .Resource

A capability hosted by a resource.

A HostedCapability is a Capability where the getResource() method returns a Resource that hosts this Capability instead of declaring it. This is necessary for cases where the declaring Resource of a Capability does not match the runtime state. For example, this is the case for fragments attached to a host. Most fragment declared capabilities and requirements become hosted by the host resource. Since a fragment can attach to multiple hosts, a single capability can actually be hosted multiple times.

Author
$Id: e6a6917f6cdb5021a7a5cf858a08a98677183606 $

Method Summary

Modifier and TypeMethod and Description
public Capability

Returns:

The Capability hosted by the Resource.
getDeclaredCapability
()

Return the Capability hosted by the Resource.

public Resource

Returns:

The Resource that hosts this Capability.
getResource
()

Redeclares org.osgi.resource.Capability.getResource.

Return the Resource that hosts this Capability.

Inherited from org.osgi.resource.Capability:
equalsgetAttributesgetDirectivesgetNamespacehashCode

Method Detail

getDeclaredCapabilityback to summary
public Capability getDeclaredCapability()

Return the Capability hosted by the Resource.

Returns:Capability

The Capability hosted by the Resource.

getResourceback to summary
public Resource getResource()

Redeclares org.osgi.resource.Capability.getResource.

Return the Resource that hosts this Capability.

Returns:Resource

The Resource that hosts this Capability.

Annotations
@Override