类 DefaultParts
java.lang.Object
cn.taketoday.http.codec.multipart.DefaultParts
Default implementations of
Part and subtypes.- 从以下版本开始:
- 4.0
- 作者:
- Arjen Poutsma
-
嵌套类概要
嵌套类修饰符和类型类说明private static classAbstract base class.private static interfacePart content abstraction.private static classDefault implementation ofFilePart.private static classDefault implementation ofFormFieldPart.private static classDefault implementation ofPart.private static final recordContentimplementation based on a file.private static final recordContentimplementation based on a flux of data buffers. -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static FormFieldPartformFieldPart(HttpHeaders headers, String value) Create a newFormFieldPartwith the given parameters.static Partpart(HttpHeaders headers, Path file, reactor.core.scheduler.Scheduler scheduler) static Partpart(HttpHeaders headers, reactor.core.publisher.Flux<cn.taketoday.core.io.buffer.DataBuffer> dataBuffers) private static PartpartInternal(HttpHeaders headers, DefaultParts.Content content)
-
构造器详细资料
-
DefaultParts
DefaultParts()
-
-
方法详细资料
-
formFieldPart
Create a newFormFieldPartwith the given parameters.- 参数:
headers- the part headersvalue- the form field value- 返回:
- the created part
-
part
public static Part part(HttpHeaders headers, reactor.core.publisher.Flux<cn.taketoday.core.io.buffer.DataBuffer> dataBuffers) Create a newPartorFilePartwith the given parameters. ReturnsFilePartif theContent-Dispositionof the given headers contains a filename, or a "normal"Partotherwise- 参数:
headers- the part headersdataBuffers- the content of the part- 返回:
PartorFilePart, depending onHttpHeaders.getContentDisposition()
-
part
Create a newPartorFilePartbased on the given file. ReturnsFilePartif theContent-Dispositionof the given headers contains a filename, or a "normal"Partotherwise- 参数:
headers- the part headersfile- the filescheduler- the scheduler used for reading the file- 返回:
PartorFilePart, depending onHttpHeaders.getContentDisposition()
-
partInternal
-