Examples of addXPathNamespace()


Examples of org.apache.synapse.processors.rules.XPathProcessor.addXPathNamespace()

    public void testXpathProcessor() throws Exception {
        SynapseMessage sm = new Axis2SynapseMessage(
                Axis2EnvSetup.axis2Deployment("target/synapse-repository"));
        XPathProcessor pro = new XPathProcessor();
        pro.setXPathExpr("//ns:text");
        pro.addXPathNamespace("ns", "urn:text-body");
        boolean result = pro.process(null, sm);
        assertTrue(result);

    }
}
View Full Code Here

Examples of org.apache.synapse.processors.rules.XPathProcessor.addXPathNamespace()

    xp.setXPathExpr(expr.getAttributeValue());
    Iterator it = el.getAllDeclaredNamespaces();
    while (it.hasNext()) {
      OMNamespace n = (OMNamespace) it.next();
      xp.addXPathNamespace(n.getPrefix(), n.getName());
    }

    return xp;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.