|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.struts2.osgi.FelixOsgiHost
public class FelixOsgiHost
Apache felix implementation of an OsgiHost
See http://felix.apache.org/site/apache-felix-framework-launching-and-embedding.html
Servlet config params:
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.
Field Summary |
---|
Fields inherited from interface org.apache.struts2.osgi.OsgiHost |
---|
OSGI_BUNDLE_CONTEXT, OSGI_HEADER_STRUTS_ENABLED |
Constructor Summary | |
---|---|
FelixOsgiHost()
|
Method Summary | |
---|---|
protected void |
addAutoStartBundles(java.util.Properties configProps)
|
protected void |
addExportedPackages(java.util.Properties strutsConfigProps,
java.util.Properties configProps)
|
protected void |
addSpringOSGiSupport()
|
void |
destroy()
|
java.util.Map<java.lang.String,org.osgi.framework.Bundle> |
getActiveBundles()
|
org.osgi.framework.BundleContext |
getBundleContext()
|
java.util.Map<java.lang.String,org.osgi.framework.Bundle> |
getBundles()
This bundle map will not change, but the status of the bundles can change over time. |
protected java.util.List<java.lang.String> |
getBundlesInDir(java.lang.String dir)
|
protected java.lang.String |
getJarUrl(java.lang.Class clazz)
|
protected java.util.Properties |
getProperties(java.lang.String fileName)
|
protected java.util.Map<java.lang.String,java.lang.String> |
getRunLevelDirs(java.lang.String dir)
Return a list of directories under a directory whose name is a number |
protected java.lang.String |
getVersion(java.net.URL url)
Gets the version used to export the packages. |
protected static java.lang.String |
getVersionFromString(java.lang.String str)
Extracts numbers followed by "." or "-" from the string and joins them with "." |
void |
init(javax.servlet.ServletContext servletContext)
|
protected void |
replaceSystemPackages(java.util.Properties properties)
|
protected void |
startFelix()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FelixOsgiHost()
Method Detail |
---|
protected void startFelix()
protected void addAutoStartBundles(java.util.Properties configProps)
protected java.util.Map<java.lang.String,java.lang.String> getRunLevelDirs(java.lang.String dir)
protected java.util.List<java.lang.String> getBundlesInDir(java.lang.String dir)
protected void addSpringOSGiSupport()
protected java.lang.String getJarUrl(java.lang.Class clazz)
protected void replaceSystemPackages(java.util.Properties properties)
protected void addExportedPackages(java.util.Properties strutsConfigProps, java.util.Properties configProps)
protected java.lang.String getVersion(java.net.URL url)
protected static java.lang.String getVersionFromString(java.lang.String str)
protected java.util.Properties getProperties(java.lang.String fileName)
public java.util.Map<java.lang.String,org.osgi.framework.Bundle> getBundles()
getBundles
in interface OsgiHost
public java.util.Map<java.lang.String,org.osgi.framework.Bundle> getActiveBundles()
getActiveBundles
in interface OsgiHost
public org.osgi.framework.BundleContext getBundleContext()
getBundleContext
in interface OsgiHost
public void destroy() throws java.lang.Exception
destroy
in interface OsgiHost
java.lang.Exception
public void init(javax.servlet.ServletContext servletContext)
init
in interface OsgiHost
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |