Class XmlRpcConfigImpl
java.lang.Object
org.apache.xmlrpc.XmlRpcConfigImpl
- All Implemented Interfaces:
XmlRpcHttpConfig, XmlRpcStreamConfig, XmlRpcConfig
- Direct Known Subclasses:
XmlRpcHttpRequestConfigImpl, XmlRpcServerConfigImpl
Default implementation of
XmlRpcConfig.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Stringprivate booleanprivate booleanprivate Stringprivate TimeZoneFields inherited from interface XmlRpcStreamConfig
UTF8_ENCODING -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the encoding being used to convert the String "username:password" into bytes.Returns the encoding being used for data encoding, when writing to a stream.Returns the timezone, which is used to interpret date/time values.booleanReturns, whether a "Content-Length" header may be omitted.booleanReturns, whether support for extensions are enabled.voidsetBasicEncoding(String pEncoding) Sets the encoding for basic authentication.voidsetContentLengthOptional(boolean pContentLengthOptional) Sets, whether a "Content-Length" header may be omitted.voidsetEnabledForExtensions(boolean pExtensions) Sets, whether extensions are enabled.voidsetEncoding(String pEncoding) Sets the requests encoding.voidsetTimeZone(TimeZone pTimeZone) Returns the timezone, which is used to interpret date/time values.
-
Field Details
-
enabledForExtensions
private boolean enabledForExtensions -
contentLengthOptional
private boolean contentLengthOptional -
basicEncoding
-
encoding
-
timeZone
-
-
Constructor Details
-
XmlRpcConfigImpl
public XmlRpcConfigImpl()
-
-
Method Details
-
isEnabledForExtensions
public boolean isEnabledForExtensions()Description copied from interface:XmlRpcConfigReturns, whether support for extensions are enabled. By default, extensions are disabled and your client is interoperable with other XML-RPC implementations. Interoperable XML-RPC implementations are those, which are compliant to the XML-RPC Specification.- Specified by:
isEnabledForExtensionsin interfaceXmlRpcConfig- Returns:
- Whether extensions are enabled or not.
-
setEnabledForExtensions
public void setEnabledForExtensions(boolean pExtensions) Sets, whether extensions are enabled. By default, the client or server is strictly compliant to the XML-RPC specification and extensions are disabled.- Parameters:
pExtensions- True to enable extensions, false otherwise.
-
setBasicEncoding
Sets the encoding for basic authentication.- Parameters:
pEncoding- The encoding; may be null, in which case UTF-8 is choosen.
-
getBasicEncoding
Description copied from interface:XmlRpcHttpConfigReturns the encoding being used to convert the String "username:password" into bytes.- Specified by:
getBasicEncodingin interfaceXmlRpcHttpConfig- Returns:
- Encoding being used for basic HTTP authentication credentials,
or null, if the default encoding
(
XmlRpcStreamConfig.UTF8_ENCODING) is being used.
-
setEncoding
Sets the requests encoding.- Parameters:
pEncoding- The requests encoding or null (default UTF-8).
-
getEncoding
Description copied from interface:XmlRpcStreamConfigReturns the encoding being used for data encoding, when writing to a stream.- Specified by:
getEncodingin interfaceXmlRpcStreamConfig- Returns:
- Suggested encoding, or null, if the
XmlRpcStreamConfig.UTF8_ENCODINGis being used.
-
isContentLengthOptional
public boolean isContentLengthOptional()Description copied from interface:XmlRpcHttpConfigReturns, whether a "Content-Length" header may be omitted. The XML-RPC specification demands, that such a header be present.- Specified by:
isContentLengthOptionalin interfaceXmlRpcHttpConfig- Returns:
- True, if the content length may be omitted.
-
setContentLengthOptional
public void setContentLengthOptional(boolean pContentLengthOptional) Sets, whether a "Content-Length" header may be omitted. The XML-RPC specification demands, that such a header be present.- Parameters:
pContentLengthOptional- True, if the content length may be omitted.
-
getTimeZone
Description copied from interface:XmlRpcConfigReturns the timezone, which is used to interpret date/time values. Defaults toTimeZone.getDefault().- Specified by:
getTimeZonein interfaceXmlRpcConfig
-
setTimeZone
Returns the timezone, which is used to interpret date/time values. Defaults toTimeZone.getDefault().
-