Class OSGiApp
java.lang.Object
org.eclipse.jetty.deploy.App
org.eclipse.jetty.osgi.OSGiApp
OSGiApp
Base class representing info about a WebAppContext/ContextHandler to be deployed into jetty.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.osgi.framework.Bundleprotected Resourceprotected ContextHandlerprotected Stringprotected Stringprotected org.osgi.framework.ServiceRegistration -
Constructor Summary
ConstructorsConstructorDescriptionOSGiApp(DeploymentManager manager, AppProvider provider, org.osgi.framework.Bundle bundle) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidorg.osgi.framework.BundleGet ContextHandler for the App.The context pathApprelating to how it is installed on the jetty server side.org.osgi.framework.ServiceRegistrationvoidRegister the Jetty deployed context/webapp as a service, as according to the OSGi Web Application Specification.voidsetContextHandler(ContextHandler contextHandler) voidsetContextPath(String contextPath) voidsetPathToResourceBase(String path) voidsetRegistration(org.osgi.framework.ServiceRegistration registration) Methods inherited from class App
getAppProvider, getDeploymentManager, getEnvironmentName, getPath, getProperties, toString
-
Field Details
-
_bundle
protected org.osgi.framework.Bundle _bundle -
_registration
protected org.osgi.framework.ServiceRegistration _registration -
_contextHandler
-
_pathToResourceBase
-
_contextPath
-
_bundleResource
-
-
Constructor Details
-
OSGiApp
public OSGiApp(DeploymentManager manager, AppProvider provider, org.osgi.framework.Bundle bundle) throws Exception - Parameters:
manager- the DeploymentManager to which to deployprovider- the provider that discovered the context/webappbundle- the bundle associated with the context/webapp- Throws:
Exception
-
-
Method Details
-
getBundleResource
-
getContextHandler
Description copied from class:AppGet ContextHandler for the App. Create it if needed.- Overrides:
getContextHandlerin classApp- Returns:
- the
ContextHandlerto use for the App when fully started. (Portions of which might be ignored when App is not yetAppLifeCycle.DEPLOYEDorAppLifeCycle.STARTED) - Throws:
Exception- if unable to get the context handler
-
setContextHandler
-
getPathToResourceBase
-
setPathToResourceBase
-
getContextPath
Description copied from class:AppThe context pathApprelating to how it is installed on the jetty server side.- Overrides:
getContextPathin classApp- Returns:
- the contextPath for the App
-
setContextPath
-
getBundleSymbolicName
-
getBundleVersionAsString
-
getBundle
public org.osgi.framework.Bundle getBundle() -
setRegistration
public void setRegistration(org.osgi.framework.ServiceRegistration registration) -
getRegistration
public org.osgi.framework.ServiceRegistration getRegistration() -
registerAsOSGiService
-
deregisterAsOSGiService
-