org.simpleframework.http.Request.getParts()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(1.8k)|赞(0)|评价(0)|浏览(250)

本文整理了Java中org.simpleframework.http.Request.getParts方法的一些代码示例,展示了Request.getParts的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Request.getParts方法的具体详情如下:
包路径:org.simpleframework.http.Request
类名称:Request
方法名:getParts

Request.getParts介绍

[英]This method is used to get all Part objects that are associated with the request. Each attachment contains the body and headers associated with it. If the request is not a multipart POST request then this will return an empty list.
[中]此方法用于获取与请求关联的所有Part对象。每个附件都包含与其关联的正文和标题。如果请求不是一个多部分POST请求,那么它将返回一个空列表。

代码示例

代码示例来源:origin: ngallagher/simpleframework

/**
* This method is used to get all <code>Part</code> objects that
* are associated with the request. Each attachment contains the 
* body and headers associated with it. If the request is not a 
* multipart POST request then this will return an empty list.
* 
* @return the list of parts associated with this request
*/     
public List<Part> getParts() {
 return request.getParts();
}

代码示例来源:origin: org.simpleframework/simple-http

/**
* This method is used to get all <code>Part</code> objects that
* are associated with the request. Each attachment contains the 
* body and headers associated with it. If the request is not a 
* multipart POST request then this will return an empty list.
* 
* @return the list of parts associated with this request
*/     
public List<Part> getParts() {
 return request.getParts();
}

代码示例来源:origin: org.simpleframework/simple

/**
* This method is used to get all <code>Part</code> objects that
* are associated with the request. Each attachment contains the 
* body and headers associated with it. If the request is not a 
* multipart POST request then this will return an empty list.
* 
* @return the list of parts associated with this request
*/     
public List<Part> getParts() {
 return request.getParts();
}

代码示例来源:origin: CodeStory/fluent-http

@Override
public List<Part> parts() {
 return request.getParts().stream().map(SimplePart::new).collect(toList());
}

相关文章