org.apache.xmlrpc.common

Class XmlRpcHttpRequestConfigImpl

Implemented Interfaces:
XmlRpcConfig, XmlRpcHttpConfig, XmlRpcHttpRequestConfig, XmlRpcRequestConfig, XmlRpcStreamConfig, XmlRpcStreamRequestConfig
Known Direct Subclasses:
RequestData, XmlRpcClientConfigImpl

public class XmlRpcHttpRequestConfigImpl
extends XmlRpcConfigImpl
implements XmlRpcHttpRequestConfig

Default implementation of a request configuration.

Fields inherited from interface org.apache.xmlrpc.common.XmlRpcStreamConfig

UTF8_ENCODING

Method Summary

String
getBasicPassword()
Returns the password being used for basic HTTP authentication.
String
getBasicUserName()
Returns the user name being used for basic HTTP authentication.
int
getConnectionTimeout()
Return the connection timeout in milliseconds
int
getReplyTimeout()
Return the reply timeout in milliseconds
boolean
isEnabledForExceptions()
Returns, whether the response should contain a "faultCause" element in case of errors.
boolean
isGzipCompressing()
Returns, whether the request stream is being compressed.
boolean
isGzipRequesting()
Returns, whether compression is requested for the response stream.
void
setBasicPassword(String pPassword)
Sets the password for basic authentication.
void
setBasicUserName(String pUser)
Sets the user name for basic authentication.
void
setConnectionTimeout(int pTimeout)
Set the connection timeout in milliseconds.
void
setEnabledForExceptions(boolean pEnabledForExceptions)
Sets, whether the response should contain a "faultCause" element in case of errors.
void
setGzipCompressing(boolean pCompressing)
Sets, whether gzip compression is being used for transmitting the request.
void
setGzipRequesting(boolean pRequesting)
Sets, whether gzip compression is requested for the response.
void
setReplyTimeout(int pTimeout)
Set the reply timeout in milliseconds.

Methods inherited from class org.apache.xmlrpc.XmlRpcConfigImpl

getBasicEncoding, getEncoding, getTimeZone, isContentLengthOptional, isEnabledForExtensions, setBasicEncoding, setContentLengthOptional, setEnabledForExtensions, setEncoding, setTimeZone

Method Details

getBasicPassword

public String getBasicPassword()
Returns the password being used for basic HTTP authentication.
Specified by:
getBasicPassword in interface XmlRpcHttpRequestConfig
Returns:
Password or null, if no basic HTTP authentication is beind used.

getBasicUserName

public String getBasicUserName()
Returns the user name being used for basic HTTP authentication.
Specified by:
getBasicUserName in interface XmlRpcHttpRequestConfig
Returns:
User name or null, if no basic HTTP authentication is being used.

getConnectionTimeout

public int getConnectionTimeout()
Return the connection timeout in milliseconds
Specified by:
getConnectionTimeout in interface XmlRpcHttpRequestConfig
Returns:
connection timeout in milliseconds or 0 if no set

getReplyTimeout

public int getReplyTimeout()
Return the reply timeout in milliseconds
Specified by:
getReplyTimeout in interface XmlRpcHttpRequestConfig
Returns:
reply timeout in milliseconds or 0 if no set

isEnabledForExceptions

public boolean isEnabledForExceptions()
Returns, whether the response should contain a "faultCause" element in case of errors. The "faultCause" is an exception, which the server has trapped and written into a byte stream as a serializable object.
Specified by:
isEnabledForExceptions in interface XmlRpcStreamRequestConfig

isGzipCompressing

public boolean isGzipCompressing()
Returns, whether the request stream is being compressed. Note, that the response stream may still be uncompressed.
Specified by:
isGzipCompressing in interface XmlRpcStreamRequestConfig
Returns:
Whether to use Gzip compression or not. Defaults to false.

isGzipRequesting

public boolean isGzipRequesting()
Specified by:
isGzipRequesting in interface XmlRpcStreamRequestConfig
Returns:
Whether to use Gzip compression or not. Defaults to false.

setBasicPassword

public void setBasicPassword(String pPassword)
Sets the password for basic authentication.
Parameters:
pPassword - The password.

setBasicUserName

public void setBasicUserName(String pUser)
Sets the user name for basic authentication.
Parameters:
pUser - The user name.

setConnectionTimeout

public void setConnectionTimeout(int pTimeout)
Set the connection timeout in milliseconds.
Parameters:
pTimeout - connection timeout, 0 to disable it

setEnabledForExceptions

public void setEnabledForExceptions(boolean pEnabledForExceptions)
Sets, whether the response should contain a "faultCause" element in case of errors. The "faultCause" is an exception, which the server has trapped and written into a byte stream as a serializable object.

setGzipCompressing

public void setGzipCompressing(boolean pCompressing)
Sets, whether gzip compression is being used for transmitting the request.
Parameters:
pCompressing - True for enabling gzip compression, false otherwise.

setGzipRequesting

public void setGzipRequesting(boolean pRequesting)
Sets, whether gzip compression is requested for the response.
Parameters:
pRequesting - True for requesting gzip compression, false otherwise.

setReplyTimeout

public void setReplyTimeout(int pTimeout)
Set the reply timeout in milliseconds.
Parameters:
pTimeout - reply timeout, 0 to disable it

Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved.