org.apache.axis2.scripting
Class ScriptMessageContext

java.lang.Object
  extended by org.apache.axis2.context.AbstractContext
      extended by org.apache.axis2.context.MessageContext
          extended by org.apache.axis2.scripting.ScriptMessageContext
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable, SafeSerializable

public class ScriptMessageContext
extends MessageContext

ScriptMessageContext decorates the Axis2 MessageContext adding methods to use the message payload XML in a way natural to the scripting language.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.apache.axis2.context.MessageContext
attachments, CHARACTER_SET_ENCODING, currentMessageContext, DEFAULT_CHAR_SET_ENCODING, DISABLE_ASYNC_CALLBACK_ON_TRANSPORT_ERROR, FLOW, IN_FAULT_FLOW, IN_FLOW, options, OUT_FAULT_FLOW, OUT_FLOW, outputWritten, REMOTE_ADDR, TRANSPORT_ADDR, TRANSPORT_HEADERS, TRANSPORT_IN, TRANSPORT_NON_BLOCKING, TRANSPORT_OUT, TRANSPORT_SUCCEED, UTF_16, UTF_8
 
Fields inherited from class org.apache.axis2.context.AbstractContext
COPY_PROPERTIES, lastTouchedTime, parent, properties
 
Constructor Summary
ScriptMessageContext(MessageContext mc, OMElementConvertor convertor)
           
 
Method Summary
 java.lang.Object getEnvelopeXML()
          Get the XML representation of the complete SOAP envelope
 java.lang.Object getPayloadXML()
          Get the XML representation of SOAP Body payload.
 void setFaultTo(java.lang.String reference)
           
 void setFrom(java.lang.String reference)
           
 void setPayloadXML(java.lang.Object payload)
          Set the SOAP body payload from XML
 void setReplyTo(java.lang.String reference)
           
 void setTo(java.lang.String reference)
           
 
Methods inherited from class org.apache.axis2.context.MessageContext
activate, activateWithOperationContext, addAttachment, addAttachment, addExecutedPhase, addRelatesTo, containsSelfManagedDataKey, extractCopyMessageContext, getAttachment, getAttachmentMap, getAxisMessage, getAxisOperation, getAxisService, getAxisServiceGroup, getConfigurationContext, getCurrentHandlerIndex, getCurrentMessageContext, getCurrentPhaseIndex, getEffectivePolicy, getEnvelope, getExecutedPhases, getExecutionChain, getFailureReason, getFaultTo, getFLOW, getFrom, getIncomingTransportName, getLocalProperty, getLocalProperty, getLogCorrelationID, getLogIDString, getMessageID, getModuleParameter, getOperationContext, getOptions, getParameter, getProperties, getProperty, getRelatesTo, getRelatesTo, getRelationships, getReplyTo, getRootContext, getSelfManagedData, getServiceContext, getServiceContextID, getServiceGroupContext, getServiceGroupContextId, getSessionContext, getSoapAction, getTo, getTransportIn, getTransportOut, getWSAAction, isDoingMTOM, isDoingREST, isDoingSwA, isEngaged, isFault, isHeaderPresent, isNewThreadRequired, isOutputWritten, isPaused, isProcessingFault, isPropertyTrue, isPropertyTrue, isResponseWritten, isServerSide, isSOAP11, pause, readExternal, removeAttachment, removeFirstExecutedPhase, removeSelfManagedData, resetExecutedPhases, setAttachmentMap, setAxisMessage, setAxisOperation, setAxisService, setAxisServiceGroup, setConfigurationContext, setCurrentHandlerIndex, setCurrentMessageContext, setCurrentPhaseIndex, setDoingMTOM, setDoingREST, setDoingSwA, setEnvelope, setExecutedPhasesExplicit, setExecutionChain, setFailureReason, setFaultTo, setFLOW, setFrom, setIncomingTransportName, setIsSOAP11Explicit, setMessageID, setNewThreadRequired, setOperationContext, setOptions, setOptionsExplicit, setOutputWritten, setPaused, setProcessingFault, setRelationships, setReplyTo, setResponseWritten, setSelfManagedData, setSelfManagedDataMapExplicit, setServerSide, setServiceContext, setServiceContextID, setServiceGroupContext, setServiceGroupContextId, setSessionContext, setSoapAction, setTo, setTransportIn, setTransportOut, setWSAAction, setWSAMessageId, toString, writeExternal
 
Methods inherited from class org.apache.axis2.context.AbstractContext
clearPropertyDifferences, flush, getLastTouchedTime, getParent, getPropertyDifferences, getPropertyNames, getPropertyNonReplicable, isAncestor, mergeProperties, removeProperty, removePropertyNonReplicable, setLastTouchedTime, setNonReplicableProperty, setParent, setProperties, setProperty, touch
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ScriptMessageContext

public ScriptMessageContext(MessageContext mc,
                            OMElementConvertor convertor)
Method Detail

getPayloadXML

public java.lang.Object getPayloadXML()
Get the XML representation of SOAP Body payload. The payload is the first element inside the SOAP tags

Returns:
the XML SOAP Body

setPayloadXML

public void setPayloadXML(java.lang.Object payload)
Set the SOAP body payload from XML

Parameters:
payload -
Throws:
javax.xml.stream.XMLStreamException

getEnvelopeXML

public java.lang.Object getEnvelopeXML()
Get the XML representation of the complete SOAP envelope


setTo

public void setTo(java.lang.String reference)

setFaultTo

public void setFaultTo(java.lang.String reference)

setFrom

public void setFrom(java.lang.String reference)

setReplyTo

public void setReplyTo(java.lang.String reference)


Copyright © 2007 Apache Web Services Project. All Rights Reserved.