| org.apache.axis2.jaxws.message.XMLPart
All known Subclasses: org.apache.axis2.jaxws.message.impl.XMLPartBase,
XMLPart | public interface XMLPart (Code) | | author: scheu |
Method Summary | |
public OMElement | getAsOMElement() | public SOAPEnvelope | getAsSOAPEnvelope() | public Block | getBodyBlock(int index, Object context, BlockFactory blockFactory) getBodyBlock Get the body block at the specificed index. | public Block | getBodyBlock(Object context, BlockFactory blockFactory) getBodyBlock Get the single Body Block. | public Block | getHeaderBlock(String namespace, String localPart, Object context, BlockFactory blockFactory) getHeaderBlock Get the header block with the specified name The BlockFactory and object context
are passed in to help create the proper kind of block. | public int | getIndirection() Get indirection. | public int | getNumBodyBlocks() getNumBodyBlocks Calling this method will cache the OM. | public int | getNumHeaderBlocks() | public QName | getOperationElement() the QName of the operation element if Style.rpc. | public Message | getParent() getParent Get the Message object that this XMLPart is attached to, if it is attached to one
at all. | public Protocol | getProtocol() | public Style | getStyle() | public XMLFault | getXMLFault() | public String | getXMLPartContentType() The representation of the XMLPart may be in a number of different forms. | public XMLStreamReader | getXMLStreamReader(boolean consume) | public boolean | isConsumed() isConsumed Return true if the part is consumed. | public boolean | isFault() | public void | outputTo(XMLStreamWriter writer, boolean consume) | public void | removeBodyBlock(int index) | public void | removeHeaderBlock(String namespace, String localPart) | public void | setBodyBlock(int index, Block block) setBodyBlock Set the block at the specified index Once set, the Message owns the block. | public void | setBodyBlock(Block block) setBodyBlock Set this as block as the single block for the message. | public void | setHeaderBlock(String namespace, String localPart, Block block) appendHeaderBlock Append the block to the list of header blocks. | public void | setIndirection(int indirection) Set indirection. | public void | setOperationElement(QName operationQName) Set the operation element qname. | public void | setParent(Message m) | public void | setStyle(Style style) Set the Style. | public void | setXMLFault(XMLFault xmlFault) | public String | traceString(String indent) Get a traceString...the trace string dumps the contents of the Block without forcing an
underlying ill-performant transformation of the message. |
getAsOMElement | public OMElement getAsOMElement() throws WebServiceException(Code) | | getAsOMElement Get the xml part as a read/write OM...note this returns an OM SOAPEnvelope for
all protocols...even REST
OMElement throws: WebServiceException - |
getBodyBlock | public Block getBodyBlock(int index, Object context, BlockFactory blockFactory) throws WebServiceException(Code) | | getBodyBlock Get the body block at the specificed index. The BlockFactory and object context are
passed in to help create the proper kind of block. Calling this method will cache the OM. Avoid
it in performant situations.
Parameters: index - Parameters: context - Parameters: blockFactory - Block or null throws: WebServiceException - See Also: getBodyBlock |
getBodyBlock | public Block getBodyBlock(Object context, BlockFactory blockFactory) throws WebServiceException(Code) | | getBodyBlock Get the single Body Block. The BlockFactory and object context are passed in to
help create the proper kind of block. This method should only be invoked when it is known
that there is zero or one block.
Parameters: index - Parameters: context - Parameters: blockFactory - Block or null throws: WebServiceException - |
getHeaderBlock | public Block getHeaderBlock(String namespace, String localPart, Object context, BlockFactory blockFactory) throws WebServiceException(Code) | | getHeaderBlock Get the header block with the specified name The BlockFactory and object context
are passed in to help create the proper kind of block.
Parameters: namespace - Parameters: localPart - Parameters: context - Parameters: blockFactory - Block throws: WebServiceException - |
getIndirection | public int getIndirection()(Code) | | Get indirection. Used to force the code to look for blocks at a particular location. For
DOCUMENT the default is 0 For RPC the default is 1 This method is used to override these
settings for special cases.
indirection (0 or 1) |
getNumBodyBlocks | public int getNumBodyBlocks() throws WebServiceException(Code) | | getNumBodyBlocks Calling this method will cache the OM. Avoid it in performant situations.
number of body blocks throws: WebServiceException - |
getOperationElement | public QName getOperationElement() throws WebServiceException(Code) | | the QName of the operation element if Style.rpc. Otherwise null |
getParent | public Message getParent()(Code) | | getParent Get the Message object that this XMLPart is attached to, if it is attached to one
at all.
|
getProtocol | public Protocol getProtocol()(Code) | | Get the protocol for this Message (soap11, soap12, etc.)
Protocl |
getStyle | public Style getStyle()(Code) | | the Style (document or rpc) |
getXMLFault | public XMLFault getXMLFault() throws WebServiceException(Code) | | If the XMLPart represents a fault, an XMLFault is returned which describes the fault in a
protocol agnostic manner
the XMLFault object or null See Also: XMLFault |
getXMLPartContentType | public String getXMLPartContentType()(Code) | | The representation of the XMLPart may be in a number of different forms. Currently the forms
are UNKNOWN, OM, SOAPENVELOPE, and SPINE. This method returns a String containing one of
these types. This method should only be used for trace and testing purposes. The consumer
of a Message should not make any decisions based on the representation of the XMLPart
String |
isConsumed | public boolean isConsumed()(Code) | | isConsumed Return true if the part is consumed. Once consumed, the information in the part is
no longer available.
true if the block is consumed (a method was called with consume=true) |
isFault | public boolean isFault() throws WebServiceException(Code) | | Determines whether the XMLPart represents a Fault
true if the message represents a fault |
setBodyBlock | public void setBodyBlock(int index, Block block) throws WebServiceException(Code) | | setBodyBlock Set the block at the specified index Once set, the Message owns the block. You
must use the getBodyBlock method to access it.
Parameters: index - Parameters: block - throws: WebServiceException - |
setHeaderBlock | public void setHeaderBlock(String namespace, String localPart, Block block) throws WebServiceException(Code) | | appendHeaderBlock Append the block to the list of header blocks. The Message owns the block.
You must use the getHeaderBlock method to access it.
Parameters: namespace - Parameters: localPart - Parameters: block - throws: WebServiceException - |
setIndirection | public void setIndirection(int indirection)(Code) | | Set indirection. Used to force the code to look for blocks at a particular location. For
DOCUMENT the default is 0 For RPC the default is 1 This method is used to override these
settings for special cases.
Parameters: indirection - (0 or 1) |
setOperationElement | public void setOperationElement(QName operationQName) throws WebServiceException(Code) | | Set the operation element qname. The operation qname is only used if Style.rpc
Parameters: operationQName - |
setParent | public void setParent(Message m)(Code) | | setParent Set the Message object that will hold this XMLPart
Parameters: m - |
setStyle | public void setStyle(Style style) throws WebServiceException(Code) | | Set the Style. If the style is DOCUMENT, the body blocks are located underneath the body
element. If the style is set to RPC, then the body blocks are located underneath the rpc
operation.
Parameters: style - Style See Also: set See Also: indirection |
traceString | public String traceString(String indent)(Code) | | Get a traceString...the trace string dumps the contents of the Block without forcing an
underlying ill-performant transformation of the message.
String containing trace information |
|
|