public class SvcInstance extends DependencyModel
DependencyModel.DependencyEventType, DependencyModel.ServiceBindingHolderBROKEN, DYNAMIC_BINDING_POLICY, DYNAMIC_PRIORITY_BINDING_POLICY, m_serviceReferenceManager, RESOLVED, STATIC_BINDING_POLICY, UNRESOLVED| Constructor and Description |
|---|
SvcInstance(ServiceDependencyHandler handler,
java.lang.String spec,
java.util.Dictionary conf,
boolean isAgg,
boolean isOpt,
org.osgi.framework.Filter filt,
java.util.Comparator cmp,
int policy)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
freeze()
Freeze the set of used provider.
|
protected java.util.Map |
getMatchingFactories()
Get the map of used references [reference, component instance].
|
java.lang.String |
getServiceSpecification()
Get the required specification.
|
boolean |
isFrozen() |
boolean |
match(org.osgi.framework.ServiceReference fact)
Does the service instance match with the given factory ?
|
void |
onDependencyReconfiguration(org.osgi.framework.ServiceReference[] departs,
org.osgi.framework.ServiceReference[] arrivals)
On Dependency Reconfiguration notification method.
|
void |
onServiceArrival(org.osgi.framework.ServiceReference ref)
A new service is injected.
|
void |
onServiceDeparture(org.osgi.framework.ServiceReference ref)
A used service is leaving.
|
void |
onServiceModification(org.osgi.framework.ServiceReference arg0)
A factory is modified.
|
void |
stop()
Stop the service instance.
|
void |
unfreeze()
Unfreezes.
|
acquireReadLockIfNotHeld, acquireWriteLockIfNotHeld, addListener, applyReconfiguration, cleanup, getBindingPolicy, getBundleContext, getComparator, getComponentInstance, getContextSourceManager, getFilter, getId, getService, getService, getServiceReference, getServiceReferenceManager, getServiceReferences, getSize, getSpecification, getState, getTracker, getUsedServiceReferences, invalidateMatchingServices, invalidateSelectedServices, isAggregate, isOptional, notifyListeners, onChange, releaseReadLockIfHeld, releaseWriteLockIfHeld, removeListener, setAggregate, setBundleContext, setComparator, setFilter, setOptionality, setSpecification, start, ungetServicepublic SvcInstance(ServiceDependencyHandler handler, java.lang.String spec, java.util.Dictionary conf, boolean isAgg, boolean isOpt, org.osgi.framework.Filter filt, java.util.Comparator cmp, int policy) throws ConfigurationException
handler - : the handler.spec - : required specification.conf - : instance configuration.isAgg - : is the service instance an aggregate service ?isOpt - : is the service instance optional ?filt - : LDAP filtercmp - : comparator to use for the trackingpolicy - : binding policyConfigurationException - : an attribute cannot be parsed correctly, or is incorrect.public void stop()
stop in class DependencyModelpublic boolean isFrozen()
isFrozen in class DependencyModelpublic void freeze()
public void unfreeze()
unfreeze in class DependencyModelpublic boolean match(org.osgi.framework.ServiceReference fact)
match in class DependencyModelfact - : the factory to test.public java.lang.String getServiceSpecification()
protected java.util.Map getMatchingFactories()
public void onDependencyReconfiguration(org.osgi.framework.ServiceReference[] departs,
org.osgi.framework.ServiceReference[] arrivals)
onDependencyReconfiguration in class DependencyModeldeparts - : leaving service references.arrivals - : new injected service references.DependencyModel.onDependencyReconfiguration(org.osgi.framework.ServiceReference[], org.osgi.framework.ServiceReference[])public void onServiceArrival(org.osgi.framework.ServiceReference ref)
onServiceArrival in class DependencyModelref - : service reference.DependencyModel.onServiceArrival(org.osgi.framework.ServiceReference)public void onServiceDeparture(org.osgi.framework.ServiceReference ref)
onServiceDeparture in class DependencyModelref - : leaving service reference.DependencyModel.onServiceDeparture(org.osgi.framework.ServiceReference)public void onServiceModification(org.osgi.framework.ServiceReference arg0)
onServiceModification in class DependencyModelarg0 - the service referenceDependencyModel.onServiceModification(org.osgi.framework.ServiceReference)Copyright © 2006-2014 The Apache Software Foundation. All Rights Reserved.