Package org.xml.sax

Examples of org.xml.sax.SAXNotSupportedException


            //   controls the use of java.lang.String#intern() for strings
            //   passed to SAX handlers.
            //
            if (feature.equals(Constants.STRING_INTERNING_FEATURE)) {
                if (state) {
                    throw new SAXNotSupportedException(
                        "PAR018 " + state + " state for feature \"" + featureId
                        + "\" is not supported.\n" + state + '\t' + featureId);
                }
                return;
            }
View Full Code Here


            if (property.equals(Constants.LEXICAL_HANDLER_PROPERTY)) {
                try {
                    setLexicalHandler((LexicalHandler)value);
                }
                catch (ClassCastException e) {
                    throw new SAXNotSupportedException(
                    "PAR012 For propertyID \""
                    +propertyId+"\", the value \""
                    +value+"\" cannot be cast to LexicalHandler."
                    +'\n'+propertyId+'\t'+value+"\tLexicalHandler");
                }
                return;
            }
            //
            // http://xml.org/sax/properties/declaration-handler
            // Value type: org.xml.sax.ext.DeclHandler
            // Access: read/write, pre-parse only
            //   Set the DTD declaration event handler.
            //
            if (property.equals(Constants.DECLARATION_HANDLER_PROPERTY)) {
                try {
                    setDeclHandler((DeclHandler)value);
                }
                catch (ClassCastException e) {
                    throw new SAXNotSupportedException(
                    "PAR012 For propertyID \""
                    +propertyId+"\", the value \""
                    +value+"\" cannot be cast to DeclHandler."
                    +'\n'+propertyId+'\t'+value+"\tDeclHandler"
                    );
                }
                return;
            }
            //
            // http://xml.org/sax/properties/dom-node
            // Value type: DOM Node
            // Access: read-only
            //   Get the DOM node currently being visited, if the SAX parser is
            //   iterating over a DOM tree.  If the parser recognises and
            //   supports this property but is not currently visiting a DOM
            //   node, it should return null (this is a good way to check for
            //   availability before the parse begins).
            //
            if (property.equals(Constants.DOM_NODE_PROPERTY)) {
                throw new SAXNotSupportedException(
                    "PAR013 Property \""+propertyId+"\" is read only."
                    +'\n'+propertyId
                    ); // read-only property
            }
            //
View Full Code Here

            //   supports this property but is not currently visiting a DOM
            //   node, it should return null (this is a good way to check for
            //   availability before the parse begins).
            //
            if (property.equals(Constants.DOM_NODE_PROPERTY)) {
                throw new SAXNotSupportedException(
                "PAR014 Cannot getProperty(\""+propertyId
                +"\". No DOM Tree exists.\n"+propertyId
                ); // we are not iterating a DOM tree
            }
            //
View Full Code Here

            //
            if (property.equals(Constants.XML_STRING_PROPERTY)) {
                // REVISIT - we should probably ask xml-dev for a precise
                // definition of what this is actually supposed to return, and
                // in exactly which circumstances.
                throw new SAXNotSupportedException(propertyId);
            }
        }

        //
        // Xerces Properties
View Full Code Here

                }
            }

            if (elemname.equals(JMSBridgeXMLConstant.Element.JMSBRIDGE)) {
                if (_jmsbridge != null) {
                    throw new SAXNotSupportedException(
                    "Multiple "+JMSBridgeXMLConstant.Element.JMSBRIDGE+
                    " element is not allowed");
                }
                _logger.log(Level.FINE, "jmsbridge: name="+name);
                _jmsbridge = new JMSBridgeElement();
View Full Code Here

    XPathContext xctxt = null;
    if (myContext instanceof XPathContext.XPathExpressionContext)
      xctxt = ((XPathContext.XPathExpressionContext) myContext).getXPathContext();
    else
      throw new SAXNotSupportedException(XSLMessages.createMessage(XSLTErrorResources.ER_INVALID_CONTEXT_PASSED, new Object[]{myContext }));

    if (expr == null || expr.length() == 0)
      return Double.NaN;
     
    NodeSetDTM contextNodes = new NodeSetDTM(nl, xctxt);
View Full Code Here

   
    XPathContext xctxt = null;
    if (myContext instanceof XPathContext.XPathExpressionContext)
      xctxt = ((XPathContext.XPathExpressionContext) myContext).getXPathContext();
    else
      throw new SAXNotSupportedException(XSLMessages.createMessage(XSLTErrorResources.ER_INVALID_CONTEXT_PASSED, new Object[]{myContext }));

    if (expr == null || expr.length() == 0)
      return Double.NaN;
     
    NodeSetDTM contextNodes = new NodeSetDTM(nl, xctxt);
View Full Code Here

  {
    XPathContext xctxt = null;
    if (myContext instanceof XPathContext.XPathExpressionContext)
      xctxt = ((XPathContext.XPathExpressionContext) myContext).getXPathContext();
    else
      throw new SAXNotSupportedException(XSLMessages.createMessage(XSLTErrorResources.ER_INVALID_CONTEXT_PASSED, new Object[]{myContext }));

    if (expr == null || expr.length() == 0)
      return Double.NaN;
     
    NodeSetDTM contextNodes = new NodeSetDTM(nl, xctxt);
View Full Code Here

    Document lDoc = null;
   
    if (myContext instanceof XPathContext.XPathExpressionContext)
      xctxt = ((XPathContext.XPathExpressionContext) myContext).getXPathContext();
    else
      throw new SAXNotSupportedException(XSLMessages.createMessage(XSLTErrorResources.ER_INVALID_CONTEXT_PASSED, new Object[]{myContext }));

    if (expr == null || expr.length() == 0)
      return new NodeSet();
     
    NodeSetDTM contextNodes = new NodeSetDTM(nl, xctxt);
View Full Code Here

      {
        return new XNodeSet(xctxt.getDTMManager());
      }
    }
    else
      throw new SAXNotSupportedException(XSLMessages.createMessage(XSLTErrorResources.ER_INVALID_CONTEXT_PASSED, new Object[]{myContext })); //"Invalid context passed to evaluate "
  }
View Full Code Here

TOP

Related Classes of org.xml.sax.SAXNotSupportedException

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.