android - HttpRequest for content-length in response header -
android - HttpRequest for content-length in response header -
this httprequest google drive.
when parse response header, content-length null. true when utilize getcontentlength() method (see below), , when print out response header.tostring -- value isn't there.
i'm not familiar httprequests, have inquire content-length included in response?
public static httpresponse getfile_contents(string downloadurl, drive drive) throws ioexception{ httprequest request = drive.getrequestfactory(). buildgetrequest(new genericurl(downloadurl)); httpresponse response = request.execute(); long length = response.getheaders().getcontentlength(); //length null... homecoming response; }
android http-headers google-drive-sdk
Comments
Post a Comment