railo.runtime.net.http
Class HttpClientUtil

java.lang.Object
  extended by railo.runtime.net.http.HttpClientUtil

public final class HttpClientUtil
extends Object

Utitlities class for HTTP Client


Field Summary
static short MAX_REDIRECT
          Maximal count of redirects (5)
static int STATUS_REDIRECT_FOUND
          Constant value for HTTP Status Code "Found 302"
static int STATUS_REDIRECT_MOVED_PERMANENTLY
          Constant value for HTTP Status Code "moved Permanently 301"
static int STATUS_REDIRECT_SEE_OTHER
          Constant value for HTTP Status Code "see other 303"
 
Constructor Summary
HttpClientUtil()
           
 
Method Summary
static org.apache.commons.httpclient.HttpMethod clone(org.apache.commons.httpclient.HttpMethod src, URL url)
          FUNKTIONIERT NICHT, HOST WIRD NICHT マBERNOMMEN Clones a http method and sets a new url
static org.apache.commons.httpclient.HttpMethod execute(org.apache.commons.httpclient.HttpClient client, org.apache.commons.httpclient.HttpMethod method, boolean doRedirect)
          Execute a HTTTP Client and follow redirect over different hosts
static String mergePath(String current, String realPath)
          merge to pathes to one
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MAX_REDIRECT

public static final short MAX_REDIRECT
Maximal count of redirects (5)

See Also:
Constant Field Values

STATUS_REDIRECT_MOVED_PERMANENTLY

public static final int STATUS_REDIRECT_MOVED_PERMANENTLY
Constant value for HTTP Status Code "moved Permanently 301"

See Also:
Constant Field Values

STATUS_REDIRECT_FOUND

public static final int STATUS_REDIRECT_FOUND
Constant value for HTTP Status Code "Found 302"

See Also:
Constant Field Values

STATUS_REDIRECT_SEE_OTHER

public static final int STATUS_REDIRECT_SEE_OTHER
Constant value for HTTP Status Code "see other 303"

See Also:
Constant Field Values
Constructor Detail

HttpClientUtil

public HttpClientUtil()
Method Detail

execute

public static org.apache.commons.httpclient.HttpMethod execute(org.apache.commons.httpclient.HttpClient client,
                                                               org.apache.commons.httpclient.HttpMethod method,
                                                               boolean doRedirect)
                                                        throws org.apache.commons.httpclient.HttpException,
                                                               IOException
Execute a HTTTP Client and follow redirect over different hosts

Parameters:
client -
method -
doRedirect -
Returns:
Throws:
IOException
org.apache.commons.httpclient.HttpException

clone

public static org.apache.commons.httpclient.HttpMethod clone(org.apache.commons.httpclient.HttpMethod src,
                                                             URL url)
FUNKTIONIERT NICHT, HOST WIRD NICHT マBERNOMMEN Clones a http method and sets a new url

Parameters:
src -
url -
Returns:

mergePath

public static String mergePath(String current,
                               String realPath)
                        throws MalformedURLException
merge to pathes to one

Parameters:
current -
realPath -
Returns:
Throws:
MalformedURLException


Copyright © 2012 Railo