Package org.pdf4j.saxon.om

Examples of org.pdf4j.saxon.om.AttributeCollection


        return true;
    }

    public QName getAttributeName(int i) {
        try {
            AttributeCollection atts = provider.getAttributes();
            return new QName(atts.getURI(i), atts.getLocalName(i), atts.getPrefix(i));
        } catch (XPathException e) {
            pendingException = e;
            return new QName("http://saxon.sf.net/error", "error", "");
        }
    }
View Full Code Here


        }
    }

    public String getAttributeType(int i) {
        try {
            AttributeCollection ac = provider.getAttributes();
            if (ac.isId(i)) {
                return "ID";
            } else if (ac.isIdref(i)) {
                return "IDREFS";
            } else {
                return "CDATA";
            }
        } catch (XPathException e) {
View Full Code Here

    public void prepareAttributes() throws XPathException {

        String selectAtt = null;

    AttributeCollection atts = getAttributeList();
    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
      String f = getNamePool().getClarkName(nc);
      if (f==StandardNames.SELECT) {
            selectAtt = atts.getValue(a);
          } else {
            checkUnknownAttribute(nc);
          }
        }
View Full Code Here

        return getCommonChildItemType();
    }


    public void prepareAttributes() throws XPathException {
    AttributeCollection atts = getAttributeList();
    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
          checkUnknownAttribute(nc);
        }
    }
View Full Code Here

        return true;
    }

    public void prepareAttributes() throws XPathException {

    AttributeCollection atts = getAttributeList();

    String selectAtt = null;
    String groupByAtt = null;
    String groupAdjacentAtt = null;
    String startingAtt = null;
    String endingAtt = null;
        String collationAtt = null;

    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
      String f = getNamePool().getClarkName(nc);
            if (f.equals(StandardNames.SELECT)) {
            selectAtt = atts.getValue(a);
          } else if (f.equals(StandardNames.GROUP_BY)) {
            groupByAtt = atts.getValue(a);
          } else if (f.equals(StandardNames.GROUP_ADJACENT)) {
            groupAdjacentAtt = atts.getValue(a);
          } else if (f.equals(StandardNames.GROUP_STARTING_WITH)) {
            startingAtt = atts.getValue(a);
          } else if (f.equals(StandardNames.GROUP_ENDING_WITH)) {
            endingAtt = atts.getValue(a);
          } else if (f.equals(StandardNames.COLLATION)) {
            collationAtt = Whitespace.trim(atts.getValue(a));
          } else {
            checkUnknownAttribute(nc);
          }
        }
View Full Code Here

    public boolean mayContainSequenceConstructor() {
        return true;
    }

    public void prepareAttributes() throws XPathException {
    AttributeCollection atts = getAttributeList();
    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
          checkUnknownAttribute(nc);
        }
    }
View Full Code Here

    public void prepareAttributes() throws XPathException {

        String testAtt=null;

    AttributeCollection atts = getAttributeList();

    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
      String f = getNamePool().getClarkName(nc);
      if (f==StandardNames.TEST) {
            testAtt = atts.getValue(a);
          } else {
            checkUnknownAttribute(nc);
          }
        }
View Full Code Here

    protected ItemType getReturnedItemType() {
        return getCommonChildItemType();
    }

    public void prepareAttributes() throws XPathException {
    AttributeCollection atts = getAttributeList();
    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
          checkUnknownAttribute(nc);
        }
    }
View Full Code Here

        // the character to be substituted, as a Unicode codepoint (may be > 65535)
    private String replacementString = null;

    public void prepareAttributes() throws XPathException {

    AttributeCollection atts = getAttributeList();

    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
      String f = getNamePool().getClarkName(nc);
      if (f==StandardNames.CHARACTER) {
                String s = atts.getValue(a);
                switch (s.length()) {
                    case 0:
                        compileError("character attribute must not be zero-length", "XTSE0020");
                        codepoint = 256; // for error recovery
                        break;
                    case 1:
                        codepoint = s.charAt(0);
                        break;
                    case 2:
                        if (UTF16.isHighSurrogate(s.charAt(0)) &&
                                UTF16.isLowSurrogate(s.charAt(1))) {
                            codepoint = UTF16.combinePair(s.charAt(0), s.charAt(1));
                        } else {
                            compileError("character attribute must be a single XML character", "XTSE0020");
                            codepoint = 256; // for error recovery
                        }
                        break;
                    default:
                        compileError("character attribute must be a single XML character", "XTSE0020");
                        codepoint = 256; // for error recovery
                }
          } else if (f==StandardNames.STRING) {
            replacementString = atts.getValue(a);
          } else {
            checkUnknownAttribute(nc);
          }
        }
        if (codepoint==-1) {
View Full Code Here

    public boolean mayContainSequenceConstructor() {
        return true;
    }

    public void prepareAttributes() throws XPathException {
    AttributeCollection atts = getAttributeList();
    for (int a=0; a<atts.getLength(); a++) {
      int nc = atts.getNameCode(a);
          checkUnknownAttribute(nc);
        }
    }
View Full Code Here

TOP

Related Classes of org.pdf4j.saxon.om.AttributeCollection

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.