Skip to content

Commit e4bec39

Browse files
author
Stephane Landelle
committed
minor clean up
1 parent 188f25b commit e4bec39

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/main/java/com/ning/http/multipart/MultipartRequestEntity.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ public static byte[] generateMultipartBoundary() {
7070

7171
/**
7272
* Creates a new multipart entity containing the given parts.
73-
*
7473
* @param parts The parts to include.
7574
*/
7675
public MultipartRequestEntity(Part[] parts, FluentCaseInsensitiveStringsMap requestHeaders) {
@@ -104,8 +103,7 @@ private String computeContentType(String base) {
104103
}
105104

106105
/**
107-
* Returns the MIME boundary string that is used to demarcate boundaries of this part. The first call to this method will implicitly create a new boundary string. To create a boundary string first the HttpMethodParams.MULTIPART_BOUNDARY parameter is considered. Otherwise a
108-
* random one is generated.
106+
* Returns the MIME boundary string that is used to demarcate boundaries of this part.
109107
*
110108
* @return The boundary string of this entity in ASCII encoding.
111109
*/
@@ -117,8 +115,8 @@ protected byte[] getMultipartBoundary() {
117115
* Returns <code>true</code> if all parts are repeatable, <code>false</code> otherwise.
118116
*/
119117
public boolean isRepeatable() {
120-
for (int i = 0; i < parts.length; i++) {
121-
if (!parts[i].isRepeatable()) {
118+
for (Part part : parts) {
119+
if (!part.isRepeatable()) {
122120
return false;
123121
}
124122
}

0 commit comments

Comments
 (0)