Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.gemini.blueprint.context.support.internal.scope
Class OsgiBundleScope

    java.lang.Object
      org.eclipse.gemini.blueprint.context.support.internal.scope.OsgiBundleScope

All Implemented Interfaces:
  org.springframework.beans.factory.config.Scope, org.springframework.beans.factory.DisposableBean

    public class OsgiBundleScope

extends Object
implements org.springframework.beans.factory.config.Scope, org.springframework.beans.factory.DisposableBean

OSGi bundle `Scope` implementation. Will allow per--calling-bundle object instance, thus this scope becomes useful when enabled on localBeans exposed as OSGi services.

Author:
  Costin Leau

Nested Class Summary
`static class` | `OsgiBundleScope.BundleScopeServiceFactory` Decorating `ServiceFactory` used for supporting 'bundle' scoped localBeans.

Field Summary
`static ThreadLocal<Object>` | `EXTERNAL_BUNDLE` ThreadLocal used for passing objects around `OsgiBundleScope` and `OsgiBundleScope.BundleScopeServiceFactory` (there is only one scope instance but multiple BSSFs).
`static String` | `SCOPE_NAME`

Constructor Summary
`OsgiBundleScope()`

Method Summary
`void` | `destroy()`
`Object` | `get(String name, org.springframework.beans.factory.ObjectFactory<?> objectFactory)`
`String` | `getConversationId()`
`void` | `registerDestructionCallback(String name, Runnable callback)`
`Object` | `remove(String name)`
`Object` | `resolveContextualObject(String key)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### SCOPE_NAME

    public static final String SCOPE_NAME

See Also:
  Constant Field Values

### EXTERNAL_BUNDLE

    public static final ThreadLocal<Object> EXTERNAL_BUNDLE

  ThreadLocal used for passing objects around `OsgiBundleScope` and `OsgiBundleScope.BundleScopeServiceFactory` (there is only one scope instance but multiple BSSFs).

Constructor Detail

### OsgiBundleScope

    public OsgiBundleScope()

Method Detail

### get

    public Object get(String name,
                      org.springframework.beans.factory.ObjectFactory<?> objectFactory)

  Specified by:
    `get` in interface `org.springframework.beans.factory.config.Scope`

### getConversationId

    public String getConversationId()

  Specified by:
    `getConversationId` in interface `org.springframework.beans.factory.config.Scope`

### registerDestructionCallback

    public void registerDestructionCallback(String name,
                                            Runnable callback)

  Specified by:
    `registerDestructionCallback` in interface `org.springframework.beans.factory.config.Scope`

### remove

    public Object remove(String name)

  Specified by:
    `remove` in interface `org.springframework.beans.factory.config.Scope`

### resolveContextualObject

    public Object resolveContextualObject(String key)

  Specified by:
    `resolveContextualObject` in interface `org.springframework.beans.factory.config.Scope`

### destroy

    public void destroy()

  Specified by:
    `destroy` in interface `org.springframework.beans.factory.DisposableBean`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2012. All Rights Reserved.