public class MockBundle extends Object implements org.osgi.framework.Bundle
| Constructor and Description |
|---|
MockBundle(long bundleId) |
| Modifier and Type | Method and Description |
|---|---|
<A> A |
adapt(Class<A> type) |
int |
compareTo(org.osgi.framework.Bundle o) |
Enumeration<URL> |
findEntries(String path,
String filePattern,
boolean recurse) |
org.osgi.framework.BundleContext |
getBundleContext() |
long |
getBundleId() |
File |
getDataFile(String filename) |
URL |
getEntry(String name) |
Enumeration<String> |
getEntryPaths(String path) |
Dictionary<String,String> |
getHeaders() |
Dictionary<String,String> |
getHeaders(String locale) |
long |
getLastModified() |
String |
getLocation() |
org.osgi.framework.ServiceReference[] |
getRegisteredServices() |
URL |
getResource(String name) |
Enumeration<URL> |
getResources(String name) |
org.osgi.framework.ServiceReference[] |
getServicesInUse() |
Map |
getSignerCertificates(int signersType) |
int |
getState() |
String |
getSymbolicName() |
org.osgi.framework.Version |
getVersion() |
boolean |
hasPermission(Object permission) |
Class<?> |
loadClass(String name) |
void |
start() |
void |
start(int options) |
void |
stop() |
void |
stop(int options) |
void |
uninstall() |
void |
update() |
void |
update(InputStream in) |
public long getBundleId()
getBundleId in interface org.osgi.framework.Bundlepublic Enumeration<URL> findEntries(String path, String filePattern, boolean recurse)
findEntries in interface org.osgi.framework.Bundlepublic URL getEntry(String name)
getEntry in interface org.osgi.framework.Bundlepublic Enumeration<String> getEntryPaths(String path)
getEntryPaths in interface org.osgi.framework.Bundlepublic Dictionary<String,String> getHeaders()
getHeaders in interface org.osgi.framework.Bundlepublic Dictionary<String,String> getHeaders(String locale)
getHeaders in interface org.osgi.framework.Bundlepublic long getLastModified()
getLastModified in interface org.osgi.framework.Bundlepublic String getLocation()
getLocation in interface org.osgi.framework.Bundlepublic org.osgi.framework.ServiceReference[] getRegisteredServices()
getRegisteredServices in interface org.osgi.framework.Bundlepublic URL getResource(String name)
getResource in interface org.osgi.framework.Bundlepublic Enumeration<URL> getResources(String name)
getResources in interface org.osgi.framework.Bundlepublic org.osgi.framework.ServiceReference[] getServicesInUse()
getServicesInUse in interface org.osgi.framework.Bundlepublic int getState()
getState in interface org.osgi.framework.Bundlepublic String getSymbolicName()
getSymbolicName in interface org.osgi.framework.Bundlepublic boolean hasPermission(Object permission)
hasPermission in interface org.osgi.framework.Bundlepublic Class<?> loadClass(String name) throws ClassNotFoundException
loadClass in interface org.osgi.framework.BundleClassNotFoundExceptionpublic void start()
start in interface org.osgi.framework.Bundlepublic void stop()
stop in interface org.osgi.framework.Bundlepublic void uninstall()
uninstall in interface org.osgi.framework.Bundlepublic void update()
update in interface org.osgi.framework.Bundlepublic void update(InputStream in)
update in interface org.osgi.framework.Bundlepublic org.osgi.framework.BundleContext getBundleContext()
getBundleContext in interface org.osgi.framework.Bundlepublic void start(int options)
throws org.osgi.framework.BundleException
start in interface org.osgi.framework.Bundleorg.osgi.framework.BundleExceptionpublic void stop(int options)
throws org.osgi.framework.BundleException
stop in interface org.osgi.framework.Bundleorg.osgi.framework.BundleExceptionpublic Map getSignerCertificates(int signersType)
getSignerCertificates in interface org.osgi.framework.Bundlepublic org.osgi.framework.Version getVersion()
getVersion in interface org.osgi.framework.Bundlepublic int compareTo(org.osgi.framework.Bundle o)
compareTo in interface Comparable<org.osgi.framework.Bundle>public <A> A adapt(Class<A> type)
adapt in interface org.osgi.framework.BundleCopyright © 2007–2017 The Apache Software Foundation. All rights reserved.