Class InputStreamBodyWithLength

  • All Implemented Interfaces:
    org.apache.http.entity.mime.content.ContentBody, org.apache.http.entity.mime.content.ContentDescriptor

    public class InputStreamBodyWithLength
    extends org.apache.http.entity.mime.content.InputStreamBody
    If we want to upload a file that is a resource in a jar file, the http client expects a content length.
    • Method Detail

      • getContentLength

        public long getContentLength()
        Specified by:
        getContentLength in interface org.apache.http.entity.mime.content.ContentDescriptor
        Overrides:
        getContentLength in class org.apache.http.entity.mime.content.InputStreamBody