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 AbstractLifeCycle
AbstractLifeCycle.AbstractLifeCycleListener, AbstractLifeCycle.StopExceptionNested classes/interfaces inherited from interface LifeCycle
LifeCycle.Listener -
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractContextProvider(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_CLASSESproperty.Get the defaultsDescriptor.booleanisDeployable(org.osgi.framework.Bundle bundle) booleanisDeployable(org.osgi.framework.ServiceReference service) booleanGet the extractWars.booleanGet the parentLoaderPriority.voidsetConfigurationClasses(String configurations) This is equivalent to setting theDeployable.CONFIGURATION_CLASSESproperty.voidsetConfigurationClasses(String[] configurations) This is equivalent to setting theDeployable.CONFIGURATION_CLASSESproperty.voidsetDefaultsDescriptor(String defaultsDescriptor) Set the defaultsDescriptor.voidsetDeploymentManager(DeploymentManager deploymentManager) Set the Deployment ManagervoidsetExtractWars(boolean extractWars) Set the extractWars.voidsetParentLoaderPriority(boolean parentLoaderPriority) Set the parentLoaderPriority.voidsetTldBundles(String tldBundles) Methods inherited from class AbstractLifeCycle
addEventListener, doStart, doStop, getEventListeners, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeEventListener, setEventListeners, start, stop, toStringMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface LifeCycle
addEventListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeEventListener, start, stop
-
Constructor Details
-
AbstractContextProvider
-
-
Method Details
-
getServer
-
getProperties
-
createContextHandler
Description copied from interface:AppProviderCreate a ContextHandler for an App- Specified by:
createContextHandlerin interfaceAppProvider- Parameters:
app- The App- Returns:
- A ContextHandler
- Throws:
Exception- if unable to create context
-
setDeploymentManager
Description copied from interface:AppProviderSet the Deployment Manager- Specified by:
setDeploymentManagerin interfaceAppProvider- Parameters:
deploymentManager- the deployment manager
-
getEnvironmentName
- Specified by:
getEnvironmentNamein interfaceAppProvider- Returns:
- The name of the
Environmentthis provider is for.
-
getDeploymentManager
-
isExtractWars
public boolean isExtractWars()Get the extractWars. This is equivalent to getting theDeployable.EXTRACT_WARSproperty.- Returns:
- the extractWars
-
setExtractWars
public void setExtractWars(boolean extractWars) Set the extractWars. This is equivalent to setting theDeployable.EXTRACT_WARSproperty.- Parameters:
extractWars- the extractWars to set
-
isParentLoaderPriority
public boolean isParentLoaderPriority()Get the parentLoaderPriority. This is equivalent to getting theDeployable.PARENT_LOADER_PRIORITYproperty.- Returns:
- the parentLoaderPriority
-
setParentLoaderPriority
public void setParentLoaderPriority(boolean parentLoaderPriority) Set the parentLoaderPriority. This is equivalent to setting theDeployable.PARENT_LOADER_PRIORITYproperty.- Parameters:
parentLoaderPriority- the parentLoaderPriority to set
-
getDefaultsDescriptor
Get the defaultsDescriptor. This is equivalent to getting theDeployable.DEFAULTS_DESCRIPTORproperty.- Returns:
- the defaultsDescriptor
-
setDefaultsDescriptor
Set the defaultsDescriptor. This is equivalent to setting theDeployable.DEFAULTS_DESCRIPTORproperty.- Parameters:
defaultsDescriptor- the defaultsDescriptor to set
-
setConfigurationClasses
This is equivalent to setting theDeployable.CONFIGURATION_CLASSESproperty.- Parameters:
configurations- The configuration class names as a comma separated list
-
setConfigurationClasses
This is equivalent to setting theDeployable.CONFIGURATION_CLASSESproperty.- Parameters:
configurations- The configuration class names.
-
getConfigurationClasses
This is equivalent to getting theDeployable.CONFIGURATION_CLASSESproperty.- 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)
-