@ProviderType public interface HostedCapability extends Capability
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.
Modifier and Type | Method and Description |
---|---|
Capability |
getDeclaredCapability()
Return the Capability hosted by the Resource.
|
Resource |
getResource()
Return the Resource that hosts this Capability.
|
equals, getAttributes, getDirectives, getNamespace, hashCode
Resource getResource()
getResource
in interface Capability
Capability getDeclaredCapability()
Copyright © OSGi Alliance (2000, 2020). All Rights Reserved. Licensed under the OSGi Specification License, Version 2.0