Example usage for org.apache.commons.httpclient.methods.multipart Part getLengthOfParts

List of usage examples for org.apache.commons.httpclient.methods.multipart Part getLengthOfParts

Introduction

In this page you can find the example usage for org.apache.commons.httpclient.methods.multipart Part getLengthOfParts.

Prototype

public static long getLengthOfParts(Part[] paramArrayOfPart, byte[] paramArrayOfByte) throws IOException 

Source Link

Usage

From source file:org.apache.commons.httpclient.methods.multipart.MultipartEntity.java

public long getContentLength() {
    try {//w  ww . j a  v  a 2 s .co m
        return Part.getLengthOfParts(parts, getMultipartBoundary());
    } catch (Exception e) {
        return 0;
    }
}