org.apache.axis2.format
Class PlainTextBuilder
java.lang.Object
org.apache.axis2.format.PlainTextBuilder
- All Implemented Interfaces:
- org.apache.axis2.builder.Builder, DataSourceMessageBuilder, TextMessageBuilder
public class PlainTextBuilder
- extends java.lang.Object
- implements TextMessageBuilder, DataSourceMessageBuilder
Message builder for plain text payloads.
This builder processes the input message as plain text and wraps
the text in a wrapper element. The name of the wrapper element can
be configured as a service parameter (see BaseConstants.WRAPPER_PARAM
).
It defaults to BaseConstants.DEFAULT_TEXT_WRAPPER
.
If the content is provided as an InputStream
and the content type specifies a
charset parameter (e.g. text/plain; charset=ISO-8859-15),
this information is used to decode the text.
If the content is provided as an InputStream
but no charset parameter
is specified on the content type, the default charset encoding specified by
MessageContext.DEFAULT_CHAR_SET_ENCODING
is used.
Method Summary |
org.apache.axiom.om.OMElement |
processDocument(javax.activation.DataSource dataSource,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
|
org.apache.axiom.om.OMElement |
processDocument(java.io.InputStream inputStream,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
|
org.apache.axiom.om.OMElement |
processDocument(java.io.Reader reader,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
|
org.apache.axiom.om.OMElement |
processDocument(java.lang.String content,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PlainTextBuilder
public PlainTextBuilder()
processDocument
public org.apache.axiom.om.OMElement processDocument(java.io.InputStream inputStream,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
throws org.apache.axis2.AxisFault
- Specified by:
processDocument
in interface org.apache.axis2.builder.Builder
- Throws:
org.apache.axis2.AxisFault
processDocument
public org.apache.axiom.om.OMElement processDocument(java.io.Reader reader,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
throws org.apache.axis2.AxisFault
- Specified by:
processDocument
in interface TextMessageBuilder
- Throws:
org.apache.axis2.AxisFault
processDocument
public org.apache.axiom.om.OMElement processDocument(java.lang.String content,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
throws org.apache.axis2.AxisFault
- Specified by:
processDocument
in interface TextMessageBuilder
- Throws:
org.apache.axis2.AxisFault
processDocument
public org.apache.axiom.om.OMElement processDocument(javax.activation.DataSource dataSource,
java.lang.String contentType,
org.apache.axis2.context.MessageContext msgContext)
throws org.apache.axis2.AxisFault
- Specified by:
processDocument
in interface DataSourceMessageBuilder
- Throws:
org.apache.axis2.AxisFault
Copyright © 2004-2009 The Apache Software Foundation. All Rights Reserved.