org.apache.aries.jpa.container.context.impl
Class GlobalPersistenceManager

java.lang.Object
  extended by org.apache.aries.jpa.container.context.impl.GlobalPersistenceManager
All Implemented Interfaces:
EventListener, org.apache.aries.jpa.container.context.PersistenceContextProvider, org.osgi.framework.BundleActivator, org.osgi.framework.BundleListener, org.osgi.framework.SynchronousBundleListener

public class GlobalPersistenceManager
extends Object
implements org.apache.aries.jpa.container.context.PersistenceContextProvider, org.osgi.framework.SynchronousBundleListener, org.osgi.framework.BundleActivator

Class that coordinates PersistenceContextManagers across multiple (nested) OSGi frameworks.


Field Summary
 
Fields inherited from interface org.apache.aries.jpa.container.context.PersistenceContextProvider
PERSISTENCE_CONTEXT_TYPE, PROXY_FACTORY_EMF_ATTRIBUTE
 
Constructor Summary
GlobalPersistenceManager()
           
 
Method Summary
 void bundleChanged(org.osgi.framework.BundleEvent event)
          This method is used to track the lifecycle of bundles inside composites
 org.osgi.framework.Bundle getBundle()
           
 void quiesceBundle(org.osgi.framework.Bundle bundleToQuiesce, DestroyCallback callback)
          Quiesce the supplied bundle
 void registerContext(String unitName, org.osgi.framework.Bundle client, HashMap<String,Object> properties)
           
 void start(org.osgi.framework.BundleContext context)
           
 void stop(org.osgi.framework.BundleContext context)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GlobalPersistenceManager

public GlobalPersistenceManager()
Method Detail

registerContext

public void registerContext(String unitName,
                            org.osgi.framework.Bundle client,
                            HashMap<String,Object> properties)
Specified by:
registerContext in interface org.apache.aries.jpa.container.context.PersistenceContextProvider

bundleChanged

public void bundleChanged(org.osgi.framework.BundleEvent event)
This method is used to track the lifecycle of bundles inside composites

Specified by:
bundleChanged in interface org.osgi.framework.BundleListener

quiesceBundle

public void quiesceBundle(org.osgi.framework.Bundle bundleToQuiesce,
                          DestroyCallback callback)
Quiesce the supplied bundle

Parameters:
bundleToQuiesce -
callback -

start

public void start(org.osgi.framework.BundleContext context)
           throws Exception
Specified by:
start in interface org.osgi.framework.BundleActivator
Throws:
Exception

stop

public void stop(org.osgi.framework.BundleContext context)
          throws Exception
Specified by:
stop in interface org.osgi.framework.BundleActivator
Throws:
Exception

getBundle

public org.osgi.framework.Bundle getBundle()


Copyright © 2009-2012 The Apache Software Foundation. All Rights Reserved.