接口 WebServerApplicationContext
- 所有超级接口:
org.springframework.context.ApplicationContext
,org.springframework.context.ApplicationEventPublisher
,org.springframework.beans.factory.BeanFactory
,org.springframework.core.env.EnvironmentCapable
,org.springframework.beans.factory.HierarchicalBeanFactory
,org.springframework.beans.factory.ListableBeanFactory
,org.springframework.context.MessageSource
,org.springframework.core.io.ResourceLoader
,org.springframework.core.io.support.ResourcePatternResolver
- 所有已知实现类:
AnnotationConfigReactiveWebServerApplicationContext
,AnnotationConfigServletWebServerApplicationContext
,ReactiveWebServerApplicationContext
,ServletWebServerApplicationContext
,XmlServletWebServerApplicationContext
public interface WebServerApplicationContext extends org.springframework.context.ApplicationContext
Interface to be implemented byapplication contexts
that create and manage the lifecycle of an embeddedWebServer
.- 从以下版本开始:
- 2.0.0
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 String
getServerNamespace()
Returns the namespace of the web server application context ornull
if no namespace has been set.WebServer
getWebServer()
Returns theWebServer
that was created by the context ornull
if the server has not yet been created.从接口继承的方法 org.springframework.context.ApplicationContext
getApplicationName, getAutowireCapableBeanFactory, getDisplayName, getId, getParent, getStartupDate
从接口继承的方法 org.springframework.beans.factory.BeanFactory
containsBean, getAliases, getBean, getBean, getBean, getBean, getBean, getBeanProvider, getBeanProvider, getType, isPrototype, isSingleton, isTypeMatch, isTypeMatch
从接口继承的方法 org.springframework.beans.factory.HierarchicalBeanFactory
containsLocalBean, getParentBeanFactory
从接口继承的方法 org.springframework.beans.factory.ListableBeanFactory
containsBeanDefinition, findAnnotationOnBean, getBeanDefinitionCount, getBeanDefinitionNames, getBeanNamesForAnnotation, getBeanNamesForType, getBeanNamesForType, getBeanNamesForType, getBeansOfType, getBeansOfType, getBeansWithAnnotation
方法详细资料
getWebServer
WebServer getWebServer()
Returns theWebServer
that was created by the context ornull
if the server has not yet been created.- 返回:
- the web server
getServerNamespace
String getServerNamespace()
Returns the namespace of the web server application context ornull
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).- 返回:
- the server namespace