public interface WebServerApplicationContext extends ApplicationContext
application contexts
that
create and manage the lifecycle of an embedded WebServer
.FACTORY_BEAN_PREFIX
CLASSPATH_ALL_URL_PREFIX
CLASSPATH_URL_PREFIX
Modifier and Type | Method and Description |
---|---|
String |
getServerNamespace()
Returns the namespace of the web server application context or
null if no
namespace has been set. |
WebServer |
getWebServer()
Returns the
WebServer that was created by the context or null if
the server has not yet been created. |
static boolean |
hasServerNamespace(ApplicationContext context,
String serverNamespace)
Returns
true if the specified context is a
WebServerApplicationContext with a matching server namespace. |
getApplicationName, getAutowireCapableBeanFactory, getDisplayName, getId, getParent, getStartupDate
getEnvironment
containsBeanDefinition, findAnnotationOnBean, getBeanDefinitionCount, getBeanDefinitionNames, getBeanNamesForAnnotation, getBeanNamesForType, getBeanNamesForType, getBeanNamesForType, getBeanNamesForType, getBeanProvider, getBeanProvider, getBeansOfType, getBeansOfType, getBeansWithAnnotation
containsLocalBean, getParentBeanFactory
containsBean, getAliases, getBean, getBean, getBean, getBean, getBean, getBeanProvider, getBeanProvider, getType, getType, isPrototype, isSingleton, isTypeMatch, isTypeMatch
getMessage, getMessage, getMessage
publishEvent, publishEvent
getResources
getClassLoader, getResource
WebServer getWebServer()
WebServer
that was created by the context or null
if
the server has not yet been created.String getServerNamespace()
null
if no
namespace has been set. Used for disambiguation when multiple web servers are
running in the same application (for example a management context running on a
different port).static boolean hasServerNamespace(ApplicationContext context, String serverNamespace)
true
if the specified context is a
WebServerApplicationContext
with a matching server namespace.context
- the context to checkserverNamespace
- the server namespace to match againsttrue
if the server namespace of the context matches