Class LocalBundleContext

  extended by

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.

Andy Piper, Costin Leau

Constructor Summary
Method Summary
static BundleContext getInvokerBundleContext()
          Try to get the current invoker bundle context.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public LocalBundleContext()
Method Detail


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.

the invoker bundle context (can be null)

Copyright 2006-2008 Spring Framework. All Rights Reserved.