Code example for InputStreamEntity

Methods: setContentType

0
        } 
 
        public HttpUriRequest createRequest(URI uri) {
            HttpPost post = new HttpPost(uri);
            post.addHeader(X_HTTP_METHOD_OVERRIDE, "PUT");
            // mMediaInputStream.reset(); 
            InputStreamEntity entity = new InputStreamEntity(mMediaInputStream,
                    -1 /* read until EOF */); 
            entity.setContentType(mContentType);
            post.setEntity(entity);
            return post;
        } 
    } 
 
    /** 
     * @deprecated Use AndroidGDAtaClient(Context) instead. 
     */ 
    public AndroidGDataClient(ContentResolver resolver) {
        mHttpClient = new GoogleHttpClient(resolver, DEFAULT_USER_AGENT_APP_VERSION,
                true /* gzip capable */); 
        mHttpClient.enableCurlLogging(TAG, Log.VERBOSE);