org.apache.synapse.mediators.elementary
Class Target

java.lang.Object
  extended by org.apache.synapse.mediators.elementary.Target

public class Target
extends Object

Inset an Axiom element to the current message. The target to insert the OMElement can be 1. A property 2. SOAP Body child element 3. SOAP envelope 4. A XPath expression to get the correct node

In case the target is an SOAP Envelope, the current SOAP envelope will be replaced by the OMNode. So the OMNode must me a SOAPEnvelope.

In case of Body the first child of the Body will be replaced by the new Node or a sibling will be added to it depending on the replace property.

In case of Expression a SOAP Element will be chosen based on the XPath. If replace is true that element will be replaced, otherwise a sibling will be added to that element.

Property case is simple. The OMNode will be stored in the given property


Field Summary
static String ACTION_ADD_CHILD
           
static String ACTION_ADD_SIBLING
           
static String ACTION_REPLACE
           
 
Constructor Summary
Target()
           
 
Method Summary
 String getAction()
           
 String getProperty()
           
 int getTargetType()
           
 SynapseXPath getXpath()
           
 void insert(MessageContext synContext, ArrayList<OMNode> sourceNodeList, SynapseLog synLog)
           
 void setAction(String action)
           
 void setProperty(String property)
           
 void setTargetType(int targetType)
           
 void setXpath(SynapseXPath xpath)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ACTION_REPLACE

public static final String ACTION_REPLACE
See Also:
Constant Field Values

ACTION_ADD_CHILD

public static final String ACTION_ADD_CHILD
See Also:
Constant Field Values

ACTION_ADD_SIBLING

public static final String ACTION_ADD_SIBLING
See Also:
Constant Field Values
Constructor Detail

Target

public Target()
Method Detail

insert

public void insert(MessageContext synContext,
                   ArrayList<OMNode> sourceNodeList,
                   SynapseLog synLog)
            throws JaxenException
Throws:
JaxenException

getXpath

public SynapseXPath getXpath()

getProperty

public String getProperty()

getTargetType

public int getTargetType()

setXpath

public void setXpath(SynapseXPath xpath)

setProperty

public void setProperty(String property)

setTargetType

public void setTargetType(int targetType)

getAction

public String getAction()

setAction

public void setAction(String action)


Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.