Package org.exist.dom

Examples of org.exist.dom.ElementAtExist


  }
 
  public void compileNode(ContextAtExist context, XSLPathExpr content, Node node) throws XPathException {
    //namespaces
    if (node instanceof ElementAtExist) {
      ElementAtExist elementAtExist = (ElementAtExist) node;
      Map<String, String> namespaceMap = elementAtExist.getNamespaceMap();
          for (String name : namespaceMap.keySet()) {
            //getContext().declareInScopeNamespace(name, namespaceMap.get(name));
            context.declareNamespace(name, namespaceMap.get(name));
            //TODO: rewrite, changes at xquery.parser. it use static
          }
View Full Code Here


   * @see javax.xml.transform.sax.TemplatesHandler#getTemplates()
   */
  public Templates getTemplates() {
    if (templates == null) {
          Document doc = getDocument();
          ElementAtExist xsl = (ElementAtExist) doc.getDocumentElement();

          try {
        templates = XSL.compile(xsl);
      } catch (XPathException e) {
        LOG.debug(e);
View Full Code Here

       
        if (document == null) {
            return null; //possibly on corrupted database, find better solution (recovery flag?)
        }
       
        final ElementAtExist confElement = (ElementAtExist) document.getDocumentElement();
        if (confElement == null) {
            return null; //possibly on corrupted database, find better solution (recovery flag?)
        }
       
        conf = new ConfigurationImpl(confElement);
View Full Code Here

        conf = hotConfigs.get(key);
        if (conf != null) {
            return conf;
        }
       
        final ElementAtExist confElement = (ElementAtExist) document.getDocumentElement();
        if (confElement == null) {
            return null; //possibly on corrupted database, find better solution (recovery flag?)
        }
        conf = new ConfigurationImpl(confElement);
       
View Full Code Here

        Node child = getFirstChild();
        while (child != null) {
           
            if (child.getNodeType() == Node.ELEMENT_NODE) {

                final ElementAtExist el = (ElementAtExist) child;
               
                if (name.equals( el.getLocalName() ) && NS.equals( el.getNamespaceURI() )) {
                   
                    final Configuration config = new ConfigurationImpl(el);
                    list.add(config);
               
                }
View Full Code Here

        Node child = getFirstChild();
        while (child != null) {
           
            if (child.getNodeType() == Node.ELEMENT_NODE) {

                final ElementAtExist el = (ElementAtExist) child;
               
                if (name.equals( el.getLocalName() ) && NS.equals( el.getNamespaceURI() )) {
                   
                    if(!el.hasAttributes()){
                        continue;
                    }
                   
                    final NamedNodeMap attrs = el.getAttributes();
                    if (attrs.getLength() != 1) {
                        continue;
                    }
                   
                    Node attr = attrs.getNamedItem("key");
                   
                    if (attr == null)
                        continue;
                   
                    final String key = attr.getNodeValue();
                    final String value = el.getNodeValue();
                   
                    if(key == null || key.isEmpty() || value == null || value.isEmpty()){
                        ; //skip
                    } else {
                        map.put(key, value);
View Full Code Here

TOP

Related Classes of org.exist.dom.ElementAtExist

Copyright © 2018 www.massapicom. 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.