类 DefaultServerCodecConfigurer
- java.lang.Object
- org.springframework.http.codec.support.DefaultServerCodecConfigurer
- 所有已实现的接口:
CodecConfigurer,ServerCodecConfigurer
public class DefaultServerCodecConfigurer extends Object implements ServerCodecConfigurer
Default implementation ofServerCodecConfigurer.- 从以下版本开始:
- 5.0
- 作者:
- Rossen Stoyanchev
嵌套类概要
从接口继承的嵌套类/接口 org.springframework.http.codec.CodecConfigurer
CodecConfigurer.CustomCodecs, CodecConfigurer.DefaultCodecConfig, CodecConfigurer.DefaultCodecs
从接口继承的嵌套类/接口 org.springframework.http.codec.ServerCodecConfigurer
ServerCodecConfigurer.ServerDefaultCodecs
字段概要
字段 修饰符和类型 字段 说明 protected org.springframework.http.codec.support.BaseCodecConfigurer.DefaultCustomCodecscustomCodecsprotected org.springframework.http.codec.support.BaseDefaultCodecsdefaultCodecs
构造器概要
构造器 构造器 说明 DefaultServerCodecConfigurer()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 DefaultServerCodecConfigurerclone()Create a copy of thisCodecConfigurer.protected org.springframework.http.codec.support.BaseDefaultCodecscloneDefaultCodecs()Sub-classes should override this to create a deep copy ofBaseDefaultCodecswhich can be client or server specific.CodecConfigurer.CustomCodecscustomCodecs()Register custom HTTP message readers or writers in addition to the ones registered by default.ServerCodecConfigurer.ServerDefaultCodecsdefaultCodecs()Provides a way to customize or replace HTTP message readers and writers registered by default.List<HttpMessageReader<?>>getReaders()Obtain the configured HTTP message readers.List<HttpMessageWriter<?>>getWriters()Obtain the configured HTTP message writers.voidregisterDefaults(boolean shouldRegister)Provides a way to completely turn off registration of default HTTP message readers and writers, and instead rely only on the ones provided viaCodecConfigurer.customCodecs().从类继承的方法 java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
从接口继承的方法 org.springframework.http.codec.CodecConfigurer
customCodecs, getReaders, getWriters, registerDefaults
构造器详细资料
DefaultServerCodecConfigurer
public DefaultServerCodecConfigurer()
方法详细资料
defaultCodecs
public ServerCodecConfigurer.ServerDefaultCodecs defaultCodecs()
从接口复制的说明:CodecConfigurerProvides a way to customize or replace HTTP message readers and writers registered by default.
clone
public DefaultServerCodecConfigurer clone()
从接口复制的说明:CodecConfigurerCreate a copy of thisCodecConfigurer. The returned clone has its own lists of default and custom codecs and generally can be configured independently. Keep in mind however that codec instances (if any are configured) are themselves not cloned.- 指定者:
clone在接口中CodecConfigurer- 指定者:
clone在接口中ServerCodecConfigurer
cloneDefaultCodecs
protected org.springframework.http.codec.support.BaseDefaultCodecs cloneDefaultCodecs()
Sub-classes should override this to create a deep copy ofBaseDefaultCodecswhich can be client or server specific.
registerDefaults
public void registerDefaults(boolean shouldRegister)
从接口复制的说明:CodecConfigurerProvides a way to completely turn off registration of default HTTP message readers and writers, and instead rely only on the ones provided viaCodecConfigurer.customCodecs().By default this is set to
"true"in which case default registrations are made; setting this tofalsedisables default registrations.- 指定者:
registerDefaults在接口中CodecConfigurer
customCodecs
public CodecConfigurer.CustomCodecs customCodecs()
从接口复制的说明:CodecConfigurerRegister custom HTTP message readers or writers in addition to the ones registered by default.- 指定者:
customCodecs在接口中CodecConfigurer
getReaders
public List<HttpMessageReader<?>> getReaders()
从接口复制的说明:CodecConfigurerObtain the configured HTTP message readers.- 指定者:
getReaders在接口中CodecConfigurer
getWriters
public List<HttpMessageWriter<?>> getWriters()
从接口复制的说明:CodecConfigurerObtain the configured HTTP message writers.- 指定者:
getWriters在接口中CodecConfigurer