aQute.junit.runtime.minifw
Class Context

java.lang.Object
  extended by java.lang.ClassLoader
      extended by java.security.SecureClassLoader
          extended by java.net.URLClassLoader
              extended by aQute.junit.runtime.minifw.Context
All Implemented Interfaces:
org.osgi.framework.Bundle, org.osgi.framework.BundleContext

public class Context
extends URLClassLoader
implements org.osgi.framework.Bundle, org.osgi.framework.BundleContext


Field Summary
 
Fields inherited from interface org.osgi.framework.Bundle
ACTIVE, INSTALLED, RESOLVED, SIGNERS_ALL, SIGNERS_TRUSTED, START_ACTIVATION_POLICY, START_TRANSIENT, STARTING, STOP_TRANSIENT, STOPPING, UNINSTALLED
 
Method Summary
 void addBundleListener(org.osgi.framework.BundleListener listener)
           
 void addFrameworkListener(org.osgi.framework.FrameworkListener listener)
           
 void addServiceListener(org.osgi.framework.ServiceListener listener)
           
 void addServiceListener(org.osgi.framework.ServiceListener listener, String filter)
           
 org.osgi.framework.Filter createFilter(String filter)
           
 Enumeration findEntries(String path, String filePattern, boolean recurse)
           
 org.osgi.framework.ServiceReference[] getAllServiceReferences(String clazz, String filter)
           
 org.osgi.framework.Bundle getBundle()
           
 org.osgi.framework.Bundle getBundle(long id)
           
 org.osgi.framework.BundleContext getBundleContext()
           
 long getBundleId()
           
 org.osgi.framework.Bundle[] getBundles()
           
 File getDataFile(String filename)
           
 URL getEntry(String path)
           
 Enumeration getEntryPaths(String path)
           
 Dictionary getHeaders()
           
 Dictionary getHeaders(String locale)
           
 long getLastModified()
           
 String getLocation()
           
 String getProperty(String key)
           
 org.osgi.framework.ServiceReference[] getRegisteredServices()
           
 Object getService(org.osgi.framework.ServiceReference reference)
           
 org.osgi.framework.ServiceReference getServiceReference(String clazz)
           
 org.osgi.framework.ServiceReference[] getServiceReferences(String clazz, String filter)
           
 org.osgi.framework.ServiceReference[] getServicesInUse()
           
 Map getSignerCertificates(int signersType)
           
 int getState()
           
 String getSymbolicName()
           
 org.osgi.framework.Version getVersion()
           
 boolean hasPermission(Object permission)
           
 org.osgi.framework.Bundle installBundle(String location)
           
 org.osgi.framework.Bundle installBundle(String location, InputStream input)
           
 org.osgi.framework.ServiceRegistration registerService(String[] clazzes, Object service, Dictionary properties)
           
 org.osgi.framework.ServiceRegistration registerService(String clazz, Object service, Dictionary properties)
           
 void removeBundleListener(org.osgi.framework.BundleListener listener)
           
 void removeFrameworkListener(org.osgi.framework.FrameworkListener listener)
           
 void removeServiceListener(org.osgi.framework.ServiceListener listener)
           
 void start()
           
 void start(int options)
           
 void stop()
           
 void stop(int options)
           
 String toString()
           
 boolean ungetService(org.osgi.framework.ServiceReference reference)
           
 void uninstall()
           
 void update()
           
 void update(InputStream in)
           
 
Methods inherited from class java.net.URLClassLoader
addURL, definePackage, findClass, findResource, findResources, getPermissions, getURLs, newInstance, newInstance
 
Methods inherited from class java.security.SecureClassLoader
defineClass, defineClass
 
Methods inherited from class java.lang.ClassLoader
clearAssertionStatus, defineClass, defineClass, defineClass, defineClass, definePackage, findLibrary, findLoadedClass, findSystemClass, getPackage, getPackages, getParent, getResource, getResourceAsStream, getResources, getSystemClassLoader, getSystemResource, getSystemResourceAsStream, getSystemResources, loadClass, loadClass, resolveClass, setClassAssertionStatus, setDefaultAssertionStatus, setPackageAssertionStatus, setSigners
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.osgi.framework.Bundle
getResource, getResources, loadClass
 

Method Detail

getBundleContext

public org.osgi.framework.BundleContext getBundleContext()
Specified by:
getBundleContext in interface org.osgi.framework.Bundle

getBundleId

public long getBundleId()
Specified by:
getBundleId in interface org.osgi.framework.Bundle

getEntry

public URL getEntry(String path)
Specified by:
getEntry in interface org.osgi.framework.Bundle

getEntryPaths

public Enumeration getEntryPaths(String path)
Specified by:
getEntryPaths in interface org.osgi.framework.Bundle

getHeaders

public Dictionary getHeaders()
Specified by:
getHeaders in interface org.osgi.framework.Bundle

getHeaders

public Dictionary getHeaders(String locale)
Specified by:
getHeaders in interface org.osgi.framework.Bundle

getLastModified

public long getLastModified()
Specified by:
getLastModified in interface org.osgi.framework.Bundle

getLocation

public String getLocation()
Specified by:
getLocation in interface org.osgi.framework.Bundle

findEntries

public Enumeration findEntries(String path,
                               String filePattern,
                               boolean recurse)
Specified by:
findEntries in interface org.osgi.framework.Bundle

getRegisteredServices

public org.osgi.framework.ServiceReference[] getRegisteredServices()
Specified by:
getRegisteredServices in interface org.osgi.framework.Bundle

getServicesInUse

public org.osgi.framework.ServiceReference[] getServicesInUse()
Specified by:
getServicesInUse in interface org.osgi.framework.Bundle

