Package org.eclipse.jetty.osgi
Class AbstractContextProvider
java.lang.Object
org.eclipse.jetty.util.component.AbstractLifeCycle
org.eclipse.jetty.osgi.AbstractContextProvider
- All Implemented Interfaces:
AppProvider
,LifeCycle
- Direct Known Subclasses:
BundleContextProvider
,BundleWebAppProvider
AbstractContextProvider
Base class for DeploymentManager Providers that can deploy ContextHandlers into Jetty that have been discovered via OSGI either as bundles or services.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
AbstractLifeCycle.AbstractLifeCycleListener, AbstractLifeCycle.StopException
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle
LifeCycle.Listener
-
Field Summary
-
Constructor Summary
ConstructorDescriptionAbstractContextProvider
(String environment, Server server, ContextFactory contextFactory) -
Method Summary
Modifier and TypeMethodDescriptioncreateContextHandler
(App app) Create a ContextHandler for an AppString[]
This is equivalent to getting theDeployable.CONFIGURATION_CLASSES
property.Get the defaultsDescriptor.boolean
isDeployable
(org.osgi.framework.Bundle bundle) boolean
isDeployable
(org.osgi.framework.ServiceReference service) boolean
Get the extractWars.boolean
Get the parentLoaderPriority.void
setConfigurationClasses
(String configurations) This is equivalent to setting theDeployable.CONFIGURATION_CLASSES
property.void
setConfigurationClasses
(String[] configurations) This is equivalent to setting theDeployable.CONFIGURATION_CLASSES
property.void
setDefaultsDescriptor
(String defaultsDescriptor) Set the defaultsDescriptor.void
setDeploymentManager
(DeploymentManager deploymentManager) Set the Deployment Managervoid
setExtractWars
(boolean extractWars) Set the extractWars.void
setParentLoaderPriority
(boolean parentLoaderPriority) Set the parentLoaderPriority.void
setTldBundles
(String tldBundles) Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
addEventListener, doStart, doStop, getEventListeners, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeEventListener, setEventListeners, start, stop, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.eclipse.jetty.util.component.LifeCycle
addEventListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeEventListener, start, stop
-
Constructor Details
-
AbstractContextProvider
-
-
Method Details
-
getServer
-
getProperties
-
createContextHandler
Description copied from interface:AppProvider
Create a ContextHandler for an App- Specified by:
createContextHandler
in interfaceAppProvider
- Parameters:
app
- The App- Returns:
- A ContextHandler
- Throws:
IOException
- if unable to create contextException
- if unable to create context
-
setDeploymentManager
Description copied from interface:AppProvider
Set the Deployment Manager- Specified by:
setDeploymentManager
in interfaceAppProvider
- Parameters:
deploymentManager
- the deployment manager
-
getEnvironmentName
- Specified by:
getEnvironmentName
in interfaceAppProvider
- Returns:
- The name of the
Environment
this provider is for.
-
getDeploymentManager
-
isExtractWars
public boolean isExtractWars()Get the extractWars. This is equivalent to getting theDeployable.EXTRACT_WARS
property.- Returns:
- the extractWars
-
setExtractWars
public void setExtractWars(boolean extractWars) Set the extractWars. This is equivalent to setting theDeployable.EXTRACT_WARS
property.- Parameters:
extractWars
- the extractWars to set
-
isParentLoaderPriority
public boolean isParentLoaderPriority()Get the parentLoaderPriority. This is equivalent to getting theDeployable.PARENT_LOADER_PRIORITY
property.- Returns:
- the parentLoaderPriority
-
setParentLoaderPriority
public void setParentLoaderPriority(boolean parentLoaderPriority) Set the parentLoaderPriority. This is equivalent to setting theDeployable.PARENT_LOADER_PRIORITY
property.- Parameters:
parentLoaderPriority
- the parentLoaderPriority to set
-
getDefaultsDescriptor
Get the defaultsDescriptor. This is equivalent to getting theDeployable.DEFAULTS_DESCRIPTOR
property.- Returns:
- the defaultsDescriptor
-
setDefaultsDescriptor
Set the defaultsDescriptor. This is equivalent to setting theDeployable.DEFAULTS_DESCRIPTOR
property.- Parameters:
defaultsDescriptor
- the defaultsDescriptor to set
-
setConfigurationClasses
This is equivalent to setting theDeployable.CONFIGURATION_CLASSES
property.- Parameters:
configurations
- The configuration class names as a comma separated list
-
setConfigurationClasses
This is equivalent to setting theDeployable.CONFIGURATION_CLASSES
property.- Parameters:
configurations
- The configuration class names.
-
getConfigurationClasses
This is equivalent to getting theDeployable.CONFIGURATION_CLASSES
property.- Returns:
- The configuration class names.
-
setTldBundles
- Parameters:
tldBundles
- Comma separated list of bundles that contain tld jars that should be setup on the context instances created here.
-
getTldBundles
- Returns:
- The list of bundles that contain tld jars that should be setup on the contexts create here.
-
isDeployable
public boolean isDeployable(org.osgi.framework.Bundle bundle) -
isDeployable
public boolean isDeployable(org.osgi.framework.ServiceReference service)
-