org.springframework.osgi.service.importer.support
Class LocalBundleContext
java.lang.Object
org.springframework.osgi.service.importer.support.LocalBundleContext
public abstract class LocalBundleContext
- extends Object
Class containing static methods used to obtain information about the current
OSGi service invocation.
The getInvokerBundleContext()
method offers access to the
BundleContext
of the entity accessing an OSGi service. The invoked
entity can thus discover information about the caller context.
The functionality in this class might be used by a target object that needed
access to resources on the invocation. However, this approach should not be
used when there is a reasonable alternative, as it makes application code
dependent on usage under AOP and the Spring Dynamic Modules and AOP framework
in particular.
- Author:
- Andy Piper, Costin Leau
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LocalBundleContext
public LocalBundleContext()
getInvokerBundleContext
public static BundleContext getInvokerBundleContext()
- Try to get the current invoker bundle context. Note that this can be
null
if the caller is not a Spring-DM importer.
- Returns:
- the invoker bundle context (can be null)
Copyright © 2006-2009 Spring Framework. All Rights Reserved.