类 ResourceEncoder
java.lang.Object
cn.taketoday.core.codec.AbstractEncoder<T>
cn.taketoday.core.codec.AbstractSingleValueEncoder<Resource>
cn.taketoday.core.codec.ResourceEncoder
Encoder for
Resources.- 从以下版本开始:
- 4.0
- 作者:
- Arjen Poutsma
-
字段概要
字段从类继承的字段 cn.taketoday.core.codec.AbstractEncoder
logger -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明booleancanEncode(ResolvableType elementType, MimeType mimeType) Whether the encoder supports the given source element type and the MIME type for the output stream.protected reactor.core.publisher.Flux<DataBuffer>encode(Resource resource, DataBufferFactory bufferFactory, ResolvableType type, MimeType mimeType, Map<String, Object> hints) EncodeTto an outputDataBufferstream.从类继承的方法 cn.taketoday.core.codec.AbstractSingleValueEncoder
encode从类继承的方法 cn.taketoday.core.codec.AbstractEncoder
getEncodableMimeTypes, getLogger, setLogger从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait从接口继承的方法 cn.taketoday.core.codec.Encoder
encodeValue, getEncodableMimeTypes
-
字段详细资料
-
DEFAULT_BUFFER_SIZE
public static final int DEFAULT_BUFFER_SIZEThe default buffer size used by the encoder.- 另请参阅:
-
-
构造器详细资料
-
ResourceEncoder
public ResourceEncoder() -
ResourceEncoder
public ResourceEncoder(int bufferSize)
-
-
方法详细资料
-
canEncode
从接口复制的说明:EncoderWhether the encoder supports the given source element type and the MIME type for the output stream. -
encode
protected reactor.core.publisher.Flux<DataBuffer> encode(Resource resource, DataBufferFactory bufferFactory, ResolvableType type, @Nullable MimeType mimeType, @Nullable Map<String, Object> hints) 从类复制的说明:AbstractSingleValueEncoderEncodeTto an outputDataBufferstream.- 指定者:
encode在类中AbstractSingleValueEncoder<Resource>- 参数:
resource- the value to processbufferFactory- a buffer factory used to create the outputtype- the stream element type to processmimeType- the mime type to processhints- additional information about how to do decode, optional- 返回:
- the output stream
-