Package org.exist.xquery

Examples of org.exist.xquery.XPathException


        return Integer.MAX_VALUE;
    }

    @Override
    public boolean effectiveBooleanValue() throws XPathException {
        throw new XPathException("FORG0006: value of type " + Type.getTypeName(getType()) + " has no boolean value.");
    }
View Full Code Here


        final ByteArrayOutputStream baos = new ByteArrayOutputStream();

        try {
            streamTo(baos);
        } catch(final IOException ex) {
            throw new XPathException("Unable to encode string value: " + ex.getMessage(), ex);
        } finally {
            try {
                baos.close();   //close the stream to ensure all data is flushed
            } catch(final IOException ioe) {
                LOG.error("Unable to close stream: " + ioe.getMessage(), ioe);
View Full Code Here

            {return true;}
        if (hasMany()) {
            if (OLD_EXIST_VERSION_COMPATIBILITY)   
                {return true;}
            else
                {throw new XPathException(
                    "err:FORG0006: effectiveBooleanValue: first item of '" +
                    (toString().length() < 20 ? toString() : toString().substring(0, 20)+ "...") +
                    "' is not a node, and sequence length > 1");}
        }
        //From now, we'll work with singletons...
View Full Code Here

    }

    @Override
    public void verifyString(String str) throws XPathException {
        if(!getMatcher(str).matches()) {
            throw new XPathException("FORG0001: Invalid base64 data");
        }
    }
View Full Code Here

   * @see org.exist.xquery.value.Sequence#convertTo(int)
   */
  public AtomicValue convertTo(int requiredType) throws XPathException {
    if (requiredType == Type.JAVA_OBJECT)
      {return this;}
    throw new XPathException(
      "cannot convert Java object to " + Type.getTypeName(requiredType));
  }
View Full Code Here

    throw new XPathException(
      "cannot convert Java object to " + Type.getTypeName(requiredType));
  }
 
  public boolean effectiveBooleanValue() throws XPathException {
    throw new XPathException("Called effectiveBooleanValue() on JavaObjectValue");
  }
View Full Code Here

  /* (non-Javadoc)
   * @see org.exist.xquery.value.AtomicValue#compareTo(int, org.exist.xquery.value.AtomicValue)
   */
  public boolean compareTo(Collator collator, int operator, AtomicValue other) throws XPathException {
    throw new XPathException(
      "cannot compare Java object to " + Type.getTypeName(other.getType()));
  }
View Full Code Here

  /* (non-Javadoc)
   * @see org.exist.xquery.value.AtomicValue#compareTo(org.exist.xquery.value.AtomicValue)
   */
  public int compareTo(Collator collator, AtomicValue other) throws XPathException {
    throw new XPathException(
      "cannot compare Java object to " + Type.getTypeName(other.getType()));
  }
View Full Code Here

  /* (non-Javadoc)
   * @see org.exist.xquery.value.AtomicValue#max(org.exist.xquery.value.AtomicValue)
   */
  public AtomicValue max(Collator collator, AtomicValue other) throws XPathException {
    throw new XPathException("Invalid argument to aggregate function: cannot compare Java objects");
  }
View Full Code Here

  public AtomicValue max(Collator collator, AtomicValue other) throws XPathException {
    throw new XPathException("Invalid argument to aggregate function: cannot compare Java objects");
  }

  public AtomicValue min(Collator collator, AtomicValue other) throws XPathException {
    throw new XPathException("Invalid argument to aggregate function: cannot compare Java objects");
  }
View Full Code Here

TOP

Related Classes of org.exist.xquery.XPathException

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.