Examples of XPathNamespaceContext


Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

  public static IntegrationTestGroup fromXml(Node config)
      throws IllegalStateException {
    XPath xpath = XPathFactory.newInstance().newXPath();

    // Define the xml namespace
    XPathNamespaceContext nsCtx = new XPathNamespaceContext(false);
    nsCtx.defineNamespaceURI("m", TEST_XMLNS);
    xpath.setNamespaceContext(nsCtx);

    return fromXml(config, xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

   * @see #fromXml(Node, XPath)
   * @see #toXml()
   */
  public static ImageStyleImpl fromXml(Node node) throws IllegalStateException {
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    return fromXml(node, xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

   */
  public static Module fromXml(Node config) throws IllegalStateException {
    XPath xpath = XPathFactory.newInstance().newXPath();

    // Define the xml namespace
    XPathNamespaceContext nsCtx = new XPathNamespaceContext(false);
    nsCtx.defineNamespaceURI("m", MODULE_XMLNS);
    xpath.setNamespaceContext(nsCtx);

    return fromXml(config, xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

   */
  public static Site fromXml(Node config) throws IllegalStateException {
    XPath xpath = XPathFactory.newInstance().newXPath();

    // Define the xml namespace
    XPathNamespaceContext nsCtx = new XPathNamespaceContext(false);
    nsCtx.defineNamespaceURI("ns", SITE_XMLNS);
    xpath.setNamespaceContext(nsCtx);

    return fromXml(config, xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    logger.info("Registering weblounge ui imagestyles");

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));

    // Load the style definitions from disk
    URL stylesDefinition = this.getClass().getResource(STYLES_DEFINITION_FILE);
    Document doc = docBuilder.parse(stylesDefinition.openStream());
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    URL testContext = this.getClass().getResource(testFile);
    Document doc = docBuilder.parse(testContext.openStream());
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    action = ActionSupport.fromXml(doc.getFirstChild(), xpath);
    action.setSite(site);
    action.setModule(module);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    URL testContext = this.getClass().getResource(testFile);
    Document doc = docBuilder.parse(testContext.openStream());
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    setUpPrerequisites();
    user = WebloungeUserImpl.fromXml(doc.getFirstChild(), mockSite, xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    URL testContext = this.getClass().getResource(testFile);
    Document doc = docBuilder.parse(testContext.openStream());
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    quartzJob = (QuartzJob)QuartzJob.fromXml(doc.getFirstChild(), xpath);
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    URL testContext = this.getClass().getResource(testFile);
    Document doc = docBuilder.parse(testContext.openStream());
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    template = PageTemplateImpl.fromXml(doc.getFirstChild(), xpath);
    composeable = (PageTemplateImpl)template;
  }
View Full Code Here

Examples of ch.entwine.weblounge.common.impl.util.xml.XPathNamespaceContext

    DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
    DocumentBuilder docBuilder = docBuilderFactory.newDocumentBuilder();
    URL testContext = this.getClass().getResource(testFile);
    Document doc = docBuilder.parse(testContext.openStream());
    XPath xpath = XPathFactory.newInstance().newXPath();
    xpath.setNamespaceContext(new XPathNamespaceContext(true));
    user = UserImpl.fromXml(doc.getFirstChild(), xpath);
  }
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.