Package org.osgi.service.resolver
Interface Resolver
-
@ProviderType public interface Resolver
A resolver service resolves the specified resources in the context supplied by the caller.- Author:
- $Id: 367c005c1a4b487bb6512c13c6348e343cefcfe5 $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<org.osgi.resource.Resource,java.util.List<org.osgi.resource.Wire>>
resolve(ResolveContext context)
Resolve the specified resolve context and return any new resources and wires to the caller.
-
-
-
Method Detail
-
resolve
java.util.Map<org.osgi.resource.Resource,java.util.List<org.osgi.resource.Wire>> resolve(ResolveContext context) throws ResolutionException
Resolve the specified resolve context and return any new resources and wires to the caller.The resolver considers two groups of resources:
- Mandatory - any resource in the
mandatory group
must be resolved. A failure to satisfy any mandatory requirement for these resources will result in throwing aResolutionException
- Optional - any resource in the
optional group
may be resolved. A failure to satisfy a mandatory requirement for a resource in this group will not fail the overall resolution but no resources or wires will be returned for that resource.
The resolve method returns the delta between the start state defined by
ResolveContext.getWirings()
and the end resolved state. That is, only new resources and wires are included.The behavior of the resolver is not defined if the specified resolve context supplies inconsistent information.
- Parameters:
context
- The resolve context for the resolve operation. Must not benull
.- Returns:
- The new resources and wires required to satisfy the specified resolve context. The returned map is the property of the caller and can be modified by the caller.
- Throws:
ResolutionException
- If the resolution cannot be satisfied.
- Mandatory - any resource in the
-
-