getSignerCertificates

public Map getSignerCertificates(int signersType)
Specified by:
getSignerCertificates in interface org.osgi.framework.Bundle

getState

public int getState()
Specified by:
getState in interface org.osgi.framework.Bundle

getSymbolicName

public String getSymbolicName()
Specified by:
getSymbolicName in interface org.osgi.framework.Bundle

getVersion

public org.osgi.framework.Version getVersion()
Specified by:
getVersion in interface org.osgi.framework.Bundle

hasPermission

public boolean hasPermission(Object permission)
Specified by:
hasPermission in interface org.osgi.framework.Bundle

start

public void start()
           throws org.osgi.framework.BundleException
Specified by:
start in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

start

public void start(int options)
           throws org.osgi.framework.BundleException
Specified by:
start in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

stop

public void stop()
          throws org.osgi.framework.BundleException
Specified by:
stop in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

stop

public void stop(int options)
          throws org.osgi.framework.BundleException
Specified by:
stop in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

uninstall

public void uninstall()
               throws org.osgi.framework.BundleException
Specified by:
uninstall in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

update

public void update()
            throws org.osgi.framework.BundleException
Specified by:
update in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

update

public void update(InputStream in)
            throws org.osgi.framework.BundleException
Specified by:
update in interface org.osgi.framework.Bundle
Throws:
org.osgi.framework.BundleException

addBundleListener

public void addBundleListener(org.osgi.framework.BundleListener listener)
Specified by:
addBundleListener in interface org.osgi.framework.BundleContext

addFrameworkListener

public void addFrameworkListener(org.osgi.framework.FrameworkListener listener)
Specified by:
addFrameworkListener in interface org.osgi.framework.BundleContext

addServiceListener

public void addServiceListener(org.osgi.framework.ServiceListener listener)
Specified by:
addServiceListener in interface org.osgi.framework.BundleContext

addServiceListener

public void addServiceListener(org.osgi.framework.ServiceListener listener,
                               String filter)
Specified by:
addServiceListener in interface org.osgi.framework.BundleContext

createFilter

public org.osgi.framework.Filter createFilter(String filter)
                                       throws org.osgi.framework.InvalidSyntaxException
Specified by:
createFilter in interface org.osgi.framework.BundleContext
Throws:
org.osgi.framework.InvalidSyntaxException

getAllServiceReferences

public org.osgi.framework.ServiceReference[] getAllServiceReferences(String clazz,
                                                                     String filter)
                                                              throws org.osgi.framework.InvalidSyntaxException
Specified by:
getAllServiceReferences in interface org.osgi.framework.BundleContext
Throws:
org.osgi.framework.InvalidSyntaxException

getBundle

public org.osgi.framework.Bundle getBundle()
Specified by:
getBundle in interface org.osgi.framework.BundleContext

getBundle

public org.osgi.framework.Bundle getBundle(long id)
Specified by:
getBundle in interface org.osgi.framework.BundleContext

getBundles

public org.osgi.framework.Bundle[] getBundles()
Specified by:
getBundles in interface org.osgi.framework.BundleContext

getDataFile

public File getDataFile(String filename)
Specified by:
getDataFile in interface org.osgi.framework.BundleContext

getProperty

public String getProperty(String key)
Specified by:
getProperty in interface org.osgi.framework.BundleContext

getService

public Object getService(org.osgi.framework.ServiceReference reference)
Specified by:
getService in interface org.osgi.framework.BundleContext

getServiceReference

public org.osgi.framework.ServiceReference getServiceReference(String clazz)
Specified by:
getServiceReference in interface org.osgi.framework.BundleContext

getServiceReferences

public org.osgi.framework.ServiceReference[] getServiceReferences(String clazz,
                                                                  String filter)
                                                           throws org.osgi.framework.InvalidSyntaxException
Specified by:
getServiceReferences in interface org.osgi.framework.BundleContext
Throws:
org.osgi.framework.InvalidSyntaxException

installBundle

public org.osgi.framework.Bundle installBundle(String location)
                                        throws org.osgi.framework.BundleException
Specified by:
installBundle in interface org.osgi.framework.BundleContext
Throws:
org.osgi.framework.BundleException

installBundle

public org.osgi.framework.Bundle installBundle(String location,
                                               InputStream input)
                                        throws org.osgi.framework.BundleException
Specified by:
installBundle in interface org.osgi.framework.BundleContext
Throws:
org.osgi.framework.BundleException

registerService

public org.osgi.framework.ServiceRegistration registerService(String[] clazzes,
                                                              Object service,
                                                              Dictionary properties)
Specified by:
registerService in interface org.osgi.framework.BundleContext

registerService

public org.osgi.framework.ServiceRegistration registerService(String clazz,
                                                              Object service,
                                                              Dictionary properties)
Specified by:
registerService in interface org.osgi.framework.BundleContext

removeBundleListener

public void removeBundleListener(org.osgi.framework.BundleListener listener)
Specified by:
removeBundleListener in interface org.osgi.framework.BundleContext

removeFrameworkListener

public void removeFrameworkListener(org.osgi.framework.FrameworkListener listener)
Specified by:
removeFrameworkListener in interface org.osgi.framework.BundleContext

removeServiceListener

public void removeServiceListener(org.osgi.framework.ServiceListener listener)
Specified by:
removeServiceListener in interface org.osgi.framework.BundleContext

ungetService

public boolean ungetService(org.osgi.framework.ServiceReference reference)
Specified by:
ungetService in interface org.osgi.framework.BundleContext

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2010 aQute SARL. All Rights Reserved.