Package org.exist.util.serializer

Examples of org.exist.util.serializer.AttrList.addAttribute()


                throw new SAXException(e.getMessage(), e);
            }
           
            setXSLHandler(null, false);
            final AttrList attrs = new AttrList();
            attrs.addAttribute(ATTR_HITS_QNAME, "1");
            attrs.addAttribute(ATTR_START_QNAME, "1");
            attrs.addAttribute(ATTR_COUNT_QNAME, "1");
            if (outputProperties.getProperty(PROPERTY_SESSION_ID) != null) {
                attrs.addAttribute(ATTR_SESSION_ID, outputProperties.getProperty(PROPERTY_SESSION_ID));
            }
View Full Code Here


            }
           
            setXSLHandler(null, false);
            final AttrList attrs = new AttrList();
            attrs.addAttribute(ATTR_HITS_QNAME, "1");
            attrs.addAttribute(ATTR_START_QNAME, "1");
            attrs.addAttribute(ATTR_COUNT_QNAME, "1");
            if (outputProperties.getProperty(PROPERTY_SESSION_ID) != null) {
                attrs.addAttribute(ATTR_SESSION_ID, outputProperties.getProperty(PROPERTY_SESSION_ID));
            }
   
View Full Code Here

           
            setXSLHandler(null, false);
            final AttrList attrs = new AttrList();
            attrs.addAttribute(ATTR_HITS_QNAME, "1");
            attrs.addAttribute(ATTR_START_QNAME, "1");
            attrs.addAttribute(ATTR_COUNT_QNAME, "1");
            if (outputProperties.getProperty(PROPERTY_SESSION_ID) != null) {
                attrs.addAttribute(ATTR_SESSION_ID, outputProperties.getProperty(PROPERTY_SESSION_ID));
            }
   
            receiver.startDocument();
View Full Code Here

            final AttrList attrs = new AttrList();
            attrs.addAttribute(ATTR_HITS_QNAME, "1");
            attrs.addAttribute(ATTR_START_QNAME, "1");
            attrs.addAttribute(ATTR_COUNT_QNAME, "1");
            if (outputProperties.getProperty(PROPERTY_SESSION_ID) != null) {
                attrs.addAttribute(ATTR_SESSION_ID, outputProperties.getProperty(PROPERTY_SESSION_ID));
            }
   
            receiver.startDocument();
           
            if(wrap) {
View Full Code Here

                final String baseUri = item.getOwnerDocument().getBaseURI();

                attrs = new AttrList();
                if(baseUri != null && baseUri.length() > 0){
                    attrs.addAttribute(ATTR_URI_QNAME, baseUri);
                }
                if(item.getOwnerDocument().getDocumentElement() == null) {
                    attrs.addAttribute(ATTR_HAS_ELEMENT_QNAME, "false");
                }
View Full Code Here

                attrs = new AttrList();
                if(baseUri != null && baseUri.length() > 0){
                    attrs.addAttribute(ATTR_URI_QNAME, baseUri);
                }
                if(item.getOwnerDocument().getDocumentElement() == null) {
                    attrs.addAttribute(ATTR_HAS_ELEMENT_QNAME, "false");
                }

                receiver.startElement(ELEM_DOC_QNAME, attrs);
                break;
View Full Code Here

            case Type.ATTRIBUTE:
                attrs = new AttrList();

                String attributeValue;
                if((attributeValue = item.getNode().getLocalName()) != null && attributeValue.length() > 0){
                    attrs.addAttribute(ATTR_LOCAL_QNAME, attributeValue);
                }
                if((attributeValue = item.getNode().getNamespaceURI()) != null && attributeValue.length() > 0) {
                    attrs.addAttribute(ATTR_TNS_QNAME, attributeValue);
                }
                if((attributeValue = item.getNode().getPrefix()) != null && attributeValue.length() > 0) {
View Full Code Here

                String attributeValue;
                if((attributeValue = item.getNode().getLocalName()) != null && attributeValue.length() > 0){
                    attrs.addAttribute(ATTR_LOCAL_QNAME, attributeValue);
                }
                if((attributeValue = item.getNode().getNamespaceURI()) != null && attributeValue.length() > 0) {
                    attrs.addAttribute(ATTR_TNS_QNAME, attributeValue);
                }
                if((attributeValue = item.getNode().getPrefix()) != null && attributeValue.length() > 0) {
                    attrs.addAttribute(ATTR_PREFIX_QNAME, attributeValue);
                }
View Full Code Here

                }
                if((attributeValue = item.getNode().getNamespaceURI()) != null && attributeValue.length() > 0) {
                    attrs.addAttribute(ATTR_TNS_QNAME, attributeValue);
                }
                if((attributeValue = item.getNode().getPrefix()) != null && attributeValue.length() > 0) {
                    attrs.addAttribute(ATTR_PREFIX_QNAME, attributeValue);
                }

                receiver.startElement(ELEM_ATTR_QNAME, attrs);
                break;
View Full Code Here

          final String ns = defaultNS == null ? node.getNamespaceURI() : defaultNS;
          if (ns.length() > 0 && (!namespaces.contains(ns)))
            {receiver.startPrefixMapping(node.getPrefix(), ns);}
          final AttrList attribs = new AttrList();
          if ((first && showId == EXIST_ID_ELEMENT) || showId == EXIST_ID_ALL) {
                attribs.addAttribute(ID_ATTRIB, node.getNodeId().toString());
            /*
             * This is a proposed fix-up that the serializer could do
             * to make sure elements always have the namespace declarations
             *
            } else {
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.