Package com.yahoo.container.bundle
Class MockBundle
java.lang.Object
com.yahoo.container.bundle.MockBundle
- All Implemented Interfaces:
Comparable<org.osgi.framework.Bundle>
,org.osgi.framework.Bundle
,org.osgi.framework.BundleReference
,org.osgi.framework.wiring.BundleWiring
,org.osgi.resource.Wiring
public class MockBundle
extends Object
implements org.osgi.framework.Bundle, org.osgi.framework.wiring.BundleWiring
- Author:
- gjoranv, ollivir
-
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
Fields inherited from interface org.osgi.framework.wiring.BundleWiring
FINDENTRIES_RECURSE, LISTRESOURCES_LOCAL, LISTRESOURCES_RECURSE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription<T> T
int
compareTo
(org.osgi.framework.Bundle o) findEntries
(String path, String filePattern, boolean recurse) findEntries
(String p1, String p2, int p3) org.osgi.framework.Bundle
org.osgi.framework.BundleContext
long
List<org.osgi.framework.wiring.BundleCapability>
getDataFile
(String filename) getEntryPaths
(String path) getHeaders
(String locale) long
List<org.osgi.resource.Wire>
List<org.osgi.framework.wiring.BundleWire>
org.osgi.framework.ServiceReference<?>[]
List<org.osgi.resource.Wire>
List<org.osgi.framework.wiring.BundleWire>
List<org.osgi.framework.wiring.BundleRequirement>
org.osgi.framework.wiring.BundleRevision
getResource
(String name) List<org.osgi.resource.Capability>
List<org.osgi.resource.Requirement>
getResources
(String name) org.osgi.framework.wiring.BundleRevision
org.osgi.framework.ServiceReference<?>[]
getSignerCertificates
(int signersType) int
getState()
org.osgi.framework.Version
boolean
hasPermission
(Object permission) boolean
boolean
isInUse()
listResources
(String p1, String p2, int p3) Class<?>
void
start()
void
start
(int options) void
stop()
void
stop
(int options) void
void
update()
void
update
(InputStream input)
-
Field Details
-
SymbolicName
- See Also:
-
BundleVersion
public static final org.osgi.framework.Version BundleVersion
-
-
Constructor Details
-
MockBundle
public MockBundle()
-
-
Method Details
-
getState
public int getState()- Specified by:
getState
in interfaceorg.osgi.framework.Bundle
-
start
public void start(int options) - Specified by:
start
in interfaceorg.osgi.framework.Bundle
-
start
public void start()- Specified by:
start
in interfaceorg.osgi.framework.Bundle
-
stop
public void stop(int options) - Specified by:
stop
in interfaceorg.osgi.framework.Bundle
-
stop
public void stop()- Specified by:
stop
in interfaceorg.osgi.framework.Bundle
-
update
- Specified by:
update
in interfaceorg.osgi.framework.Bundle
-
update
public void update()- Specified by:
update
in interfaceorg.osgi.framework.Bundle
-
uninstall
public void uninstall()- Specified by:
uninstall
in interfaceorg.osgi.framework.Bundle
-
getHeaders
- Specified by:
getHeaders
in interfaceorg.osgi.framework.Bundle
-
getSymbolicName
- Specified by:
getSymbolicName
in interfaceorg.osgi.framework.Bundle
-
getVersion
public org.osgi.framework.Version getVersion()- Specified by:
getVersion
in interfaceorg.osgi.framework.Bundle
-
getLocation
- Specified by:
getLocation
in interfaceorg.osgi.framework.Bundle
-
getBundleId
public long getBundleId()- Specified by:
getBundleId
in interfaceorg.osgi.framework.Bundle
-
getHeaders
- Specified by:
getHeaders
in interfaceorg.osgi.framework.Bundle
-
getRegisteredServices
public org.osgi.framework.ServiceReference<?>[] getRegisteredServices()- Specified by:
getRegisteredServices
in interfaceorg.osgi.framework.Bundle
-
getServicesInUse
public org.osgi.framework.ServiceReference<?>[] getServicesInUse()- Specified by:
getServicesInUse
in interfaceorg.osgi.framework.Bundle
-
hasPermission
- Specified by:
hasPermission
in interfaceorg.osgi.framework.Bundle
-
getResource
- Specified by:
getResource
in interfaceorg.osgi.framework.Bundle
-
loadClass
- Specified by:
loadClass
in interfaceorg.osgi.framework.Bundle
-
getResources
- Specified by:
getResources
in interfaceorg.osgi.framework.Bundle
-
getEntryPaths
- Specified by:
getEntryPaths
in interfaceorg.osgi.framework.Bundle
-
getEntry
- Specified by:
getEntry
in interfaceorg.osgi.framework.Bundle
-
findEntries
- Specified by:
findEntries
in interfaceorg.osgi.framework.Bundle
-
getLastModified
public long getLastModified()- Specified by:
getLastModified
in interfaceorg.osgi.framework.Bundle
-
getBundleContext
public org.osgi.framework.BundleContext getBundleContext()- Specified by:
getBundleContext
in interfaceorg.osgi.framework.Bundle
-
getSignerCertificates
- Specified by:
getSignerCertificates
in interfaceorg.osgi.framework.Bundle
-
adapt
- Specified by:
adapt
in interfaceorg.osgi.framework.Bundle
-
getDataFile
- Specified by:
getDataFile
in interfaceorg.osgi.framework.Bundle
-
compareTo
public int compareTo(org.osgi.framework.Bundle o) - Specified by:
compareTo
in interfaceComparable<org.osgi.framework.Bundle>
-
findEntries
- Specified by:
findEntries
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getRequiredResourceWires
- Specified by:
getRequiredResourceWires
in interfaceorg.osgi.framework.wiring.BundleWiring
- Specified by:
getRequiredResourceWires
in interfaceorg.osgi.resource.Wiring
-
getResourceCapabilities
- Specified by:
getResourceCapabilities
in interfaceorg.osgi.framework.wiring.BundleWiring
- Specified by:
getResourceCapabilities
in interfaceorg.osgi.resource.Wiring
-
isCurrent
public boolean isCurrent()- Specified by:
isCurrent
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getRequiredWires
- Specified by:
getRequiredWires
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getCapabilities
- Specified by:
getCapabilities
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getProvidedResourceWires
- Specified by:
getProvidedResourceWires
in interfaceorg.osgi.framework.wiring.BundleWiring
- Specified by:
getProvidedResourceWires
in interfaceorg.osgi.resource.Wiring
-
getProvidedWires
- Specified by:
getProvidedWires
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getRevision
public org.osgi.framework.wiring.BundleRevision getRevision()- Specified by:
getRevision
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getResourceRequirements
- Specified by:
getResourceRequirements
in interfaceorg.osgi.framework.wiring.BundleWiring
- Specified by:
getResourceRequirements
in interfaceorg.osgi.resource.Wiring
-
isInUse
public boolean isInUse()- Specified by:
isInUse
in interfaceorg.osgi.framework.wiring.BundleWiring
-
listResources
- Specified by:
listResources
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getClassLoader
- Specified by:
getClassLoader
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getRequirements
- Specified by:
getRequirements
in interfaceorg.osgi.framework.wiring.BundleWiring
-
getResource
public org.osgi.framework.wiring.BundleRevision getResource()- Specified by:
getResource
in interfaceorg.osgi.framework.wiring.BundleWiring
- Specified by:
getResource
in interfaceorg.osgi.resource.Wiring
-
getBundle
public org.osgi.framework.Bundle getBundle()- Specified by:
getBundle
in interfaceorg.osgi.framework.BundleReference
-