类 BaseCodecConfigurer.DefaultCustomCodecs
java.lang.Object
cn.taketoday.http.codec.support.BaseCodecConfigurer.DefaultCustomCodecs
- 所有已实现的接口:
CodecConfigurer.CustomCodecs
- 封闭类:
- BaseCodecConfigurer
protected static final class BaseCodecConfigurer.DefaultCustomCodecs
extends Object
implements CodecConfigurer.CustomCodecs
Default implementation of
CustomCodecs.-
字段概要
字段修饰符和类型字段说明private final ArrayList<Consumer<CodecConfigurer.DefaultCodecConfig>>private final LinkedHashMap<HttpMessageReader<?>,Boolean> private final LinkedHashMap<HttpMessageWriter<?>,Boolean> private final LinkedHashMap<HttpMessageReader<?>,Boolean> private final LinkedHashMap<HttpMessageWriter<?>,Boolean> -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明private void(专用程序包) List<Consumer<CodecConfigurer.DefaultCodecConfig>>(专用程序包) Map<HttpMessageReader<?>,Boolean> (专用程序包) Map<HttpMessageWriter<?>,Boolean> (专用程序包) Map<HttpMessageReader<?>,Boolean> (专用程序包) Map<HttpMessageWriter<?>,Boolean> voidRegister a custom codec.voidregisterWithDefaultConfig(Object codec) Variant ofCodecConfigurer.CustomCodecs.register(Object)that also applies the below properties, if configured, viaCodecConfigurer.defaultCodecs():maxInMemorySizeenableLoggingRequestDetailsvoidregisterWithDefaultConfig(Object codec, Consumer<CodecConfigurer.DefaultCodecConfig> configConsumer) Variant ofCodecConfigurer.CustomCodecs.register(Object)that also allows the caller to apply the properties fromCodecConfigurer.DefaultCodecConfigto the given codec.voidwithDefaultCodecConfig(Consumer<CodecConfigurer.DefaultCodecConfig> codecsConfigConsumer) Register a callback for theconfigurationapplied to default codecs.
-
字段详细资料
-
typedReaders
-
typedWriters
-
objectReaders
-
objectWriters
-
defaultConfigConsumers
-
-
构造器详细资料
-
DefaultCustomCodecs
DefaultCustomCodecs() -
DefaultCustomCodecs
DefaultCustomCodecs(BaseCodecConfigurer.DefaultCustomCodecs other) Create a deep copy of the givenBaseCodecConfigurer.DefaultCustomCodecs.
-
-
方法详细资料
-
register
从接口复制的说明:CodecConfigurer.CustomCodecsRegister a custom codec. This is expected to be one of the following:HttpMessageReaderHttpMessageWriterEncoder(wrapped internally withEncoderHttpMessageWriter)Decoder(wrapped internally withDecoderHttpMessageReader)
- 指定者:
register在接口中CodecConfigurer.CustomCodecs- 参数:
codec- the codec to register
-
registerWithDefaultConfig
从接口复制的说明:CodecConfigurer.CustomCodecsVariant ofCodecConfigurer.CustomCodecs.register(Object)that also applies the below properties, if configured, viaCodecConfigurer.defaultCodecs():The properties are applied every time
CodecConfigurer.getReaders()orCodecConfigurer.getWriters()are used to obtain the list of configured readers or writers.- 指定者:
registerWithDefaultConfig在接口中CodecConfigurer.CustomCodecs- 参数:
codec- the codec to register and apply default config to
-
registerWithDefaultConfig
public void registerWithDefaultConfig(Object codec, Consumer<CodecConfigurer.DefaultCodecConfig> configConsumer) 从接口复制的说明:CodecConfigurer.CustomCodecsVariant ofCodecConfigurer.CustomCodecs.register(Object)that also allows the caller to apply the properties fromCodecConfigurer.DefaultCodecConfigto the given codec. If you want to apply all the properties, prefer usingCodecConfigurer.CustomCodecs.registerWithDefaultConfig(Object).The consumer is called every time
CodecConfigurer.getReaders()orCodecConfigurer.getWriters()are used to obtain the list of configured readers or writers.- 指定者:
registerWithDefaultConfig在接口中CodecConfigurer.CustomCodecs- 参数:
codec- the codec to registerconfigConsumer- consumer of the default config
-
withDefaultCodecConfig
public void withDefaultCodecConfig(Consumer<CodecConfigurer.DefaultCodecConfig> codecsConfigConsumer) 从接口复制的说明:CodecConfigurer.CustomCodecsRegister a callback for theconfigurationapplied to default codecs. This allows custom codecs to follow general guidelines applied to default ones, such as logging details and limiting the amount of buffered data.- 指定者:
withDefaultCodecConfig在接口中CodecConfigurer.CustomCodecs- 参数:
codecsConfigConsumer- the default codecs configuration callback
-
addCodec
-
getTypedReaders
Map<HttpMessageReader<?>,Boolean> getTypedReaders() -
getTypedWriters
Map<HttpMessageWriter<?>,Boolean> getTypedWriters() -
getObjectReaders
Map<HttpMessageReader<?>,Boolean> getObjectReaders() -
getObjectWriters
Map<HttpMessageWriter<?>,Boolean> getObjectWriters() -
getDefaultConfigConsumers
List<Consumer<CodecConfigurer.DefaultCodecConfig>> getDefaultConfigConsumers()
-