eXo JCR :: Open Office WebDav plugin 1.15.8-GA

org.exoplatform.applications.ooplugin.client
Class HttpClient

java.lang.Object
  extended by org.exoplatform.applications.ooplugin.client.HttpClient

public class HttpClient
extends Object

Created by The eXo Platform SAS.

Version:
$Id: $

Field Summary
static String CLIENT_DESCRIPTION
           
static String CLIENT_VERSION
           
static String HEADER_SPLITTER
           
 
Constructor Summary
HttpClient(String server, int port)
           
 
Method Summary
 void conect()
           
 int execute()
           
 int getContentLength()
           
 String getMainHeader()
           
 int getReplyCode()
           
 String getResponseBody()
           
 byte[] getResponseBytes()
           
 String getResponseHeader(String headerName)
           
 ArrayList<String> getResponseHeadersNames()
           
 InputStream getResponseStream()
           
protected  String readLine()
           
 void sendRequest(String request)
           
 void setHttpCommand(String httpCommand)
           
 void setRequestBody(byte[] httpRequestBodyBytes)
           
 void setRequestBody(String httpRequestBodyStr)
           
 void setRequestHeader(String headerName, String headerValue)
           
 void setRequestPath(String httpRequestStr)
           
 void setRequestStream(InputStream httpRequestBodyStream)
           
 void zeroRequestBody()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLIENT_DESCRIPTION

public static final String CLIENT_DESCRIPTION
See Also:
Constant Field Values

HEADER_SPLITTER

public static final String HEADER_SPLITTER
See Also:
Constant Field Values

CLIENT_VERSION

public static final String CLIENT_VERSION
See Also:
Constant Field Values
Constructor Detail

HttpClient

public HttpClient(String server,
                  int port)
Method Detail

conect

public void conect()
            throws Exception
Throws:
Exception

setHttpCommand

public void setHttpCommand(String httpCommand)

setRequestPath

public void setRequestPath(String httpRequestStr)

setRequestHeader

public void setRequestHeader(String headerName,
                             String headerValue)

setRequestBody

public void setRequestBody(String httpRequestBodyStr)

setRequestBody

public void setRequestBody(byte[] httpRequestBodyBytes)

setRequestStream

public void setRequestStream(InputStream httpRequestBodyStream)

zeroRequestBody

public void zeroRequestBody()

sendRequest

public void sendRequest(String request)

getMainHeader

public String getMainHeader()

getContentLength

public int getContentLength()

getResponseHeadersNames

public ArrayList<String> getResponseHeadersNames()

getResponseHeader

public String getResponseHeader(String headerName)

getReplyCode

public int getReplyCode()

getResponseBody

public String getResponseBody()

getResponseBytes

public byte[] getResponseBytes()

getResponseStream

public InputStream getResponseStream()

execute

public int execute()
            throws IOException
Throws:
IOException

readLine

protected String readLine()
                   throws IOException
Throws:
IOException

eXo JCR :: Open Office WebDav plugin 1.15.8-GA

Copyright © 2014 eXo Platform SAS. All Rights Reserved.