public class FelixOsgiHost extends Object implements OsgiHost
struts.osgi.clearBundleCache: Defaults to "true" delete installed bundles when the comntainer starts
struts.osgi.logLevel: Defaults to "1". Felix log level. 1 = error, 2 = warning, 3 = information, and 4 = debug
struts.osgi.runLevel: Defaults to "3". Run level to start the container.
OSGI_BUNDLE_CONTEXT, OSGI_HEADER_STRUTS_ENABLED
Constructor and Description |
---|
FelixOsgiHost() |
Modifier and Type | Method and Description |
---|---|
protected void |
addAutoStartBundles(Properties configProps) |
protected void |
addExportedPackages(Properties strutsConfigProps,
Properties configProps) |
protected void |
addSpringOSGiSupport() |
void |
destroy() |
Map<String,org.osgi.framework.Bundle> |
getActiveBundles() |
org.osgi.framework.BundleContext |
getBundleContext() |
Map<String,org.osgi.framework.Bundle> |
getBundles()
This bundle map will not change, but the status of the bundles can change over time.
|
protected List<String> |
getBundlesInDir(String dir) |
protected String |
getJarUrl(Class clazz) |
protected Properties |
getProperties(String fileName) |
protected Map<String,String> |
getRunLevelDirs(String dir)
Return a list of directories under a directory whose name is a number
|
protected String |
getVersion(URL url)
Gets the version used to export the packages.
|
protected static String |
getVersionFromString(String str)
Extracts numbers followed by "." or "-" from the string and joins them with "."
|
void |
init(javax.servlet.ServletContext servletContext) |
protected void |
replaceSystemPackages(Properties properties) |
protected void |
startFelix() |
protected void startFelix()
protected void addAutoStartBundles(Properties configProps)
protected Map<String,String> getRunLevelDirs(String dir)
protected void addSpringOSGiSupport()
protected void replaceSystemPackages(Properties properties)
protected void addExportedPackages(Properties strutsConfigProps, Properties configProps)
protected String getVersion(URL url)
protected static String getVersionFromString(String str)
protected Properties getProperties(String fileName)
public Map<String,org.osgi.framework.Bundle> getBundles()
getBundles
in interface OsgiHost
public Map<String,org.osgi.framework.Bundle> getActiveBundles()
getActiveBundles
in interface OsgiHost
public org.osgi.framework.BundleContext getBundleContext()
getBundleContext
in interface OsgiHost
public void destroy() throws Exception
Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.