[llvm-commits] [llvm-gcc-4.2] r43913 [32/80] - in /llvm-gcc-4.2/trunk: boehm-gc/ boehm-gc/Mac_files/ boehm-gc/cord/ boehm-gc/doc/ boehm-gc/include/ boehm-gc/include/private/ boehm-gc/tests/ libffi/ libffi/include/ libffi/src/ libffi/src/alpha/ libffi/src/arm/ libffi/src/cris/ libffi/src/frv/ libffi/src/ia64/ libffi/src/m32r/ libffi/src/m68k/ libffi/src/mips/ libffi/src/pa/ libffi/src/powerpc/ libffi/src/s390/ libffi/src/sh/ libffi/src/sh64/ libffi/src/sparc/ libffi/src/x86/ libffi/testsuite/ libffi/testsuite/config/ li...
Bill Wendling
isanbard at gmail.com
Thu Nov 8 14:57:11 PST 2007
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/QNameType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/QNameType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/QNameType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/QNameType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,122 @@
+/* QNameType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.io.IOException;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+import gnu.xml.stream.UnicodeReader;
+import gnu.xml.stream.XMLParser;
+
+/**
+ * The XML Schema QName type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class QNameType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.LENGTH,
+ Facet.MIN_LENGTH,
+ Facet.MAX_LENGTH,
+ Facet.PATTERN,
+ Facet.ENUMERATION,
+ Facet.WHITESPACE
+ };
+
+ QNameType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "QName"),
+ TypeLibrary.ANY_SIMPLE_TYPE);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int ci = -1;
+ try
+ {
+ int[] cp = UnicodeReader.toCodePointArray(value);
+ if (cp.length == 0)
+ throw new DatatypeException("invalid NCName value");
+ // XXX XML 1.1 documents?
+ if (cp[0] == ':' || !XMLParser.isNameStartCharacter(cp[0], false))
+ throw new DatatypeException(0, "invalid NCName value");
+ for (int i = 1; i < cp.length; i++)
+ {
+ if (cp[i] == ':')
+ {
+ if (ci != -1 || (i + 1 == cp.length))
+ throw new DatatypeException(i, "invalid NCName value");
+ ci = i;
+ }
+ else if (!XMLParser.isNameCharacter(cp[i], false))
+ throw new DatatypeException(i, "invalid NCName value");
+ }
+ }
+ catch (IOException e)
+ {
+ DatatypeException e2 = new DatatypeException("invalid NCName value");
+ e2.initCause(e);
+ throw e2;
+ }
+ if (ci != -1)
+ {
+ String prefix = value.substring(0, ci);
+ if (context.resolveNamespacePrefix(prefix) == null)
+ throw new DatatypeException("invalid namespace prefix");
+ }
+ }
+
+ public boolean isContextDependent()
+ {
+ return true;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/ShortType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/ShortType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/ShortType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/ShortType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,133 @@
+/* ShortType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema short type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class ShortType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.TOTAL_DIGITS,
+ Facet.FRACTION_DIGITS,
+ Facet.PATTERN,
+ Facet.WHITESPACE,
+ Facet.ENUMERATION,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ static final String MAX_VALUE = "32767";
+ static final String MIN_VALUE = "32768";
+ static final int LENGTH = MAX_VALUE.length();
+
+ ShortType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "short"),
+ TypeLibrary.INT);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid short value");
+ int i = 0, off = 0;
+ boolean compare = false;
+ String compareTo = MAX_VALUE;
+ char c = value.charAt(0);
+ if (c == '+')
+ i++;
+ else if (c == '-')
+ {
+ compareTo = MIN_VALUE;
+ i++;
+ }
+ if (len - i > LENGTH)
+ throw new DatatypeException(i, "invalid short value");
+ else if (len - i == LENGTH)
+ compare = true;
+ for (; i < len; i++)
+ {
+ c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ {
+ if (compare)
+ {
+ char d = compareTo.charAt(off);
+ if (Character.digit(c, 10) > Character.digit(d, 10))
+ throw new DatatypeException(i, "invalid short value");
+ }
+ off++;
+ continue;
+ }
+ throw new DatatypeException(i, "invalid short value");
+ }
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ try
+ {
+ return new Short(literal);
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/SimpleType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/SimpleType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/SimpleType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/SimpleType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,257 @@
+/* SimpleType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.Iterator;
+import java.util.Set;
+import java.util.regex.Matcher;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.Datatype;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.DatatypeStreamingValidator;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * An XML Schema simple type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class SimpleType
+ extends Type
+ implements Datatype
+{
+
+ /**
+ * The variety of the <code>anySimpleType</code> datatype.
+ */
+ public static final int ANY = 0;
+
+ /**
+ * The atomic variety.
+ */
+ public static final int ATOMIC = 1;
+
+ /**
+ * The list variety.
+ */
+ public static final int LIST = 2;
+
+ /**
+ * The union variety.
+ */
+ public static final int UNION = 3;
+
+ public static final int ID_TYPE_NULL = 0;
+ public static final int ID_TYPE_ID = 1;
+ public static final int ID_TYPE_IDREF = 2;
+ public static final int ID_TYPE_IDREFS = 3;
+
+ /**
+ * The variety of this simple type.
+ */
+ public final int variety;
+
+ /**
+ * The facets of this simple type.
+ */
+ public Set facets;
+
+ /**
+ * The fundamental facets of this simple type.
+ */
+ public int fundamentalFacets;
+
+ /**
+ * If this datatype has been derived by restriction, then the component
+ * from which it was derived.
+ */
+ public final SimpleType baseType;
+
+ /**
+ * Optional annotation.
+ */
+ public final Annotation annotation;
+
+ public SimpleType(QName name, int variety, Set facets,
+ int fundamentalFacets, SimpleType baseType,
+ Annotation annotation)
+ {
+ super(name);
+ this.variety = variety;
+ this.facets = facets;
+ this.fundamentalFacets = fundamentalFacets;
+ this.baseType = baseType;
+ this.annotation = annotation;
+ }
+
+ /**
+ * Indicates whether this type permits the specified value.
+ */
+ public boolean isValid(String value, ValidationContext context)
+ {
+ try
+ {
+ checkValid(value, context);
+ return true;
+ }
+ catch (DatatypeException e)
+ {
+ return false;
+ }
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ if (facets != null && !facets.isEmpty())
+ {
+ Object parsedValue = createValue(value, context);
+ for (Iterator i = facets.iterator(); i.hasNext(); )
+ {
+ Facet facet = (Facet) i.next();
+ switch (facet.type)
+ {
+ case Facet.LENGTH:
+ LengthFacet lf = (LengthFacet) facet;
+ if (value.length() != lf.value)
+ throw new DatatypeException("invalid length");
+ break;
+ case Facet.MIN_LENGTH:
+ MinLengthFacet nlf = (MinLengthFacet) facet;
+ if (value.length() < nlf.value)
+ throw new DatatypeException("invalid minimum length");
+ break;
+ case Facet.MAX_LENGTH:
+ MaxLengthFacet xlf = (MaxLengthFacet) facet;
+ if (value.length() > xlf.value)
+ throw new DatatypeException("invalid maximum length");
+ break;
+ case Facet.PATTERN:
+ PatternFacet pf = (PatternFacet) facet;
+ Matcher matcher = pf.value.matcher(value);
+ if (!matcher.find())
+ throw new DatatypeException("invalid match for pattern");
+ break;
+ case Facet.ENUMERATION:
+ // TODO
+ break;
+ case Facet.WHITESPACE:
+ // TODO
+ break;
+ case Facet.MAX_INCLUSIVE:
+ MaxInclusiveFacet xif = (MaxInclusiveFacet) facet;
+ if (!xif.matches(parsedValue))
+ throw new DatatypeException("beyond upper bound");
+ break;
+ case Facet.MAX_EXCLUSIVE:
+ MaxExclusiveFacet xef = (MaxExclusiveFacet) facet;
+ if (!xef.matches(parsedValue))
+ throw new DatatypeException("beyond upper bound");
+ break;
+ case Facet.MIN_EXCLUSIVE:
+ MinExclusiveFacet nef = (MinExclusiveFacet) facet;
+ if (!nef.matches(parsedValue))
+ throw new DatatypeException("beyond lower bound");
+ break;
+ case Facet.MIN_INCLUSIVE:
+ MinInclusiveFacet nif = (MinInclusiveFacet) facet;
+ if (!nif.matches(parsedValue))
+ throw new DatatypeException("beyond lower bound");
+ break;
+ case Facet.TOTAL_DIGITS:
+ TotalDigitsFacet tdf = (TotalDigitsFacet) facet;
+ if (countDigits(value, true) > tdf.value)
+ throw new DatatypeException("too many digits");
+ break;
+ case Facet.FRACTION_DIGITS:
+ FractionDigitsFacet fdf = (FractionDigitsFacet) facet;
+ if (countDigits(value, false) > fdf.value)
+ throw new DatatypeException("too many fraction digits");
+ break;
+ }
+ }
+ }
+ }
+
+ private static int countDigits(String value, boolean any)
+ {
+ int count = 0;
+ int len = value.length();
+ boolean seenDecimal = false;
+ for (int i = 0; i < len; i++)
+ {
+ char c = value.charAt(i);
+ if (c == 0x2e)
+ seenDecimal = true;
+ else if (c >= 0x30 && c <= 0x39 && (any || seenDecimal))
+ count++;
+ }
+ return count;
+ }
+
+ // TODO createStreamingValidator
+ public DatatypeStreamingValidator createStreamingValidator(ValidationContext context)
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ return literal;
+ }
+
+ public boolean sameValue(Object value1, Object value2) {
+ return value1.equals(value2);
+ }
+
+ public int valueHashCode(Object value) {
+ return value.hashCode();
+ }
+
+ public int getIdType()
+ {
+ return ID_TYPE_NULL;
+ }
+
+ public boolean isContextDependent()
+ {
+ return false;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/StringType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/StringType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/StringType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/StringType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,77 @@
+/* StringType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.Collections;
+import java.util.Set;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema string type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class StringType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.LENGTH,
+ Facet.MIN_LENGTH,
+ Facet.MAX_LENGTH,
+ Facet.PATTERN,
+ Facet.ENUMERATION,
+ Facet.WHITESPACE
+ };
+
+ StringType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "string"),
+ TypeLibrary.ANY_SIMPLE_TYPE);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TimeType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TimeType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TimeType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TimeType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,303 @@
+/* TimeType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.TimeZone;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema time type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class TimeType
+ extends AtomicSimpleType
+{
+
+ static class Time
+ implements Comparable
+ {
+ int minutes;
+ float seconds;
+
+ public int hashCode()
+ {
+ return minutes * 31 + new Float(seconds).hashCode();
+ }
+
+ public boolean equals(Object other)
+ {
+ if (other instanceof Time)
+ {
+ Time time = (Time) other;
+ return time.minutes == minutes && time.seconds == seconds;
+ }
+ return false;
+ }
+
+ public int compareTo(Object other)
+ {
+ if (other instanceof Time)
+ {
+ Time time = (Time) other;
+ if (time.minutes != minutes)
+ return minutes - time.minutes;
+ if (time.seconds == seconds)
+ return 0;
+ return (seconds < time.seconds) ? -1 : 1;
+ }
+ return 0;
+ }
+
+ }
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.PATTERN,
+ Facet.ENUMERATION,
+ Facet.WHITESPACE,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ TimeType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "time"),
+ TypeLibrary.ANY_SIMPLE_TYPE);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ int state = 3;
+ int start = 0;
+ for (int i = 0; i < len; i++)
+ {
+ char c = value.charAt(i);
+ if (c == '-' && state == 0)
+ {
+ start++;
+ continue;
+ }
+ if (c >= 0x30 && c <= 0x39)
+ continue;
+ switch (state)
+ {
+ case 3: // hour
+ if (c == ':')
+ {
+ if (i - start != 2)
+ throw new DatatypeException(i, "invalid time value");
+ state = 4;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 4: // minute
+ if (c == ':')
+ {
+ if (i - start != 2)
+ throw new DatatypeException(i, "invalid time value");
+ state = 5;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 5: // second
+ if (c == '.')
+ {
+ if (i - start != 2)
+ throw new DatatypeException(i, "invalid time value");
+ state = 6;
+ start = i + 1;
+ continue;
+ }
+ else if (c == ' ')
+ {
+ if (i - start != 2)
+ throw new DatatypeException(i, "invalid time value");
+ state = 7;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 6: // second fraction
+ if (c == ' ')
+ {
+ state = 7;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 7: // timezone 1
+ if (start == i)
+ {
+ if (c == '+' || c == '-')
+ continue;
+ else if (c == 'Z')
+ {
+ state = 9;
+ start = i + 1;
+ continue;
+ }
+ }
+ if (c == ':')
+ {
+ if (i - start != 2)
+ throw new DatatypeException(i, "invalid time value");
+ state = 8;
+ start = i + 1;
+ continue;
+ }
+ break;
+ }
+ throw new DatatypeException(i, "invalid time value");
+ }
+ switch (state)
+ {
+ case 5: // second
+ if (len - start != 2)
+ throw new DatatypeException(len, "invalid time value");
+ break;
+ case 6: // second fraction
+ break;
+ case 8: // timezone 2
+ if (len - start != 2)
+ throw new DatatypeException(len, "invalid time value");
+ break;
+ case 9: // post Z
+ break;
+ default:
+ throw new DatatypeException(len, "invalid time value");
+ }
+ }
+
+ public Object createValue(String value, ValidationContext context) {
+ int len = value.length();
+ int state = 3;
+ int start = 0;
+ Time time = new Time();
+ try
+ {
+ for (int i = 0; i < len; i++)
+ {
+ char c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ continue;
+ switch (state)
+ {
+ case 3: // hour
+ if (c == ':')
+ {
+ time.minutes =
+ Integer.parseInt(value.substring(start, i)) * 60;
+ state = 4;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 4: // minute
+ if (c == ':')
+ {
+ time.minutes +=
+ Integer.parseInt(value.substring(start, i));
+ state = 5;
+ start = i + 1;
+ continue;
+ }
+ break;
+ case 5: // second
+ if (c == ' ')
+ {
+ time.seconds =
+ Float.parseFloat(value.substring(start, i));
+ state = 7;
+ start = i + 1;
+ continue;
+ }
+ break;
+ }
+ }
+ // end of input
+ if (len - start > 0 && state == 7)
+ {
+ // Timezone
+ String timezone = value.substring(len - start);
+ int i = timezone.indexOf(':');
+ if (i == -1)
+ {
+ if ("Z".equals(timezone))
+ timezone = "UTC";
+ TimeZone tz = TimeZone.getTimeZone(timezone);
+ if (tz == null)
+ return null;
+ time.minutes += tz.getRawOffset();
+ }
+ else
+ {
+ String tzh = timezone.substring(0, i);
+ String tzm = timezone.substring(i + 1);
+ int offset = Integer.parseInt(tzh) * 60;
+ if (offset < 0)
+ offset -= Integer.parseInt(tzm);
+ else
+ offset += Integer.parseInt(tzm);
+ time.minutes += offset;
+ }
+ }
+ return time;
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TokenType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TokenType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TokenType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TokenType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,96 @@
+/* TokenType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema token type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class TokenType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.LENGTH,
+ Facet.MIN_LENGTH,
+ Facet.MAX_LENGTH,
+ Facet.PATTERN,
+ Facet.ENUMERATION,
+ Facet.WHITESPACE
+ };
+
+ TokenType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "token"),
+ TypeLibrary.NORMALIZED_STRING);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid token value");
+ if (value.charAt(0) == ' ' || value.charAt(len - 1) == ' ')
+ throw new DatatypeException(0, "invalid token value");
+ char last = '\u0000';
+ for (int i = 0; i < len; i++)
+ {
+ char c = value.charAt(i);
+ if (c == 0x0a || c == 0x0d || c == 0x09)
+ throw new DatatypeException(i, "invalid token value");
+ if (c == ' ' && last == ' ')
+ throw new DatatypeException(i, "invalid token value");
+ last = c;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TotalDigitsFacet.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TotalDigitsFacet.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TotalDigitsFacet.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TotalDigitsFacet.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,72 @@
+/* TotalDigitsFacet.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+/**
+ * The <code>totalDigits</code> facet.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class TotalDigitsFacet
+ extends Facet
+{
+
+ public final int value;
+
+ public final boolean fixed;
+
+ public TotalDigitsFacet(int value, boolean fixed, Annotation annotation)
+ {
+ super(TOTAL_DIGITS, annotation);
+ this.value = value;
+ this.fixed = fixed;
+ }
+
+ public int hashCode()
+ {
+ return value;
+ }
+
+ public boolean equals(Object other)
+ {
+ return (other instanceof TotalDigitsFacet &&
+ ((TotalDigitsFacet) other).value == value);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/Type.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/Type.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/Type.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/Type.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,65 @@
+/* Type.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.HashMap;
+import java.util.Map;
+import javax.xml.namespace.QName;
+/**
+ * Abstract base class for XML Schema datatypes.
+ * @see http://www.w3.org/TR/xmlschema-2/
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public abstract class Type
+{
+
+ public static final Type ANY_TYPE = new AnyType();
+
+ /**
+ * The name of this type.
+ */
+ public final QName name;
+
+ public Type(QName name)
+ {
+ this.name = name;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeBuilder.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeBuilder.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeBuilder.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeBuilder.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,279 @@
+/* TypeBuilder.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.LinkedHashSet;
+import java.util.regex.Pattern;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.Datatype;
+import org.relaxng.datatype.DatatypeBuilder;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * Datatype builder.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class TypeBuilder
+ implements DatatypeBuilder
+{
+
+ final SimpleType type;
+
+ TypeBuilder(SimpleType type)
+ {
+ this.type = type;
+ // TODO fundamental facets
+ type.facets = new LinkedHashSet();
+ }
+
+ public void addParameter(String name, String value, ValidationContext context)
+ throws DatatypeException
+ {
+ // TODO fundamental facets
+ if ("length".equals(name))
+ type.facets.add(parseLengthFacet(value));
+ else if ("minLength".equals(name))
+ type.facets.add(parseMinLengthFacet(value));
+ else if ("maxLength".equals(name))
+ type.facets.add(parseMaxLengthFacet(value));
+ else if ("pattern".equals(name))
+ type.facets.add(parsePatternFacet(value));
+ else if ("enumeration".equals(name))
+ type.facets.add(parseEnumerationFacet(value));
+ else if ("whiteSpace".equals(name))
+ type.facets.add(parseWhiteSpaceFacet(value));
+ else if ("maxInclusive".equals(name))
+ type.facets.add(parseMaxInclusiveFacet(value, context));
+ else if ("maxExclusive".equals(name))
+ type.facets.add(parseMaxExclusiveFacet(value, context));
+ else if ("minExclusive".equals(name))
+ type.facets.add(parseMinExclusiveFacet(value, context));
+ else if ("minInclusive".equals(name))
+ type.facets.add(parseMinInclusiveFacet(value, context));
+ else if ("totalDigits".equals(name))
+ type.facets.add(parseTotalDigitsFacet(value));
+ else if ("fractionDigits".equals(name))
+ type.facets.add(parseFractionDigitsFacet(value));
+ }
+
+ LengthFacet parseLengthFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new LengthFacet(Integer.parseInt(value), fixed, null);
+ }
+
+ MinLengthFacet parseMinLengthFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MinLengthFacet(Integer.parseInt(value), fixed, null);
+ }
+
+ MaxLengthFacet parseMaxLengthFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MaxLengthFacet(Integer.parseInt(value), fixed, null);
+ }
+
+ PatternFacet parsePatternFacet(String value)
+ throws DatatypeException
+ {
+ return new PatternFacet(Pattern.compile(value), null);
+ }
+
+ EnumerationFacet parseEnumerationFacet(String value)
+ throws DatatypeException
+ {
+ return new EnumerationFacet(value, null);
+ }
+
+ WhiteSpaceFacet parseWhiteSpaceFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ if ("preserve".equals(value))
+ return new WhiteSpaceFacet(WhiteSpaceFacet.PRESERVE, fixed, null);
+ if ("replace".equals(value))
+ return new WhiteSpaceFacet(WhiteSpaceFacet.REPLACE, fixed, null);
+ if ("collapse".equals(value))
+ return new WhiteSpaceFacet(WhiteSpaceFacet.COLLAPSE, fixed, null);
+ throw new DatatypeException("argument must be preserve, replace, or collapse");
+ }
+
+ MaxInclusiveFacet parseMaxInclusiveFacet(String value,
+ ValidationContext context)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MaxInclusiveFacet(type.createValue(value, context), fixed, null);
+ }
+
+ MaxExclusiveFacet parseMaxExclusiveFacet(String value,
+ ValidationContext context)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MaxExclusiveFacet(type.createValue(value, context), fixed, null);
+ }
+
+ MinExclusiveFacet parseMinExclusiveFacet(String value,
+ ValidationContext context)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MinExclusiveFacet(type.createValue(value, context), fixed, null);
+ }
+
+ MinInclusiveFacet parseMinInclusiveFacet(String value,
+ ValidationContext context)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ return new MinInclusiveFacet(type.createValue(value, context), fixed, null);
+ }
+
+ TotalDigitsFacet parseTotalDigitsFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ int val = Integer.parseInt(value);
+ if (val < 0)
+ throw new DatatypeException("value must be a positiveInteger");
+ return new TotalDigitsFacet(val, fixed, null);
+ }
+
+ FractionDigitsFacet parseFractionDigitsFacet(String value)
+ throws DatatypeException
+ {
+ int si = value.indexOf(' ');
+ boolean fixed = false;
+ if (si != -1)
+ {
+ if (!"FIXED".equalsIgnoreCase(value.substring(si + 1)))
+ throw new DatatypeException("second argument must be FIXED if present");
+ fixed = true;
+ value = value.substring(0, si);
+ }
+ int val = Integer.parseInt(value);
+ if (val < 0)
+ throw new DatatypeException("value must be a positiveInteger");
+ return new FractionDigitsFacet(val, fixed, null);
+ }
+
+ public Datatype createDatatype()
+ {
+ return type;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibrary.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibrary.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibrary.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibrary.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,173 @@
+/* TypeLibrary.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.HashMap;
+import java.util.Map;
+import org.relaxng.datatype.Datatype;
+import org.relaxng.datatype.DatatypeBuilder;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.DatatypeLibrary;
+
+/**
+ * Datatype library for XML Schema datatypes.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class TypeLibrary
+ implements DatatypeLibrary
+{
+
+ public static final SimpleType ANY_SIMPLE_TYPE = new AnySimpleType();
+
+ public static final SimpleType STRING = new StringType();
+ public static final SimpleType BOOLEAN = new BooleanType();
+ public static final SimpleType DECIMAL = new DecimalType();
+ public static final SimpleType FLOAT = new FloatType();
+ public static final SimpleType DOUBLE = new DoubleType();
+ public static final SimpleType DURATION = new DurationType();
+ public static final SimpleType DATE_TIME = new DateTimeType();
+ public static final SimpleType TIME = new TimeType();
+ public static final SimpleType DATE = new DateType();
+ public static final SimpleType G_YEAR_MONTH = new GYearMonthType();
+ public static final SimpleType G_YEAR = new GYearType();
+ public static final SimpleType G_MONTH_DAY = new GMonthDayType();
+ public static final SimpleType G_DAY = new GDayType();
+ public static final SimpleType G_MONTH = new GMonthType();
+ public static final SimpleType HEX_BINARY = new HexBinaryType();
+ public static final SimpleType BASE64_BINARY = new Base64BinaryType();
+ public static final SimpleType ANY_URI = new AnyURIType();
+ public static final SimpleType QNAME = new QNameType();
+ public static final SimpleType NOTATION = new NotationType();
+
+ public static final SimpleType NORMALIZED_STRING = new NormalizedStringType();
+ public static final SimpleType TOKEN = new TokenType();
+ public static final SimpleType LANGUAGE = new LanguageType();
+ public static final SimpleType NMTOKEN = new NMTokenType();
+ public static final SimpleType NMTOKENS = new NMTokensType();
+ public static final SimpleType NAME = new NameType();
+ public static final SimpleType NCNAME = new NCNameType();
+ public static final SimpleType ID = new IDType();
+ public static final SimpleType IDREF = new IDRefType();
+ public static final SimpleType IDREFS = new IDRefsType();
+ public static final SimpleType ENTITY = new EntityType();
+ public static final SimpleType ENTITIES = new EntitiesType();
+ public static final SimpleType INTEGER = new IntegerType();
+ public static final SimpleType NON_POSITIVE_INTEGER = new NonPositiveIntegerType();
+ public static final SimpleType NEGATIVE_INTEGER = new NegativeIntegerType();
+ public static final SimpleType LONG = new LongType();
+ public static final SimpleType INT = new IntType();
+ public static final SimpleType SHORT = new ShortType();
+ public static final SimpleType BYTE = new ByteType();
+ public static final SimpleType NON_NEGATIVE_INTEGER = new NonNegativeIntegerType();
+ public static final SimpleType UNSIGNED_LONG = new UnsignedLongType();
+ public static final SimpleType UNSIGNED_INT = new UnsignedIntType();
+ public static final SimpleType UNSIGNED_SHORT = new UnsignedShortType();
+ public static final SimpleType UNSIGNED_BYTE = new UnsignedByteType();
+ public static final SimpleType POSITIVE_INTEGER = new PositiveIntegerType();
+
+ private static Map byName;
+ static
+ {
+ byName = new HashMap();
+ byName.put("anySimpleType", ANY_SIMPLE_TYPE);
+ byName.put("string", STRING);
+ byName.put("boolean", BOOLEAN);
+ byName.put("decimal", DECIMAL);
+ byName.put("float", FLOAT);
+ byName.put("double", DOUBLE);
+ byName.put("duration", DURATION);
+ byName.put("dateTime", DATE_TIME);
+ byName.put("time", TIME);
+ byName.put("date", DATE);
+ byName.put("gYearMonth", G_YEAR_MONTH);
+ byName.put("gYear", G_YEAR);
+ byName.put("gMonthDay", G_MONTH_DAY);
+ byName.put("gDay", G_DAY);
+ byName.put("gMonth",G_MONTH);
+ byName.put("hexBinary", HEX_BINARY);
+ byName.put("base64Binary", BASE64_BINARY);
+ byName.put("anyURI", ANY_URI);
+ byName.put("QName", QNAME);
+ byName.put("NOTATION", NOTATION);
+ byName.put("normalizedString", NORMALIZED_STRING);
+ byName.put("token", TOKEN);
+ byName.put("language", LANGUAGE);
+ byName.put("NMTOKEN", NMTOKEN);
+ byName.put("NMTOKENS", NMTOKENS);
+ byName.put("Name", NAME);
+ byName.put("NCName", NCNAME);
+ byName.put("ID", ID);
+ byName.put("IDREF", IDREF);
+ byName.put("IDREFS", IDREFS);
+ byName.put("ENTITY", ENTITY);
+ byName.put("ENTITIES", ENTITIES);
+ byName.put("integer", INTEGER);
+ byName.put("nonPositiveInteger", NON_POSITIVE_INTEGER);
+ byName.put("negativeInteger", NEGATIVE_INTEGER);
+ byName.put("long", LONG);
+ byName.put("int", INT);
+ byName.put("short", SHORT);
+ byName.put("byte", BYTE);
+ byName.put("nonNegativeInteger", NON_NEGATIVE_INTEGER);
+ byName.put("unsignedLong", UNSIGNED_LONG);
+ byName.put("unsignedInt", UNSIGNED_INT);
+ byName.put("unsignedShort", UNSIGNED_SHORT);
+ byName.put("unsignedByte", UNSIGNED_BYTE);
+ byName.put("positiveInteger", POSITIVE_INTEGER);
+ }
+
+ public DatatypeBuilder createDatatypeBuilder(String baseTypeLocalName)
+ throws DatatypeException
+ {
+ SimpleType type = (SimpleType) byName.get(baseTypeLocalName);
+ if (type == null)
+ throw new DatatypeException("Unknown type name: " + baseTypeLocalName);
+ return new TypeBuilder(type);
+ }
+
+ public Datatype createDatatype(String typeLocalName)
+ throws DatatypeException
+ {
+ SimpleType type = (SimpleType) byName.get(typeLocalName);
+ if (type == null)
+ throw new DatatypeException("Unknown type name: " + typeLocalName);
+ return type;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibraryFactory.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibraryFactory.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibraryFactory.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/TypeLibraryFactory.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,60 @@
+/* TypeLibraryFactory.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import org.relaxng.datatype.DatatypeLibrary;
+import org.relaxng.datatype.DatatypeLibraryFactory;
+
+/**
+ * Datatype library factory for XML Schema datatypes.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class TypeLibraryFactory
+ implements DatatypeLibraryFactory
+{
+
+ public DatatypeLibrary createDatatypeLibrary(String namespaceURI)
+ {
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(namespaceURI))
+ return new TypeLibrary();
+ return null;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnionSimpleType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnionSimpleType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnionSimpleType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnionSimpleType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,83 @@
+/* UnionSimpleType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * An XML Schema union simple type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class UnionSimpleType
+ extends SimpleType
+{
+
+ /**
+ * The member types in this union.
+ */
+ public final List memberTypes;
+
+ public UnionSimpleType(QName name, Set facets,
+ int fundamentalFacets, SimpleType baseType,
+ Annotation annotation, List memberTypes)
+ {
+ super(name, UNION, facets, fundamentalFacets, baseType, annotation);
+ this.memberTypes = memberTypes;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ for (Iterator i = memberTypes.iterator(); i.hasNext(); )
+ {
+ SimpleType type = (SimpleType) i.next();
+ if (type.isValid(value, context))
+ return;
+ }
+ throw new DatatypeException("invalid union type value");
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedByteType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedByteType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedByteType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedByteType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,121 @@
+/* UnsignedByteType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema unsignedByte type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class UnsignedByteType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.TOTAL_DIGITS,
+ Facet.FRACTION_DIGITS,
+ Facet.PATTERN,
+ Facet.WHITESPACE,
+ Facet.ENUMERATION,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ static final String MAX_VALUE = "255";
+ static final int LENGTH = MAX_VALUE.length();
+
+ UnsignedByteType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "unsignedByte"),
+ TypeLibrary.UNSIGNED_SHORT);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid unsigned byte value");
+ boolean compare = false;
+ for (int i = 0; i < len; i++)
+ {
+ if (len - i > LENGTH)
+ throw new DatatypeException(i, "invalid unsigned byte value");
+ else if (len - i == LENGTH)
+ compare = true;
+ char c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ {
+ if (compare)
+ {
+ char d = MAX_VALUE.charAt(i);
+ if (Character.digit(c, 10) > Character.digit(d, 10))
+ throw new DatatypeException(i, "invalid unsigned byte value");
+ }
+ continue;
+ }
+ throw new DatatypeException(i, "invalid unsigned byte value");
+ }
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ try
+ {
+ return new Byte(literal);
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedIntType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedIntType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedIntType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedIntType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,121 @@
+/* UnsignedIntType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema unsignedInt type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class UnsignedIntType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.TOTAL_DIGITS,
+ Facet.FRACTION_DIGITS,
+ Facet.PATTERN,
+ Facet.WHITESPACE,
+ Facet.ENUMERATION,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ static final String MAX_VALUE = "4294967295";
+ static final int LENGTH = MAX_VALUE.length();
+
+ UnsignedIntType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "unsignedInt"),
+ TypeLibrary.UNSIGNED_LONG);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid unsigned int value");
+ boolean compare = false;
+ for (int i = 0; i < len; i++)
+ {
+ if (len - i > LENGTH)
+ throw new DatatypeException(i, "invalid unsigned int value");
+ else if (len - i == LENGTH)
+ compare = true;
+ char c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ {
+ if (compare)
+ {
+ char d = MAX_VALUE.charAt(i);
+ if (Character.digit(c, 10) > Character.digit(d, 10))
+ throw new DatatypeException(i, "invalid unsigned int value");
+ }
+ continue;
+ }
+ throw new DatatypeException(i, "invalid unsigned int value");
+ }
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ try
+ {
+ return new Integer(literal);
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedLongType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedLongType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedLongType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedLongType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,121 @@
+/* UnsignedLongType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema unsignedLong type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class UnsignedLongType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.TOTAL_DIGITS,
+ Facet.FRACTION_DIGITS,
+ Facet.PATTERN,
+ Facet.WHITESPACE,
+ Facet.ENUMERATION,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ static final String MAX_VALUE = "18446744073709551615";
+ static final int LENGTH = MAX_VALUE.length();
+
+ UnsignedLongType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "unsignedLong"),
+ TypeLibrary.NON_NEGATIVE_INTEGER);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid unsigned long value");
+ boolean compare = false;
+ for (int i = 0; i < len; i++)
+ {
+ if (len - i > LENGTH)
+ throw new DatatypeException(i, "invalid unsigned long value");
+ else if (len - i == LENGTH)
+ compare = true;
+ char c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ {
+ if (compare)
+ {
+ char d = MAX_VALUE.charAt(i);
+ if (Character.digit(c, 10) > Character.digit(d, 10))
+ throw new DatatypeException(i, "invalid unsigned long value");
+ }
+ continue;
+ }
+ throw new DatatypeException(i, "invalid unsigned long value");
+ }
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ try
+ {
+ return new Long(literal);
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedShortType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedShortType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedShortType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/UnsignedShortType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,122 @@
+/* UnsignedShortType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.ValidationContext;
+
+/**
+ * The XML Schema unsignedShort type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class UnsignedShortType
+ extends AtomicSimpleType
+{
+
+ static final int[] CONSTRAINING_FACETS = {
+ Facet.TOTAL_DIGITS,
+ Facet.FRACTION_DIGITS,
+ Facet.PATTERN,
+ Facet.WHITESPACE,
+ Facet.ENUMERATION,
+ Facet.MAX_INCLUSIVE,
+ Facet.MAX_EXCLUSIVE,
+ Facet.MIN_INCLUSIVE,
+ Facet.MIN_EXCLUSIVE
+ };
+
+ static final String MAX_VALUE = "65535";
+ static final int LENGTH = MAX_VALUE.length();
+
+ UnsignedShortType()
+ {
+ super(new QName(XMLConstants.W3C_XML_SCHEMA_NS_URI, "unsignedShort"),
+ TypeLibrary.UNSIGNED_INT);
+ }
+
+ public int[] getConstrainingFacets()
+ {
+ return CONSTRAINING_FACETS;
+ }
+
+ public void checkValid(String value, ValidationContext context)
+ throws DatatypeException
+ {
+ super.checkValid(value, context);
+ int len = value.length();
+ if (len == 0)
+ throw new DatatypeException(0, "invalid unsigned short value");
+ boolean compare = false;
+ for (int i = 0; i < len; i++)
+ {
+ if (len - i > LENGTH)
+ throw new DatatypeException(i, "invalid unsigned short value");
+ else if (len - i == LENGTH)
+ compare = true;
+ char c = value.charAt(i);
+ if (c >= 0x30 && c <= 0x39)
+ {
+ if (compare)
+ {
+ char d = MAX_VALUE.charAt(i);
+ if (Character.digit(c, 10) > Character.digit(d, 10))
+ throw new DatatypeException(i,
+ "invalid unsigned short value");
+ }
+ continue;
+ }
+ throw new DatatypeException(i, "invalid unsigned short value");
+ }
+ }
+
+ public Object createValue(String literal, ValidationContext context) {
+ try
+ {
+ return new Short(literal);
+ }
+ catch (NumberFormatException e)
+ {
+ return null;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/WhiteSpaceFacet.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/WhiteSpaceFacet.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/WhiteSpaceFacet.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/datatype/WhiteSpaceFacet.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,75 @@
+/* WhiteSpaceFacet.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.datatype;
+
+/**
+ * The <code>whiteSpace</code> facet.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class WhiteSpaceFacet
+ extends Facet
+{
+
+ public static final int PRESERVE = 0;
+ public static final int REPLACE = 1;
+ public static final int COLLAPSE = 2;
+
+ public final int value;
+ public final boolean fixed;
+
+ public WhiteSpaceFacet(int value, boolean fixed, Annotation annotation)
+ {
+ super(WHITESPACE, annotation);
+ this.value = value;
+ this.fixed = fixed;
+ }
+
+ public int hashCode()
+ {
+ return value;
+ }
+
+ public boolean equals(Object other)
+ {
+ return (other instanceof WhiteSpaceFacet &&
+ ((WhiteSpaceFacet) other).value == value);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AnyNameNameClass.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AnyNameNameClass.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AnyNameNameClass.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AnyNameNameClass.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,58 @@
+/* AnyNameNameClass.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG anyName element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class AnyNameNameClass
+ extends NameClass
+{
+
+ NameClass exceptNameClass;
+
+ boolean matchesName(String uri, String localName)
+ {
+ return (exceptNameClass == null) ? true :
+ !exceptNameClass.matchesName(uri, localName);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AttributePattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AttributePattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AttributePattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/AttributePattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* AttributePattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG attribute element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class AttributePattern
+ extends Pattern
+{
+
+ NameClass nameClass;
+ Pattern pattern;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoiceNameClass.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoiceNameClass.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoiceNameClass.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoiceNameClass.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,59 @@
+/* ChoiceNameClass.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG choice element (in the context of a name class).
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ChoiceNameClass
+ extends NameClass
+{
+
+ NameClass name1;
+ NameClass name2;
+
+ boolean matchesName(String uri, String localName)
+ {
+ return name1.matchesName(uri, localName) ||
+ name2.matchesName(uri, localName);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoicePattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoicePattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoicePattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ChoicePattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* ChoicePattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG choice element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ChoicePattern
+ extends Pattern
+{
+
+ Pattern pattern1;
+ Pattern pattern2;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/DataPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/DataPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/DataPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/DataPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,60 @@
+/* DataPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.util.LinkedList;
+import java.util.List;
+import org.relaxng.datatype.Datatype;
+import org.relaxng.datatype.DatatypeLibrary;
+
+/**
+ * A RELAX NG data element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class DataPattern
+ extends Pattern
+{
+
+ Datatype type;
+ DatatypeLibrary datatypeLibrary;
+ List params = new LinkedList();
+ Pattern exceptPattern;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Define.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Define.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Define.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Define.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* Define.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG define.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class Define
+{
+
+ String name;
+ ElementPattern element;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ElementPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ElementPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ElementPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ElementPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* ElementPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ElementPattern
+ extends Pattern
+{
+
+ NameClass nameClass;
+ Pattern pattern;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/EmptyPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/EmptyPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/EmptyPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/EmptyPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* EmptyPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG empty element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class EmptyPattern
+ extends Pattern
+{
+
+ static final EmptyPattern INSTANCE = new EmptyPattern();
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/FullSyntaxBuilder.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/FullSyntaxBuilder.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/FullSyntaxBuilder.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/FullSyntaxBuilder.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,1651 @@
+/* FullSyntaxBuilder.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.io.InputStream;
+import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+import java.net.URL;
+import java.net.URLEncoder;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.DatatypeLibrary;
+import org.relaxng.datatype.helpers.DatatypeLibraryLoader;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+import org.xml.sax.SAXException;
+
+import gnu.xml.stream.XMLParser;
+
+/**
+ * Parses a RELAX NG XML DOM tree, constructing a compiled internal
+ * representation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class FullSyntaxBuilder
+{
+
+ /**
+ * Complete vocabulary (elements and attributes) of the full syntax.
+ */
+ static final Map VOCABULARY = new HashMap();
+ static final Set STRIPPED_ATTRIBUTES = new HashSet();
+ static final Set PATTERN_ELEMENTS = new HashSet();
+ static
+ {
+ Set elementAttrs = Collections.singleton("name");
+ Set dataAttrs = new HashSet();
+ dataAttrs.add("type");
+ dataAttrs.add("datatypeLibrary");
+ Set valueAttrs = new HashSet();
+ valueAttrs.add("type");
+ valueAttrs.add("datatypeLibrary");
+ valueAttrs.add("ns");
+ Set externalAttrs = Collections.singleton("href");
+ Set startAttrs = Collections.singleton("combine");
+ Set defineAttrs = new HashSet();
+ defineAttrs.add("name");
+ defineAttrs.add("combine");
+ Set nsAttrs = Collections.singleton("ns");
+
+ VOCABULARY.put("element", elementAttrs);
+ VOCABULARY.put("attribute", elementAttrs);
+ VOCABULARY.put("group", Collections.EMPTY_SET);
+ VOCABULARY.put("interleave", Collections.EMPTY_SET);
+ VOCABULARY.put("choice", Collections.EMPTY_SET);
+ VOCABULARY.put("optional", Collections.EMPTY_SET);
+ VOCABULARY.put("zeroOrMore", Collections.EMPTY_SET);
+ VOCABULARY.put("oneOrMore", Collections.EMPTY_SET);
+ VOCABULARY.put("list", Collections.EMPTY_SET);
+ VOCABULARY.put("mixed", Collections.EMPTY_SET);
+ VOCABULARY.put("ref", elementAttrs);
+ VOCABULARY.put("parentRef", elementAttrs);
+ VOCABULARY.put("empty", Collections.EMPTY_SET);
+ VOCABULARY.put("text", Collections.EMPTY_SET);
+ VOCABULARY.put("value", valueAttrs);
+ VOCABULARY.put("data", dataAttrs);
+ VOCABULARY.put("notAllowed", Collections.EMPTY_SET);
+ VOCABULARY.put("externalRef", externalAttrs);
+ VOCABULARY.put("grammar", Collections.EMPTY_SET);
+ VOCABULARY.put("param", elementAttrs);
+ VOCABULARY.put("except", Collections.EMPTY_SET);
+ VOCABULARY.put("div", Collections.EMPTY_SET);
+ VOCABULARY.put("include", externalAttrs);
+ VOCABULARY.put("start", startAttrs);
+ VOCABULARY.put("define", defineAttrs);
+ VOCABULARY.put("name", nsAttrs);
+ VOCABULARY.put("anyName", Collections.EMPTY_SET);
+ VOCABULARY.put("nsName", nsAttrs);
+
+ STRIPPED_ATTRIBUTES.add("name");
+ STRIPPED_ATTRIBUTES.add("type");
+ STRIPPED_ATTRIBUTES.add("combine");
+
+ PATTERN_ELEMENTS.add("element");
+ PATTERN_ELEMENTS.add("attribute");
+ PATTERN_ELEMENTS.add("group");
+ PATTERN_ELEMENTS.add("interleave");
+ PATTERN_ELEMENTS.add("choice");
+ PATTERN_ELEMENTS.add("optional");
+ PATTERN_ELEMENTS.add("zeroOrMore");
+ PATTERN_ELEMENTS.add("oneOrMore");
+ PATTERN_ELEMENTS.add("list");
+ PATTERN_ELEMENTS.add("mixed");
+ PATTERN_ELEMENTS.add("ref");
+ PATTERN_ELEMENTS.add("parentRef");
+ PATTERN_ELEMENTS.add("empty");
+ PATTERN_ELEMENTS.add("text");
+ PATTERN_ELEMENTS.add("value");
+ PATTERN_ELEMENTS.add("data");
+ PATTERN_ELEMENTS.add("notAllowed");
+ PATTERN_ELEMENTS.add("externalRef");
+ PATTERN_ELEMENTS.add("grammar");
+ }
+
+ private Set urls; // recursion checking
+ private int refCount; // creation of ref names
+ private Map datatypeLibraries;
+
+ /**
+ * Parse the specified document into a grammar.
+ */
+ synchronized Grammar parse(Document doc)
+ throws IOException
+ {
+ urls = new HashSet();
+ refCount = 1;
+
+ doc.normalizeDocument(); // Normalize XML document
+ transform(doc); // Apply transformation rules to provide simple syntax
+
+ // 4.18. grammar element
+ Element p = doc.getDocumentElement();
+ Element grammar =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "grammar");
+ Element start =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "start");
+ doc.removeChild(p);
+ doc.appendChild(grammar);
+ grammar.appendChild(start);
+ start.appendChild(p);
+ transformGrammar(grammar, p);
+ Element define = getNextSiblingElement(start);
+ while (define != null)
+ {
+ Element next = getNextSiblingElement(define);
+ String name = define.getAttribute("new-name");
+ if (name != null)
+ {
+ define.setAttribute("name", name);
+ define.removeAttribute("new-name");
+ }
+ else
+ grammar.removeChild(define); // unreferenced
+ define = next;
+ }
+
+ // 4.19. define and ref elements
+ Set allDefines = new HashSet(), reachableDefines = new HashSet();
+ getDefines(allDefines, grammar, grammar, false);
+ getDefines(reachableDefines, grammar, start, true);
+ allDefines.removeAll(reachableDefines);
+ for (Iterator i = allDefines.iterator(); i.hasNext(); )
+ {
+ // remove unreachable defines
+ Element d = (Element) i.next();
+ Node parent = d.getParentNode();
+ parent.removeChild(d);
+ }
+ // replace all elements that are not children of defines by refs to new
+ // defines
+ Set elements = new HashSet();
+ getElements(elements, grammar, grammar);
+ for (Iterator i = elements.iterator(); i.hasNext(); )
+ {
+ Element element = (Element) i.next();
+ Node parent = element.getParentNode();
+ if (!reachableDefines.contains(parent))
+ {
+ define =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "define");
+ Element ref =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "ref");
+ String name = createRefName();
+ define.setAttribute("name", name);
+ ref.setAttribute("name", name);
+ parent.insertBefore(ref, element);
+ define.appendChild(element);
+ grammar.appendChild(define);
+ reachableDefines.add(define);
+ }
+ }
+ // Get defines that don't have element children
+ for (Iterator i = reachableDefines.iterator(); i.hasNext(); )
+ {
+ Element d = (Element) i.next();
+ Element child = getFirstChildElement(d);
+ if (child != null && "element".equals(child.getLocalName()))
+ i.remove();
+ }
+ // Expand refs that refer to these defines
+ expandRefs(reachableDefines, grammar);
+ // Remove any defines that don't have element children
+ for (Iterator i = reachableDefines.iterator(); i.hasNext(); )
+ {
+ Element d = (Element) i.next();
+ Node parent = d.getParentNode();
+ parent.removeChild(d);
+ }
+
+ transform2(p); // Apply second stage transformation rules
+
+ Grammar ret = parseGrammar(grammar);
+ datatypeLibraries = null; // free datatype libraries cache
+ return ret;
+ }
+
+ private void getDefines(Set defines, Element grammar, Element node,
+ boolean followRefs)
+ {
+ String elementName = node.getLocalName();
+ if ("define".equals(elementName))
+ defines.add(node);
+ else if ("ref".equals(elementName) && followRefs)
+ {
+ String rname = node.getAttribute("name");
+ Element define = getFirstChildElement(grammar);
+ define = getNextSiblingElement(define);
+ while (define != null)
+ {
+ String dname = define.getAttribute("name");
+ if (rname.equals(dname))
+ {
+ getDefines(defines, grammar, node, followRefs);
+ break;
+ }
+ define = getNextSiblingElement(define);
+ }
+ }
+ for (Element child = getFirstChildElement(node); child != null;
+ child = getNextSiblingElement(child))
+ getDefines(defines, grammar, child, followRefs);
+ }
+
+ private void getElements(Set elements, Element grammar, Element node)
+ {
+ String elementName = node.getLocalName();
+ if ("element".equals(elementName))
+ elements.add(node);
+ for (Element child = getFirstChildElement(node); child != null;
+ child = getNextSiblingElement(child))
+ getElements(elements, grammar, child);
+ }
+
+ private void expandRefs(Set defines, Element node)
+ throws GrammarException
+ {
+ String elementName = node.getLocalName();
+ if ("ref".equals(elementName))
+ {
+ String rname = node.getAttribute("name");
+ for (Iterator i = defines.iterator(); i.hasNext(); )
+ {
+ Element define = (Element) i.next();
+ String dname = define.getAttribute("name");
+ if (rname.equals(dname))
+ {
+ Element child = getFirstChildElement(define);
+ forbidRefs(child, rname);
+ Element refChild = (Element) child.cloneNode(true);
+ Node parent = node.getParentNode();
+ parent.insertBefore(refChild, node);
+ parent.removeChild(node);
+ node = refChild;
+ break;
+ }
+ }
+ }
+ for (Element child = getFirstChildElement(node); child != null;
+ child = getNextSiblingElement(child))
+ expandRefs(defines, child);
+ }
+
+ private void forbidRefs(Element node, String name)
+ throws GrammarException
+ {
+ String elementName = node.getLocalName();
+ if ("ref".equals(elementName))
+ {
+ String rname = node.getAttribute("name");
+ if (name.equals(rname))
+ throw new GrammarException("cannot expand ref with name '" + name +
+ "' due to circularity");
+ }
+ for (Element child = getFirstChildElement(node); child != null;
+ child = getNextSiblingElement(child))
+ forbidRefs(child, name);
+ }
+
+ private void transform(Node node)
+ throws IOException
+ {
+ Node parent = node.getParentNode();
+ switch (node.getNodeType())
+ {
+ case Node.ELEMENT_NODE:
+ // 4.1 Annotations
+ String elementNs = node.getNamespaceURI();
+ String elementName = node.getLocalName();
+ if (!XMLConstants.RELAXNG_NS_URI.equals(elementNs) ||
+ !VOCABULARY.containsKey(elementName))
+ parent.removeChild(node);
+ else
+ {
+ Set allowedAttrs = (Set) VOCABULARY.get(elementName);
+ NamedNodeMap attrs = node.getAttributes();
+ int len = attrs.getLength();
+ for (int i = len - 1; i >= 0; i--)
+ {
+ Node attr = attrs.item(i);
+ String attrNs = attr.getNamespaceURI();
+ String attrName = attr.getLocalName();
+ if (XMLConstants.XMLNS_ATTRIBUTE_NS_URI.equals(attrNs))
+ continue; // ignore namespace nodes
+ if (!(XMLConstants.RELAXNG_NS_URI.equals(attrNs) ||
+ attrNs == null) ||
+ !allowedAttrs.contains(attrName))
+ attrs.removeNamedItemNS(attrNs, attrName);
+ else
+ {
+ // 4.2 Whitespace
+ if (STRIPPED_ATTRIBUTES.contains(attrName))
+ attr.setNodeValue(attr.getNodeValue().trim());
+ // 4.3 datatypeLibrary attribute
+ else if ("datatypeLibrary".equals(attrName))
+ {
+ String dl = attr.getNodeValue();
+ attr.setNodeValue(escapeURL(dl));
+ }
+ // 4.5. href attribute
+ else if ("href".equals(attrName))
+ {
+ String href = attr.getNodeValue();
+ href = XMLParser.absolutize(node.getBaseURI(),
+ escapeURL(href));
+ attr.setNodeValue(href);
+ }
+ }
+ }
+ // 4.3 datatypeLibrary attribute
+ if ("data".equals(elementName) || "value".equals(elementName))
+ {
+ Element element = (Element) node;
+ String dl = element.getAttribute("datatypeLibrary");
+ if (dl == null)
+ {
+ Node p = parent;
+ while (dl == null && p != null &&
+ p.getNodeType() == Node.ELEMENT_NODE)
+ {
+ dl = ((Element) p)
+ .getAttribute("datatypeLibrary");
+ p = p.getParentNode();
+ }
+ if (dl == null)
+ dl = "";
+ element.setAttribute("datatypeLibrary", dl);
+ }
+ // 4.4. type attribute of value element
+ if ("value".equals(elementName))
+ {
+ String type = element.getAttribute("type");
+ if (type == null)
+ {
+ element.setAttribute("type", "token");
+ element.setAttribute("datatypeLibrary", "");
+ }
+ }
+ // 4.16. Constraints
+ // TODO validate type
+ }
+ // 4.6. externalRef element
+ else if ("externalRef".equals(elementName))
+ {
+ Element externalRef = (Element) node;
+ String href = externalRef.getAttribute("href");
+ // check for recursion
+ if (urls.contains(href))
+ throw new GrammarException("recursive href");
+ urls.add(href);
+ Element element = resolve(href);
+ String eNs = element.getNamespaceURI();
+ String eName = element.getLocalName();
+ if (!(XMLConstants.RELAXNG_NS_URI.equals(eNs) ||
+ eNs == null) ||
+ !PATTERN_ELEMENTS.contains(eName))
+ throw new GrammarException("externally referenced element " +
+ "is not a pattern");
+ transform(element);
+ urls.remove(href);
+ String ns = element.getAttribute("ns");
+ if (ns != null)
+ element.setAttribute("ns",
+ externalRef.getAttribute("ns"));
+ element = (Element) externalRef.getOwnerDocument()
+ .importNode(element, true);
+ parent.replaceChild(element, externalRef);
+ return;
+ }
+ // 4.7 include element
+ else if ("include".equals(elementName))
+ {
+ Element include = (Element) node;
+ String href = include.getAttribute("href");
+ // check for recursion
+ if (urls.contains(href))
+ throw new GrammarException("recursive href");
+ urls.add(href);
+ Element element = resolve(href);
+ String eNs = element.getNamespaceURI();
+ String eName = element.getLocalName();
+ if (!(XMLConstants.RELAXNG_NS_URI.equals(eNs) ||
+ eNs == null) ||
+ !"grammar".equals(eName))
+ throw new GrammarException("included element is not " +
+ "a grammar");
+
+ transform(element);
+ urls.remove(href);
+ // handle components
+ List includeComponents = getComponents(include);
+ List grammarComponents = getComponents(element);
+ for (Iterator i = includeComponents.iterator(); i.hasNext(); )
+ {
+ Element comp = (Element) i.next();
+ String compName = comp.getLocalName();
+ if ("start".equals(compName))
+ {
+ boolean found = false;
+ for (Iterator j = grammarComponents.iterator();
+ j.hasNext(); )
+ {
+ Element c2 = (Element) j.next();
+ if ("start".equals(c2.getLocalName()))
+ {
+ c2.getParentNode().removeChild(c2);
+ found = true;
+ }
+ }
+ if (!found)
+ throw new GrammarException("no start component in " +
+ "included grammar");
+ }
+ else if ("define".equals(compName))
+ {
+ String name = comp.getAttribute("name");
+ boolean found = false;
+ for (Iterator j = grammarComponents.iterator();
+ j.hasNext(); )
+ {
+ Element c2 = (Element) j.next();
+ if ("define".equals(c2.getLocalName()) &&
+ name.equals(c2.getAttribute("name")))
+ {
+ c2.getParentNode().removeChild(c2);
+ found = true;
+ }
+ }
+ if (!found)
+ throw new GrammarException("no define component " +
+ "with name '" + name +
+ "' in included grammar");
+ }
+ }
+ // transform to div element
+ Document doc = include.getOwnerDocument();
+ Element includeDiv =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "div");
+ Element grammarDiv =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "div");
+ // XXX copy include non-href attributes (none defined?)
+ element = (Element) doc.importNode(element, true);
+ Node ctx = element.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ grammarDiv.appendChild(ctx);
+ ctx = next;
+ }
+ includeDiv.appendChild(grammarDiv);
+ ctx = include.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ includeDiv.appendChild(ctx);
+ ctx = next;
+ }
+ parent.replaceChild(includeDiv, include);
+ transform(includeDiv);
+ return;
+ }
+ // 4.8. name attribute of element and attribute elements
+ else if ("attribute".equals(elementName) ||
+ "element".equals(elementName))
+ {
+ Element element = (Element) node;
+ String name = element.getAttribute("name");
+ if (name != null)
+ {
+ Document doc = element.getOwnerDocument();
+ Element n =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, "name");
+ n.appendChild(doc.createTextNode(name));
+ Node first = element.getFirstChild();
+ if (first != null)
+ element.insertBefore(n, first);
+ else
+ element.appendChild(n);
+ if ("attribute".equals(elementName))
+ {
+ String ns = element.getAttribute("ns");
+ if (ns != null)
+ {
+ n.setAttribute("ns", ns);
+ element.removeAttribute("ns");
+ }
+ }
+ element.removeAttribute("name");
+ }
+ // 4.12. Number of child elements
+ if ("attribute".equals(elementName))
+ {
+ if (getComponents(node).size() == 1)
+ {
+ Document doc = node.getOwnerDocument();
+ Element text =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "text");
+ node.appendChild(text);
+ }
+ }
+ else // element
+ {
+ if (node.getChildNodes().getLength() > 2)
+ {
+ // transform to 2 child elements
+ Document doc = node.getOwnerDocument();
+ Element child =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "group");
+ Node ctx = getFirstChildElement(node);
+ ctx = getNextSiblingElement(ctx); // skip 1
+ while (ctx != null)
+ {
+ Node next = getNextSiblingElement(ctx);
+ child.appendChild(ctx);
+ ctx = next;
+ }
+ node.appendChild(child);
+ }
+ }
+ }
+ // 4.11. div element
+ else if ("div".equals(elementName))
+ {
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ parent.insertBefore(ctx, node);
+ transform(ctx);
+ ctx = next;
+ }
+ parent.removeChild(node);
+ return;
+ }
+ else if ("mixed".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ transformToOneChildElement(node, "group");
+ // 4.13. mixed element
+ Document doc = node.getOwnerDocument();
+ Node interleave =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "interleave");
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ interleave.appendChild(ctx);
+ ctx = next;
+ }
+ Node text =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "text");
+ interleave.appendChild(text);
+ parent.insertBefore(interleave, node);
+ parent.removeChild(node);
+ node = interleave;
+ }
+ else if ("optional".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ transformToOneChildElement(node, "group");
+ // 4.14. optional element
+ Document doc = node.getOwnerDocument();
+ Node choice =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "choice");
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ choice.appendChild(ctx);
+ ctx = next;
+ }
+ Node empty =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "empty");
+ choice.appendChild(empty);
+ parent.insertBefore(choice, node);
+ parent.removeChild(node);
+ node = choice;
+ }
+ else if ("zeroOrMore".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ transformToOneChildElement(node, "group");
+ // 4.15. zeroOrMore element
+ Document doc = node.getOwnerDocument();
+ Node choice =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "choice");
+ Node oneOrMore =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "oneOrMore");
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ oneOrMore.appendChild(ctx);
+ ctx = next;
+ }
+ Node empty =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "empty");
+ choice.appendChild(oneOrMore);
+ choice.appendChild(empty);
+ parent.insertBefore(choice, node);
+ parent.removeChild(node);
+ node = choice;
+ }
+ else if ("list".equals(elementName) ||
+ "oneOrMore".equals(elementName) ||
+ "define".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ transformToOneChildElement(node, "group");
+ }
+ else if ("except".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ transformToOneChildElement(node, "choice");
+ // 4.16. Constraints
+ String parentName = parent.getLocalName();
+ if ("anyName".equals(parentName))
+ forbidDescendants(node, Collections.singleton("anyName"));
+ else if ("nsName".equals(parentName))
+ {
+ Set names = new HashSet();
+ names.add("nsName");
+ names.add("anyName");
+ forbidDescendants(node, names);
+ }
+ }
+ else if ("choice".equals(elementName) ||
+ "group".equals(elementName) ||
+ "interleave".equals(elementName))
+ {
+ // 4.12. Number of child elements
+ Node ctx = getFirstChildElement(node);
+ Node next = getNextSiblingElement(ctx);
+ if (next == null)
+ {
+ // replace
+ parent.insertBefore(ctx, node);
+ parent.removeChild(node);
+ transform(ctx);
+ return;
+ }
+ else
+ {
+ // transform to 2 child elements
+ Node next2 = getNextSiblingElement(next);
+ if (next2 != null)
+ {
+ Document doc = node.getOwnerDocument();
+ Node child =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ elementName);
+ child.appendChild(ctx);
+ child.appendChild(next);
+ node.insertBefore(next2, child);
+ transform(node); // recurse
+ }
+ }
+ }
+ // 4.17. combine attribute
+ else if ("grammar".equals(elementName))
+ {
+ String combine = null;
+ List nodes = new LinkedList();
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ if ("start".equals(ctx.getLocalName()))
+ {
+ String c = ((Element) ctx).getAttribute("combine");
+ if (combine != null && !combine.equals(c))
+ throw new GrammarException("multiple start elements "+
+ "but no combine attribute");
+ combine = c;
+ nodes.add(ctx);
+ }
+ ctx = next;
+ }
+ if (!nodes.isEmpty())
+ combineNodes(node, combine, "start", nodes);
+ // defines
+ Map defines = new HashMap();
+ Map defineCombines = new HashMap();
+ ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ if ("define".equals(ctx.getLocalName()))
+ {
+ String name = ((Element) ctx).getAttribute("name");
+ combine = (String) defineCombines.get(name);
+ String c = ((Element) ctx).getAttribute("combine");
+ if (combine != null && !combine.equals(c))
+ throw new GrammarException("multiple define " +
+ "elements with name '"+
+ name + "' but no " +
+ "combine attribute");
+ defineCombines.put(name, c);
+ nodes = (List) defines.get(name);
+ if (nodes == null)
+ {
+ nodes = new LinkedList();
+ defines.put(name, nodes);
+ }
+ nodes.add(ctx);
+ }
+ ctx = next;
+ }
+ for (Iterator i = defines.keySet().iterator(); i.hasNext(); )
+ {
+ String name = (String) i.next();
+ combine = (String) defineCombines.get(name);
+ nodes = (List) defines.get(name);
+ if (!nodes.isEmpty())
+ combineNodes(node, combine, "define", nodes);
+ }
+ }
+ // 4.9. ns attribute
+ if ("name".equals(elementName) ||
+ "nsName".equals(elementName) ||
+ "value".equals(elementName))
+ {
+ Element element = (Element) node;
+ String ns = element.getAttribute("ns");
+ if (ns == null)
+ {
+ Node ctx = parent;
+ while (ns == null && ctx != null &&
+ ctx.getNodeType() == Node.ELEMENT_NODE)
+ {
+ ns = ((Element) ctx).getAttribute("ns");
+ ctx = ctx.getParentNode();
+ }
+ element.setAttribute("ns", (ns == null) ? "" : ns);
+ }
+ if ("name".equals(elementName))
+ {
+ // 4.10. QNames
+ String name = element.getTextContent();
+ int ci = name.indexOf(':');
+ if (ci != -1)
+ {
+ String prefix = name.substring(0, ci);
+ element.setTextContent(name.substring(ci + 1));
+ ns = element.lookupNamespaceURI(prefix);
+ element.setAttribute("ns", (ns == null) ? "" : ns);
+ }
+ // 4.16. Constraints
+ if (isDescendantOfFirstChildOfAttribute(element) &&
+ "".equals(element.getAttribute("ns")) &&
+ "xmlns".equals(element.getTextContent()))
+ throw new GrammarException("name cannot be xmlns");
+ }
+ else if ("nsName".equals(elementName))
+ {
+ // 4.16. Constraints
+ if (isDescendantOfFirstChildOfAttribute(element) &&
+ "http://www.w3.org/2000/xmlns"
+ .equals(element.getAttribute("ns")))
+ throw new GrammarException("nsName cannot be XMLNS URI");
+ }
+ }
+ }
+
+ break;
+ case Node.TEXT_NODE:
+ case Node.CDATA_SECTION_NODE:
+ // 4.2 Whitespace
+ String parentName = parent.getLocalName();
+ if ("name".equals(parentName))
+ node.setNodeValue(node.getNodeValue().trim());
+ if (!"param".equals(parentName) &&
+ !"value".equals(parentName) &&
+ isWhitespace(node.getNodeValue()))
+ parent.removeChild(node);
+ break;
+ case Node.DOCUMENT_NODE:
+ break;
+ default:
+ parent.removeChild(node);
+ }
+ // Transform children
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ transform(ctx);
+ ctx = next;
+ }
+ }
+
+ /**
+ * Transforms the schema to place all defines under the top-level grammar
+ * element and replace all other grammar elements by their start child.
+ */
+ private void transformGrammar(Node grammar, Node node)
+ throws GrammarException
+ {
+ if (node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ String elementName = node.getLocalName();
+ if ("grammar".equals(elementName))
+ {
+ handleRefs(grammar, node, node);
+ Node start = null;
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ String childName = ctx.getLocalName();
+ if ("define".equals(childName))
+ grammar.appendChild(ctx);
+ else if ("start".equals(childName))
+ start = ctx;
+ ctx = next;
+ }
+ if (start == null)
+ throw new GrammarException("no start element for grammar");
+ Node p = getFirstChildElement(start);
+ Node parent = node.getParentNode();
+ parent.insertBefore(p, node);
+ parent.removeChild(node);
+ node = p;
+ }
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ transformGrammar(grammar, ctx);
+ ctx = next;
+ }
+ }
+ }
+
+ /**
+ * Checks that all references in the specified grammar match a define in
+ * the grammar.
+ */
+ private void handleRefs(Node grammar1, Node grammar2, Node node)
+ throws GrammarException
+ {
+ if (node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ String elementName = node.getLocalName();
+ if ("ref".equals(elementName) || "parentRef".equals(elementName))
+ {
+ Node grammar = grammar2;
+ if ("parentRef".equals(elementName))
+ grammar = grammar1;
+
+ String name = ((Element) node).getAttribute("name");
+ if (name != null)
+ throw new GrammarException("no name attribute on " +
+ elementName);
+ Node define = null;
+ for (Node ctx = grammar.getFirstChild();
+ define == null && ctx != null;
+ ctx = ctx.getNextSibling())
+ {
+ if ("define".equals(ctx.getLocalName()))
+ {
+ String dname = ((Element) ctx).getAttribute("name");
+ if (name.equals(dname))
+ define = ctx;
+ }
+ }
+ if (define == null)
+ throw new GrammarException("no define for '" + name + "'");
+ name = ((Element) define).getAttribute("new-name");
+ if (name == null)
+ {
+ name = createRefName();
+ ((Element) define).setAttribute("new-name", name);
+ }
+ if ("parentRef".equals(elementName))
+ {
+ Document doc = node.getOwnerDocument();
+ Node ref = doc.createElementNS(XMLConstants.RELAXNG_NS_URI,
+ "ref");
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ ref.appendChild(ctx);
+ ctx = next;
+ }
+ Node parent = node.getParentNode();
+ parent.insertBefore(ref, node);
+ parent.removeChild(node);
+ node = ref;
+ }
+ ((Element) node).setAttribute("name", name);
+ }
+ else if ("grammar".equals(elementName))
+ {
+ grammar1 = grammar2;
+ grammar2 = node;
+ }
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ handleRefs(grammar1, grammar2, ctx);
+ ctx = next;
+ }
+ }
+ }
+
+ private String createRefName()
+ {
+ return "ref" + Integer.toString(refCount++);
+ }
+
+ private void transform2(Node node)
+ throws GrammarException
+ {
+ Node parent = node.getParentNode();
+ if (node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ String elementName = node.getLocalName();
+ // 4.20. notAllowed element
+ if ("notAllowed".equals(elementName))
+ {
+ String parentName = parent.getLocalName();
+ if ("attribute".equals(parentName) ||
+ "list".equals(parentName) ||
+ "group".equals(parentName) ||
+ "interleave".equals(parentName) ||
+ "oneOrMore".equals(parentName))
+ {
+ Node pp = parent.getParentNode();
+ pp.insertBefore(node, parent);
+ pp.removeChild(parent);
+ transform2(node); // apply recursively
+ return;
+ }
+ else if ("choice".equals(parentName))
+ {
+ Node p1 = getFirstChildElement(parent);
+ Node p2 = getNextSiblingElement(p1);
+ if (p1 == null || p2 == null)
+ throw new GrammarException("choice does not have two " +
+ "children");
+ String p1Name = p1.getLocalName();
+ String p2Name = p2.getLocalName();
+ Node pp = parent.getParentNode();
+ if ("notAllowed".equals(p1Name) &&
+ "notAllowed".equals(p2Name))
+ {
+ pp.insertBefore(p1, parent);
+ pp.removeChild(parent);
+ transform2(p1); //apply recursively
+ return;
+ }
+ else if ("notAllowed".equals(p1Name))
+ {
+ pp.insertBefore(p2, parent);
+ pp.removeChild(parent);
+ transform2(p2);
+ return;
+ }
+ else
+ {
+ pp.insertBefore(p1, parent);
+ pp.removeChild(parent);
+ transform2(p1);
+ return;
+ }
+ }
+ else if ("except".equals(parentName))
+ {
+ Node pp = parent.getParentNode();
+ pp.removeChild(parent);
+ return;
+ }
+ }
+ // 4.21. empty element
+ else if ("empty".equals(elementName))
+ {
+ String parentName = parent.getLocalName();
+ if ("group".equals(parentName) ||
+ "interleave".equals(parentName))
+ {
+ Node p1 = getFirstChildElement(parent);
+ Node p2 = getNextSiblingElement(p1);
+ if (p1 == null || p2 == null)
+ throw new GrammarException(parentName + " does not have " +
+ "two children");
+ String p1Name = p1.getLocalName();
+ String p2Name = p2.getLocalName();
+ Node pp = parent.getParentNode();
+ if ("empty".equals(p1Name) &&
+ "empty".equals(p2Name))
+ {
+ pp.insertBefore(p1, parent);
+ pp.removeChild(parent);
+ transform2(p1);
+ return;
+ }
+ else if ("empty".equals(p1Name))
+ {
+ pp.insertBefore(p2, parent);
+ pp.removeChild(parent);
+ transform2(p2);
+ return;
+ }
+ else
+ {
+ pp.insertBefore(p1, parent);
+ pp.removeChild(parent);
+ transform2(p1);
+ return;
+ }
+ }
+ else if ("choice".equals(parentName))
+ {
+ Node p1 = getFirstChildElement(parent);
+ Node p2 = getNextSiblingElement(p1);
+ if (p1 == null || p2 == null)
+ throw new GrammarException(parentName + " does not have " +
+ "two children");
+ String p1Name = p1.getLocalName();
+ String p2Name = p2.getLocalName();
+ Node pp = parent.getParentNode();
+ if ("empty".equals(p1Name) &&
+ "empty".equals(p2Name))
+ {
+ pp.insertBefore(p1, parent);
+ pp.removeChild(parent);
+ transform2(p1);
+ return;
+ }
+ }
+ else if ("oneOrMore".equals(parentName))
+ {
+ Node pp = parent.getParentNode();
+ pp.insertBefore(node, parent);
+ pp.removeChild(parent);
+ transform2(node);
+ return;
+ }
+ }
+ Node ctx = node.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ transform2(ctx);
+ ctx = next;
+ }
+ }
+ }
+
+ private static boolean isWhitespace(String text)
+ {
+ int len = text.length();
+ for (int i = 0; i < len; i++)
+ {
+ char c = text.charAt(i);
+ if (c != ' ' && c != '\t' && c != '\n' && c != '\r')
+ return false;
+ }
+ return true;
+ }
+
+ private static String escapeURL(String url)
+ {
+ try
+ {
+ return URLEncoder.encode(url, "UTF-8");
+ }
+ catch (UnsupportedEncodingException e)
+ {
+ RuntimeException e2 = new RuntimeException("UTF-8 is unsupported");
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+ /**
+ * Resolve a URL to an element, as described in section 4.5.
+ */
+ private static Element resolve(String url)
+ throws IOException
+ {
+ try
+ {
+ URL u = new URL(url);
+ InputStream in = u.openStream();
+ DocumentBuilderFactory f = DocumentBuilderFactory.newInstance();
+ f.setNamespaceAware(true);
+ f.setCoalescing(true);
+ f.setExpandEntityReferences(true);
+ f.setIgnoringComments(true);
+ f.setIgnoringElementContentWhitespace(true);
+ DocumentBuilder b = f.newDocumentBuilder();
+ Document doc = b.parse(in, url);
+ in.close();
+ String fragment = u.getRef();
+ if (fragment != null)
+ return doc.getElementById(fragment);
+ return doc.getDocumentElement();
+ }
+ catch (SAXException e)
+ {
+ IOException e2 = new IOException("error parsing included element");
+ e2.initCause(e);
+ throw e2;
+ }
+ catch (ParserConfigurationException e)
+ {
+ IOException e2 = new IOException("error parsing included element");
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+ /**
+ * Returns the "components" of an element, as described in section 4.7.
+ */
+ private List getComponents(Node node)
+ {
+ List ret = new LinkedList();
+ for (Node ctx = node.getFirstChild(); ctx != null;
+ ctx = ctx.getNextSibling())
+ {
+ if (ctx.getNodeType() != Node.ELEMENT_NODE)
+ continue;
+ String ns = ctx.getNamespaceURI();
+ if (ns != null && !ns.equals(XMLConstants.RELAXNG_NS_URI))
+ continue;
+ String name = ctx.getLocalName();
+ if ("div".equals(name))
+ ret.addAll(getComponents(ctx));
+ else if (VOCABULARY.containsKey(name))
+ ret.add(ctx);
+ }
+ return ret;
+ }
+
+ private static void transformToOneChildElement(Node node, String name)
+ {
+ if (node.getChildNodes().getLength() < 2)
+ return;
+ Document doc = node.getOwnerDocument();
+ Element child = doc.createElementNS(XMLConstants.RELAXNG_NS_URI, name);
+ Node ctx = getFirstChildElement(node);
+ while (ctx != null)
+ {
+ Node next = getNextSiblingElement(ctx);
+ child.appendChild(ctx);
+ ctx = next;
+ }
+ node.appendChild(child);
+ }
+
+ private static Element getFirstChildElement(Node node)
+ {
+ Node ctx = node.getFirstChild();
+ while (ctx != null && ctx.getNodeType() != Node.ELEMENT_NODE)
+ ctx = ctx.getNextSibling();
+ return (Element) ctx;
+ }
+
+ private static Element getNextSiblingElement(Node node)
+ {
+ Node ctx = node.getNextSibling();
+ while (ctx != null && ctx.getNodeType() != Node.ELEMENT_NODE)
+ ctx = ctx.getNextSibling();
+ return (Element) ctx;
+ }
+
+ private static void forbidDescendants(Node node, Set names)
+ throws GrammarException
+ {
+ for (Node ctx = node.getFirstChild(); ctx != null;
+ ctx = ctx.getNextSibling())
+ {
+ String ns = ctx.getNamespaceURI();
+ if (!XMLConstants.RELAXNG_NS_URI.equals(ns))
+ continue;
+ String name = ctx.getLocalName();
+ if (names.contains(name))
+ throw new GrammarException("name not allowed: " + name);
+ forbidDescendants(ctx, names);
+ }
+ }
+
+ private static boolean isDescendantOfFirstChildOfAttribute(Node node)
+ {
+ Node child = node;
+ Node parent = node.getParentNode();
+ while (parent != null && !"attribute".equals(parent.getLocalName()))
+ {
+ child = parent;
+ parent = child.getParentNode();
+ }
+ if (parent == null)
+ return false;
+ Node firstChild = getFirstChildElement(parent);
+ return firstChild == child;
+ }
+
+ private static void combineNodes(Node node, String combine, String name,
+ List nodes)
+ {
+ Document doc = node.getOwnerDocument();
+ Node child =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, name);
+ Node combineNode =
+ doc.createElementNS(XMLConstants.RELAXNG_NS_URI, combine);
+ child.appendChild(combineNode);
+ boolean inserted = false;
+ for (Iterator i = nodes.iterator(); i.hasNext(); )
+ {
+ Node startNode = (Node) i.next();
+ if (!inserted)
+ {
+ node.insertBefore(child, startNode);
+ inserted = true;
+ }
+ Node ctx = startNode.getFirstChild();
+ while (ctx != null)
+ {
+ Node next = ctx.getNextSibling();
+ combineNode.appendChild(ctx);
+ ctx = next;
+ }
+ node.removeChild(startNode);
+ }
+ }
+
+ Grammar parseGrammar(Element node)
+ throws GrammarException
+ {
+ checkName(node, "grammar");
+ Grammar grammar = new Grammar();
+ Element start = getFirstChildElement(node);
+ grammar.start = parsePattern(getFirstChildElement(start));
+ for (Element define = getNextSiblingElement(start); define != null;
+ define = getNextSiblingElement(define))
+ grammar.defines.add(parseDefine(define));
+ return grammar;
+ }
+
+ Define parseDefine(Element node)
+ throws GrammarException
+ {
+ checkName(node, "define");
+ Define define = new Define();
+ define.name = node.getAttribute("name");
+ define.element = parseElement(getFirstChildElement(node));
+ return define;
+ }
+
+ Pattern parseTop(Element node)
+ throws GrammarException
+ {
+ String name = node.getLocalName();
+ if ("notAllowed".equals(name))
+ return parseNotAllowed(node);
+ return parsePattern(node);
+ }
+
+ Pattern parsePattern(Element node)
+ throws GrammarException
+ {
+ String name = node.getLocalName();
+ if ("empty".equals(name))
+ return parseEmpty(node);
+ return parseNonEmptyPattern(node);
+ }
+
+ Pattern parseNonEmptyPattern(Element node)
+ throws GrammarException
+ {
+ String name = node.getLocalName();
+ if ("text".equals(name))
+ return parseText(node);
+ else if ("data".equals(name))
+ return parseData(node);
+ else if ("value".equals(name))
+ return parseValue(node);
+ else if ("list".equals(name))
+ return parseList(node);
+ else if ("attribute".equals(name))
+ return parseAttribute(node);
+ else if ("ref".equals(name))
+ return parseRef(node);
+ else if ("oneOrMore".equals(name))
+ return parseOneOrMore(node);
+ else if ("choice".equals(name))
+ return parseChoice(node);
+ else if ("group".equals(name))
+ return parseGroup(node);
+ else if ("interleave".equals(name))
+ return parseInterleave(node);
+ throw new GrammarException("invalid pattern: " + name);
+ }
+
+ ElementPattern parseElement(Element node)
+ throws GrammarException
+ {
+ checkName(node, "element");
+ ElementPattern element = new ElementPattern();
+ Element nameClass = getFirstChildElement(node);
+ element.nameClass = parseNameClass(nameClass);
+ element.pattern = parseTop(getNextSiblingElement(nameClass));
+ return element;
+ }
+
+ NotAllowedPattern parseNotAllowed(Element node)
+ throws GrammarException
+ {
+ checkName(node, "notAllowed");
+ return NotAllowedPattern.INSTANCE;
+ }
+
+ EmptyPattern parseEmpty(Element node)
+ throws GrammarException
+ {
+ checkName(node, "empty");
+ return EmptyPattern.INSTANCE;
+ }
+
+ TextPattern parseText(Element node)
+ throws GrammarException
+ {
+ checkName(node, "text");
+ return TextPattern.INSTANCE;
+ }
+
+ DataPattern parseData(Element node)
+ throws GrammarException
+ {
+ checkName(node, "data");
+ DataPattern data = new DataPattern();
+ DatatypeLibrary dl =
+ getDatatypeLibrary(node.getAttribute("datatypeLibrary"));
+ String type = node.getAttribute("type");
+ try
+ {
+ data.type = dl.createDatatype(type);
+ data.datatypeLibrary = dl;
+ }
+ catch (DatatypeException e)
+ {
+ GrammarException e2 = new GrammarException(type);
+ e2.initCause(e);
+ throw e2;
+ }
+ Element ctx = getFirstChildElement(node);
+ while (ctx != null)
+ {
+ Element next = getNextSiblingElement(ctx);
+ String name = ctx.getLocalName();
+ if ("param".equals(name))
+ data.params.add(parseParam(ctx));
+ else if ("except".equals(name) && next == null)
+ data.exceptPattern = parsePattern(getFirstChildElement(ctx));
+ else
+ throw new GrammarException("invalid element: " + name);
+ ctx = next;
+ }
+ return data;
+ }
+
+ Param parseParam(Element node)
+ throws GrammarException
+ {
+ checkName(node, "param");
+ Param param = new Param();
+ param.name = node.getAttribute("name");
+ param.value = node.getTextContent();
+ return param;
+ }
+
+ ValuePattern parseValue(Element node)
+ throws GrammarException
+ {
+ checkName(node, "value");
+ ValuePattern value = new ValuePattern();
+ DatatypeLibrary dl =
+ getDatatypeLibrary(node.getAttribute("datatypeLibrary"));
+ String type = node.getAttribute("type");
+ try
+ {
+ value.type = dl.createDatatype(type);
+ value.datatypeLibrary = dl;
+ }
+ catch (DatatypeException e)
+ {
+ GrammarException e2 = new GrammarException(type);
+ e2.initCause(e);
+ throw e2;
+ }
+ value.ns = node.getAttribute("ns");
+ value.value = node.getTextContent();
+ return value;
+ }
+
+ ListPattern parseList(Element node)
+ throws GrammarException
+ {
+ checkName(node, "list");
+ ListPattern list = new ListPattern();
+ list.pattern = parsePattern(getFirstChildElement(node));
+ return list;
+ }
+
+ AttributePattern parseAttribute(Element node)
+ throws GrammarException
+ {
+ checkName(node, "attribute");
+ AttributePattern attribute = new AttributePattern();
+ Element nameClass = getFirstChildElement(node);
+ attribute.nameClass = parseNameClass(nameClass);
+ attribute.pattern = parsePattern(getNextSiblingElement(nameClass));
+ return attribute;
+ }
+
+ RefPattern parseRef(Element node)
+ throws GrammarException
+ {
+ checkName(node, "ref");
+ RefPattern ref = new RefPattern();
+ ref.name = node.getAttribute("name");
+ return ref;
+ }
+
+ OneOrMorePattern parseOneOrMore(Element node)
+ throws GrammarException
+ {
+ checkName(node, "oneOrMore");
+ OneOrMorePattern oneOrMore = new OneOrMorePattern();
+ oneOrMore.pattern = parseNonEmptyPattern(getFirstChildElement(node));
+ return oneOrMore;
+ }
+
+ ChoicePattern parseChoice(Element node)
+ throws GrammarException
+ {
+ checkName(node, "choice");
+ ChoicePattern choice = new ChoicePattern();
+ Element p1 = getFirstChildElement(node);
+ Element p2 = getNextSiblingElement(p1);
+ choice.pattern1 = parsePattern(p1);
+ choice.pattern2 = parseNonEmptyPattern(p2);
+ return choice;
+ }
+
+ GroupPattern parseGroup(Element node)
+ throws GrammarException
+ {
+ checkName(node, "group");
+ GroupPattern group = new GroupPattern();
+ Element p1 = getFirstChildElement(node);
+ Element p2 = getNextSiblingElement(p1);
+ group.pattern1 = parseNonEmptyPattern(p1);
+ group.pattern2 = parseNonEmptyPattern(p2);
+ return group;
+ }
+
+ InterleavePattern parseInterleave(Element node)
+ throws GrammarException
+ {
+ checkName(node, "interleave");
+ InterleavePattern interleave = new InterleavePattern();
+ Element p1 = getFirstChildElement(node);
+ Element p2 = getNextSiblingElement(p1);
+ interleave.pattern1 = parseNonEmptyPattern(p1);
+ interleave.pattern2 = parseNonEmptyPattern(p2);
+ return interleave;
+ }
+
+ NameClass parseNameClass(Element node)
+ throws GrammarException
+ {
+ String name = node.getLocalName();
+ if ("anyName".equals(name))
+ return parseAnyName(node);
+ else if ("name".equals(name))
+ return parseName(node);
+ else if ("nsName".equals(name))
+ return parseNsName(node);
+ else if ("choice".equals(name))
+ return parseChoiceNameClass(node);
+ throw new GrammarException("invalid name class: " + name);
+ }
+
+ AnyNameNameClass parseAnyName(Element node)
+ throws GrammarException
+ {
+ checkName(node, "anyName");
+ AnyNameNameClass anyName = new AnyNameNameClass();
+ Element except = getFirstChildElement(node);
+ if (except != null) {
+ checkName(except, "except");
+ anyName.exceptNameClass = parseNameClass(getFirstChildElement(except));
+ }
+ return anyName;
+ }
+
+ NameNameClass parseName(Element node)
+ throws GrammarException
+ {
+ checkName(node, "name");
+ NameNameClass name = new NameNameClass();
+ name.ns = node.getAttribute("ns");
+ name.name = node.getTextContent();
+ return name;
+ }
+
+ NSNameNameClass parseNsName(Element node)
+ throws GrammarException
+ {
+ checkName(node, "nsName");
+ NSNameNameClass nsName = new NSNameNameClass();
+ nsName.ns = node.getAttribute("ns");
+ Element except = getFirstChildElement(node);
+ if (except != null) {
+ checkName(except, "except");
+ nsName.exceptNameClass = parseNameClass(getFirstChildElement(except));
+ }
+ return nsName;
+ }
+
+ ChoiceNameClass parseChoiceNameClass(Element node)
+ throws GrammarException
+ {
+ checkName(node, "choice");
+ ChoiceNameClass choice = new ChoiceNameClass();
+ Element c1 = getFirstChildElement(node);
+ Element c2 = getNextSiblingElement(c1);
+ choice.name1 = parseNameClass(c1);
+ choice.name2 = parseNameClass(c2);
+ return choice;
+ }
+
+ void checkName(Element node, String name)
+ throws GrammarException
+ {
+ if (!name.equals(node.getLocalName()))
+ throw new GrammarException("expecting " + name);
+ }
+
+ DatatypeLibrary getDatatypeLibrary(String uri)
+ throws GrammarException
+ {
+ if (datatypeLibraries == null)
+ datatypeLibraries = new HashMap();
+ DatatypeLibrary library = (DatatypeLibrary) datatypeLibraries.get(uri);
+ if (library == null)
+ {
+ library = new DatatypeLibraryLoader().createDatatypeLibrary(uri);
+ if (library == null)
+ throw new GrammarException("Datatype library not supported: " + uri);
+ datatypeLibraries.put(uri, library);
+ }
+ return library;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Grammar.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Grammar.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Grammar.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Grammar.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,70 @@
+/* Grammar.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.util.LinkedList;
+import java.util.List;
+import javax.xml.validation.Schema;
+import javax.xml.validation.Validator;
+import javax.xml.validation.ValidatorHandler;
+
+/**
+ * A RELAX NG grammar.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class Grammar
+ extends Schema
+{
+
+ Pattern start;
+ List defines = new LinkedList();
+
+ public Validator newValidator()
+ {
+ return new GrammarValidator(this);
+ }
+
+ public ValidatorHandler newValidatorHandler()
+ {
+ // TODO
+ return null;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarException.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarException.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarException.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarException.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,56 @@
+/* GrammarException.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.io.IOException;
+
+/**
+ * Exception parsing a grammar.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class GrammarException
+ extends IOException
+{
+
+ GrammarException(String message)
+ {
+ super(message);
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarValidator.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarValidator.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarValidator.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GrammarValidator.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,97 @@
+/* GrammarValidator.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.io.IOException;
+import javax.xml.transform.Source;
+import javax.xml.transform.Result;
+import javax.xml.validation.Validator;
+import org.w3c.dom.ls.LSResourceResolver;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.SAXException;
+
+/**
+ * RELAX NG validator.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class GrammarValidator
+ extends Validator
+{
+
+ final Grammar grammar;
+ ErrorHandler errorHandler;
+ LSResourceResolver resourceResolver;
+
+ GrammarValidator(Grammar grammar)
+ {
+ this.grammar = grammar;
+ }
+
+ public ErrorHandler getErrorHandler()
+ {
+ return errorHandler;
+ }
+
+ public void setErrorHandler(ErrorHandler errorHandler)
+ {
+ this.errorHandler = errorHandler;
+ }
+
+ public LSResourceResolver getResourceResolver()
+ {
+ return resourceResolver;
+ }
+
+ public void setResourceResolver(LSResourceResolver resourceResolver)
+ {
+ this.resourceResolver = resourceResolver;
+ }
+
+ public void reset()
+ {
+ // TODO
+ }
+
+ public void validate(Source source, Result result)
+ throws SAXException, IOException
+ {
+ // TODO
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GroupPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GroupPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GroupPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/GroupPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* GroupPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG group element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class GroupPattern
+ extends Pattern
+{
+
+ Pattern pattern1;
+ Pattern pattern2;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/InterleavePattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/InterleavePattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/InterleavePattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/InterleavePattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* InterleavePattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG interleave element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class InterleavePattern
+ extends Pattern
+{
+
+ Pattern pattern1;
+ Pattern pattern2;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ListPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ListPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ListPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ListPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* ListPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG list element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ListPattern
+ extends Pattern
+{
+
+ Pattern pattern;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NSNameNameClass.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NSNameNameClass.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NSNameNameClass.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NSNameNameClass.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,61 @@
+/* NSNameNameClass.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG nsName element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class NSNameNameClass
+ extends NameClass
+{
+
+ String ns;
+ NameClass exceptNameClass;
+
+ boolean matchesName(String uri, String localName)
+ {
+ if (!ns.equals(uri))
+ return false;
+ return (exceptNameClass == null) ? true :
+ !exceptNameClass.matchesName(uri, localName);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameClass.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameClass.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameClass.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameClass.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,50 @@
+/* NameClass.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG name class.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+abstract class NameClass
+{
+
+ abstract boolean matchesName(String uri, String localName);
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameNameClass.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameNameClass.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameNameClass.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NameNameClass.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,60 @@
+/* NameNameClass.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG name element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class NameNameClass
+ extends NameClass
+{
+
+ String ns;
+ String name;
+
+ boolean matchesName(String uri, String localName)
+ {
+ if (!ns.equals(uri))
+ return false;
+ return name.equals(localName);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NotAllowedPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NotAllowedPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NotAllowedPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/NotAllowedPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,53 @@
+/* NotAllowedPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG notAllowed element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class NotAllowedPattern
+ extends Pattern
+{
+
+ static final NotAllowedPattern INSTANCE = new NotAllowedPattern();
+
+}
+
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/OneOrMorePattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/OneOrMorePattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/OneOrMorePattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/OneOrMorePattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* OneOrMorePattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG oneOrMore element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class OneOrMorePattern
+ extends Pattern
+{
+
+ Pattern pattern;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Param.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Param.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Param.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Param.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* Param.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG param element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class Param
+{
+
+ String name;
+ String value;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Pattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Pattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Pattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/Pattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,48 @@
+/* Pattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG pattern.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+abstract class Pattern
+{
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RELAXNGSchemaFactory.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RELAXNGSchemaFactory.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RELAXNGSchemaFactory.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RELAXNGSchemaFactory.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,163 @@
+/* RelaxNGSchemaFactory.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import java.io.IOException;
+import java.net.URL;
+import javax.xml.XMLConstants;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.transform.Source;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamSource;
+import javax.xml.validation.Schema;
+import javax.xml.validation.SchemaFactory;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.ls.LSResourceResolver;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * Schema factory for RELAX NG grammars.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class RELAXNGSchemaFactory
+ extends SchemaFactory
+{
+
+ LSResourceResolver resourceResolver;
+ ErrorHandler errorHandler;
+
+ public LSResourceResolver getResourceResolver()
+ {
+ return resourceResolver;
+ }
+
+ public void setResourceResolver(LSResourceResolver resourceResolver)
+ {
+ this.resourceResolver = resourceResolver;
+ }
+
+ public ErrorHandler getErrorHandler()
+ {
+ return this.errorHandler;
+ }
+
+ public void setErrorHandler(ErrorHandler errorHandler)
+ {
+ this.errorHandler = errorHandler;
+ }
+
+ public boolean isSchemaLanguageSupported(String schemaLanguage)
+ {
+ return XMLConstants.RELAXNG_NS_URI.equals(schemaLanguage);
+ }
+
+ public Schema newSchema()
+ throws SAXException
+ {
+ // TODO
+ throw new UnsupportedOperationException();
+ }
+
+ public Schema newSchema(Source[] schemata)
+ throws SAXException
+ {
+ if (schemata == null || schemata.length != 1)
+ throw new IllegalArgumentException("must specify one source");
+ // TODO multiple schemata
+ // TODO compact syntax
+ try
+ {
+ Document doc = getDocument(schemata[0]);
+ FullSyntaxBuilder builder = new FullSyntaxBuilder();
+ return builder.parse(doc);
+ }
+ catch (IOException e)
+ {
+ SAXException e2 = new SAXException(e.getMessage());
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+ private static Document getDocument(Source source)
+ throws SAXException, IOException
+ {
+ if (source instanceof DOMSource)
+ {
+ Node node = ((DOMSource) source).getNode();
+ if (node != null && node instanceof Document)
+ return (Document) node;
+ }
+ String url = source.getSystemId();
+ try
+ {
+ InputSource input = new InputSource(url);
+ if (source instanceof StreamSource)
+ {
+ StreamSource streamSource = (StreamSource) source;
+ input.setByteStream(streamSource.getInputStream());
+ input.setCharacterStream(streamSource.getReader());
+ }
+ if (input.getByteStream() == null &&
+ input.getCharacterStream() == null &&
+ url != null)
+ input.setByteStream(new URL(url).openStream());
+ DocumentBuilderFactory f = DocumentBuilderFactory.newInstance();
+ f.setNamespaceAware(true);
+ f.setCoalescing(true);
+ f.setExpandEntityReferences(true);
+ f.setIgnoringComments(true);
+ f.setIgnoringElementContentWhitespace(true);
+ DocumentBuilder b = f.newDocumentBuilder();
+ return b.parse(input);
+ }
+ catch (ParserConfigurationException e)
+ {
+ SAXException e2 = new SAXException(e.getMessage());
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RefPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RefPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RefPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/RefPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* RefPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG ref element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class RefPattern
+ extends Pattern
+{
+
+ String name;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/TextPattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/TextPattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/TextPattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/TextPattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* TextPattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+/**
+ * A RELAX NG text element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class TextPattern
+ extends Pattern
+{
+
+ static final TextPattern INSTANCE = new TextPattern();
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ValuePattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ValuePattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ValuePattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/relaxng/ValuePattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,58 @@
+/* ValuePattern.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.relaxng;
+
+import org.relaxng.datatype.Datatype;
+import org.relaxng.datatype.DatatypeLibrary;
+
+/**
+ * A RELAX NG value element.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ValuePattern
+ extends Pattern
+{
+
+ DatatypeLibrary datatypeLibrary;
+ Datatype type;
+ String ns;
+ String value;
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AnyAttribute.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AnyAttribute.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AnyAttribute.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AnyAttribute.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,67 @@
+/* AnyAttribute.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import gnu.xml.validation.datatype.Annotation;
+
+/**
+ * An attribute wildcard.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class AnyAttribute
+{
+
+ static final int STRICT = 0;
+ static final int LAX = 1;
+ static final int SKIP = 2;
+
+ final String namespace;
+
+ final int processContents;
+
+ Annotation annotation;
+
+ AnyAttribute(String namespace, int processContents)
+ {
+ this.namespace = namespace;
+ this.processContents = processContents;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeDeclaration.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeDeclaration.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeDeclaration.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeDeclaration.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,99 @@
+/* AttributeDeclaration.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import gnu.xml.validation.datatype.Annotation;
+import gnu.xml.validation.datatype.SimpleType;
+import javax.xml.namespace.QName;
+
+/**
+ * An XML Schema attribute declaration schema component.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class AttributeDeclaration
+{
+
+ static final int NONE = 0;
+ static final int DEFAULT = 1;
+ static final int FIXED = 2;
+
+ /**
+ * The scope of this attribute declaration (global or local).
+ */
+ final boolean scope;
+
+ /**
+ * The constraint type.
+ * One of NONE, DEFAULT, FIXED.
+ */
+ final int type;
+
+ /**
+ * The value constraint.
+ */
+ final String value;
+
+ /**
+ * The name of the attribute to which this declaration refers.
+ */
+ final QName name;
+
+ /**
+ * The type definition corresponding to this attribute.
+ */
+ final SimpleType datatype;
+
+ /**
+ * The annotation associated with this attribute declaration, if any.
+ */
+ final Annotation annotation;
+
+ AttributeDeclaration(boolean scope, int type, String value, QName name,
+ SimpleType datatype, Annotation annotation)
+ {
+ this.scope = scope;
+ this.type = type;
+ this.value = value;
+ this.name = name;
+ this.datatype = datatype;
+ this.annotation = annotation;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeUse.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeUse.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeUse.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/AttributeUse.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,79 @@
+/* AttributeUse.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+/**
+ * An XML Schema attribute use schema component.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class AttributeUse
+{
+
+ /**
+ * Whether the attribute is required.
+ */
+ final boolean required;
+
+ /**
+ * The constraint type.
+ * One of NONE, DEFAULT, FIXED.
+ */
+ final int type;
+
+ /**
+ * The value constraint.
+ */
+ final String value;
+
+ /**
+ * The name of the attribute to which this declaration refers.
+ */
+ final AttributeDeclaration declaration;
+
+ AttributeUse(boolean required, int type, String value,
+ AttributeDeclaration declaration)
+ {
+ this.required = required;
+ this.type = type;
+ this.value = value;
+ this.declaration = declaration;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ComplexType.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ComplexType.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ComplexType.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ComplexType.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,102 @@
+/* ComplexType.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.util.LinkedHashSet;
+import java.util.Set;
+import javax.xml.namespace.QName;
+import gnu.xml.validation.datatype.Type;
+
+/**
+ * A complex type definition.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ComplexType
+ extends Type
+{
+
+ /**
+ * Either a simple type definition or a complex type definition.
+ */
+ QName baseType;
+
+ /**
+ * Either EXTENSION or RESTRICTION.
+ */
+ int derivationMethod;
+
+ /**
+ * A subset of {EXTENSION, RESTRICTION}.
+ */
+ final int finality;
+
+ final boolean isAbstract;
+
+ Set attributeUses;
+
+ AnyAttribute attributeWildcard;
+
+ /**
+ * One of EMPTY, SIMPLE, MIXED, or ELEMENT_ONLY.
+ */
+ int contentType;
+
+ /**
+ * A simple type definition or a Particle.
+ */
+ Object contentModel;
+
+ final int prohibitedSubstitutions;
+
+ Set annotations;
+
+ ComplexType(QName name,
+ boolean isAbstract,
+ int prohibitedSubstitutions,
+ int finality)
+ {
+ super(name);
+ this.isAbstract = isAbstract;
+ this.prohibitedSubstitutions = prohibitedSubstitutions;
+ this.finality = finality;
+ attributeUses = new LinkedHashSet();
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ElementDeclaration.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ElementDeclaration.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ElementDeclaration.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ElementDeclaration.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,125 @@
+/* ElementDeclaration.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import gnu.xml.validation.datatype.Annotation;
+import gnu.xml.validation.datatype.Type;
+import javax.xml.namespace.QName;
+
+/**
+ * An XML Schema element declaration schema component.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ElementDeclaration
+{
+
+ /**
+ * The name of the element to which this declaration refers.
+ */
+ final QName name;
+
+ /**
+ * The type definition corresponding to this element.
+ */
+ Type datatype;
+
+ /**
+ * The scope of this schema component.
+ * One of GLOBAL, LOCAL, or ABSENT.
+ */
+ final int scope;
+
+ /**
+ * If scope is LOCAL, the parent element definition.
+ */
+ final ElementDeclaration parent;
+
+ /**
+ * The constraint type.
+ * One of NONE, DEFAULT, FIXED.
+ */
+ final int type;
+
+ /**
+ * The value constraint.
+ */
+ final String value;
+
+ final boolean nillable;
+
+ // TODO identity-constraint definitions
+
+ final QName substitutionGroup;
+
+ final int substitutionGroupExclusions;
+
+ final int disallowedSubstitutions;
+
+ final boolean isAbstract;
+
+ /**
+ * The annotation associated with this attribute declaration, if any.
+ */
+ Annotation annotation;
+
+ ElementDeclaration(QName name,
+ Type datatype,
+ int scope, ElementDeclaration parent,
+ int type, String value,
+ boolean nillable,
+ QName substitutionGroup,
+ int substitutionGroupExclusions,
+ int disallowedSubstitutions,
+ boolean isAbstract)
+ {
+ this.name = name;
+ this.datatype = datatype;
+ this.scope = scope;
+ this.parent = parent;
+ this.type = type;
+ this.value = value;
+ this.nillable = nillable;
+ this.substitutionGroup = substitutionGroup;
+ this.substitutionGroupExclusions = substitutionGroupExclusions;
+ this.disallowedSubstitutions = disallowedSubstitutions;
+ this.isAbstract = isAbstract;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/Particle.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/Particle.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/Particle.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/Particle.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,61 @@
+/* Particle.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+/**
+ * Container for element content.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class Particle
+{
+
+ final Integer minOccurs;
+ final Integer maxOccurs;
+
+ final Object term;
+
+ Particle(Integer minOccurs, Integer maxOccurs, Object term)
+ {
+ this.minOccurs = minOccurs;
+ this.maxOccurs = maxOccurs;
+ this.term = term;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ValidationException.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ValidationException.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ValidationException.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/ValidationException.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,58 @@
+/* ValidationException.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import org.xml.sax.Locator;
+import org.xml.sax.SAXParseException;
+
+/**
+ * An XML Schema validation rule violation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class ValidationException
+ extends SAXParseException
+{
+
+ ValidationException(String message, Locator locator)
+ {
+ super(message, locator);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchema.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchema.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchema.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchema.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,134 @@
+/* XMLSchema.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.util.LinkedHashMap;
+import java.util.Map;
+import javax.xml.validation.Schema;
+import javax.xml.validation.Validator;
+import javax.xml.validation.ValidatorHandler;
+
+/**
+ * An XML Schema schema.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchema
+ extends Schema
+{
+
+ static final int FINAL_NONE = 0x00;
+ static final int FINAL_EXTENSION = 0x01;
+ static final int FINAL_RESTRICTION = 0x02;
+ static final int FINAL_LIST = 0x04;
+ static final int FINAL_UNION = 0x08;
+ static final int FINAL_ALL = 0x0f;
+
+ static final int BLOCK_NONE = 0x00;
+ static final int BLOCK_EXTENSION = 0x01;
+ static final int BLOCK_RESTRICTION = 0x02;
+ static final int BLOCK_SUBSTITUTION = 0x04;
+ static final int BLOCK_ALL = 0x07;
+
+ static final int GLOBAL = 0x00;
+ static final int LOCAL = 0x01;
+ static final int ABSENT = 0x02;
+
+ static final int CONSTRAINT_NONE = 0x00;
+ static final int CONSTRAINT_DEFAULT = 0x01;
+ static final int CONSTRAINT_FIXED = 0x02;
+
+ static final int CONTENT_EMPTY = 0x00;
+ static final int CONTENT_SIMPLE = 0x01;
+ static final int CONTENT_MIXED = 0x02;
+ static final int CONTENT_ELEMENT_ONLY = 0x03;
+
+ final String targetNamespace;
+ final String version;
+ final int finalDefault;
+ final int blockDefault;
+ final boolean attributeFormQualified;
+ final boolean elementFormQualified;
+
+ /**
+ * The element declarations in this schema.
+ */
+ final Map elementDeclarations;
+
+ /**
+ * The attribute declarations in this schema.
+ */
+ final Map attributeDeclarations;
+
+ /**
+ * The type declarations in this schema.
+ */
+ final Map types;
+
+ XMLSchema(String targetNamespace, String version,
+ int finalDefault, int blockDefault,
+ boolean attributeFormQualified,
+ boolean elementFormQualified)
+ {
+ this.targetNamespace = targetNamespace;
+ this.version = version;
+ this.finalDefault = finalDefault;
+ this.blockDefault = blockDefault;
+ this.attributeFormQualified = attributeFormQualified;
+ this.elementFormQualified = elementFormQualified;
+ elementDeclarations = new LinkedHashMap();
+ attributeDeclarations = new LinkedHashMap();
+ types = new LinkedHashMap();
+ }
+
+ public Validator newValidator()
+ {
+ // TODO
+ //return new XMLSchemaValidator(this);
+ return null;
+ }
+
+ public ValidatorHandler newValidatorHandler()
+ {
+ // TODO
+ //return new XMLSchemaValidatorHandler(this);
+ return null;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaAttributeTypeInfo.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaAttributeTypeInfo.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaAttributeTypeInfo.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaAttributeTypeInfo.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,100 @@
+/* XMLSchemaAttributeTypeInfo.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import org.w3c.dom.TypeInfo;
+import gnu.xml.validation.datatype.SimpleType;
+
+/**
+ * Attribute type information provided by validation against an XML Schema.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchemaAttributeTypeInfo
+ extends XMLSchemaTypeInfo
+{
+
+ final XMLSchema schema;
+ final AttributeDeclaration decl;
+ final SimpleType type;
+ boolean id;
+ final boolean specified;
+
+ XMLSchemaAttributeTypeInfo(XMLSchema schema, AttributeDeclaration decl,
+ boolean specified)
+ {
+ this.schema = schema;
+ this.decl = decl;
+ this.specified = specified;
+ type = (decl == null) ? null : decl.datatype;
+ }
+
+ public String getTypeName()
+ {
+ if (type == null)
+ {
+ return "CDATA";
+ }
+ return type.name.getLocalPart();
+ }
+
+ public String getTypeNamespace()
+ {
+ if (type == null)
+ {
+ return "";
+ }
+ return type.name.getNamespaceURI();
+ }
+
+ public boolean isDerivedFrom(String typeNamespace, String typeName,
+ int derivationMethod)
+ {
+ if (type == null)
+ {
+ return false;
+ }
+ else
+ {
+ return simpleTypeIsDerivedFrom(type, typeNamespace, typeName,
+ derivationMethod);
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaBuilder.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaBuilder.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaBuilder.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaBuilder.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,844 @@
+/* XMLSchemaBuilder.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.util.LinkedHashSet;
+import java.util.List;
+import java.util.Set;
+import java.util.StringTokenizer;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.DatatypeLibrary;
+import org.relaxng.datatype.helpers.DatatypeLibraryLoader;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+import gnu.xml.validation.datatype.Annotation;
+import gnu.xml.validation.datatype.AtomicSimpleType;
+import gnu.xml.validation.datatype.ListSimpleType;
+import gnu.xml.validation.datatype.SimpleType;
+import gnu.xml.validation.datatype.Type;
+import gnu.xml.validation.datatype.UnionSimpleType;
+
+/**
+ * Parses an XML Schema DOM tree, constructing a compiled internal
+ * representation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class XMLSchemaBuilder
+{
+
+ XMLSchema schema;
+ final DatatypeLibrary typeLibrary;
+
+ XMLSchemaBuilder()
+ {
+ final String ns = XMLConstants.W3C_XML_SCHEMA_NS_URI;
+ typeLibrary = new DatatypeLibraryLoader().createDatatypeLibrary(ns);
+ }
+
+ void parseSchema(Node node)
+ throws DatatypeException
+ {
+ String uri = node.getNamespaceURI();
+ String name = node.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("schema".equals(name))
+ {
+ NamedNodeMap attrs = node.getAttributes();
+ String targetNamespace = getAttribute(attrs, "targetNamespace");
+ String version = getAttribute(attrs, "version");
+ String fd = getAttribute(attrs, "finalDefault");
+ int finalDefault = parseFullDerivationSet(fd);
+ String bd = getAttribute(attrs, "blockDefault");
+ int blockDefault = parseBlockSet(bd);
+ String afd = getAttribute(attrs, "attributeFormDefault");
+ boolean attributeFormQualified = "qualified".equals(afd);
+ String efd = getAttribute(attrs, "elementFormDefault");
+ boolean elementFormQualified = "qualified".equals(efd);
+ schema = new XMLSchema(targetNamespace, version,
+ finalDefault, blockDefault,
+ attributeFormQualified,
+ elementFormQualified);
+ for (Node child = node.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ parseTopLevelElement(child);
+ }
+ return;
+ }
+ }
+ // TODO throw schema exception
+ }
+
+ void parseTopLevelElement(Node node)
+ throws DatatypeException
+ {
+ String uri = node.getNamespaceURI();
+ String name = node.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("element".equals(name))
+ {
+ ElementDeclaration ed =
+ (ElementDeclaration) parseElement(node, null);
+ schema.elementDeclarations.put(ed.name, ed);
+ // TODO
+ }
+ else if ("attribute".equals(name))
+ {
+ AttributeDeclaration ad =
+ (AttributeDeclaration) parseAttribute(node, true);
+ schema.attributeDeclarations.put(ad.name, ad);
+ // TODO
+ }
+ else if ("type".equals(name))
+ {
+ // TODO
+ }
+ else if ("group".equals(name))
+ {
+ // TODO
+ }
+ else if ("attributeGroup".equals(name))
+ {
+ // TODO
+ }
+ else if ("notation".equals(name))
+ {
+ // TODO
+ }
+ else if ("identityConstraint".equals(name))
+ {
+ // TODO
+ }
+ }
+ // TODO throw schema exception
+ }
+
+ Object parseAttribute(Node node, boolean scope)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = node.getAttributes();
+ String def = getAttribute(attrs, "default");
+ String fixed = getAttribute(attrs, "fixed");
+ int constraintType = AttributeDeclaration.NONE;
+ String constraintValue = null;
+ if (def != null)
+ {
+ constraintType = AttributeDeclaration.DEFAULT;
+ constraintValue = def;
+ }
+ else if (fixed != null)
+ {
+ constraintType = AttributeDeclaration.FIXED;
+ constraintValue = fixed;
+ }
+ // TODO form = (qualified | unqualified)
+ String attrName = getAttribute(attrs, "name");
+ String attrNamespace = getAttribute(attrs, "targetNamespace");
+ String ref = getAttribute(attrs, "ref");
+ String use = getAttribute(attrs, "use");
+ String type = getAttribute(attrs, "type");
+ SimpleType datatype = (type == null) ? null :
+ parseSimpleType(asQName(type, node));
+ Annotation annotation = null;
+ for (Node child = node.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ annotation = parseAnnotation(child);
+ }
+ else if ("simpleType".equals(name))
+ {
+ datatype = parseSimpleType(child);
+ }
+ else
+ {
+ // TODO throw schema exception
+ }
+ }
+ }
+ if (scope)
+ {
+ return new AttributeDeclaration(scope,
+ constraintType,
+ constraintValue,
+ new QName(attrNamespace, attrName),
+ datatype,
+ annotation);
+ }
+ else
+ {
+ boolean required = "required".equals(use);
+ // TODO ref
+ AttributeDeclaration decl = (ref == null) ?
+ new AttributeDeclaration(scope,
+ AttributeDeclaration.NONE,
+ null,
+ new QName(attrNamespace, attrName),
+ datatype,
+ annotation) :
+ /*schema.getAttributeDeclaration(ref)*/ null;
+ return new AttributeUse(required,
+ constraintType,
+ constraintValue,
+ decl);
+ }
+ }
+
+ int parseFullDerivationSet(String value)
+ {
+ int ret = XMLSchema.FINAL_NONE;
+ if ("#all".equals(value))
+ {
+ ret = XMLSchema.FINAL_ALL;
+ }
+ else
+ {
+ StringTokenizer st = new StringTokenizer(value, " ");
+ while (st.hasMoreTokens())
+ {
+ String token = st.nextToken();
+ if ("extension".equals(token))
+ {
+ ret |= XMLSchema.FINAL_EXTENSION;
+ }
+ else if ("restriction".equals(token))
+ {
+ ret |= XMLSchema.FINAL_RESTRICTION;
+ }
+ else if ("list".equals(token))
+ {
+ ret |= XMLSchema.FINAL_LIST;
+ }
+ else if ("union".equals(token))
+ {
+ ret |= XMLSchema.FINAL_UNION;
+ }
+ }
+ }
+ return ret;
+ }
+
+ int parseSimpleTypeDerivationSet(String value)
+ {
+ int ret = XMLSchema.FINAL_NONE;
+ if ("#all".equals(value))
+ {
+ ret = XMLSchema.FINAL_LIST |
+ XMLSchema.FINAL_UNION |
+ XMLSchema.FINAL_RESTRICTION;
+ }
+ else
+ {
+ StringTokenizer st = new StringTokenizer(value, " ");
+ while (st.hasMoreTokens())
+ {
+ String token = st.nextToken();
+ if ("list".equals(token))
+ {
+ ret |= XMLSchema.FINAL_LIST;
+ }
+ else if ("union".equals(token))
+ {
+ ret |= XMLSchema.FINAL_UNION;
+ }
+ else if ("restriction".equals(token))
+ {
+ ret |= XMLSchema.FINAL_RESTRICTION;
+ }
+ }
+ }
+ return ret;
+ }
+
+ int parseComplexTypeDerivationSet(String value)
+ {
+ int ret = XMLSchema.FINAL_NONE;
+ if ("#all".equals(value))
+ {
+ ret = XMLSchema.FINAL_EXTENSION | XMLSchema.FINAL_RESTRICTION;
+ }
+ else
+ {
+ StringTokenizer st = new StringTokenizer(value, " ");
+ while (st.hasMoreTokens())
+ {
+ String token = st.nextToken();
+ if ("extension".equals(token))
+ {
+ ret |= XMLSchema.FINAL_EXTENSION;
+ }
+ else if ("restriction".equals(token))
+ {
+ ret |= XMLSchema.FINAL_RESTRICTION;
+ }
+ }
+ }
+ return ret;
+ }
+
+ int parseBlockSet(String value)
+ {
+ int ret = XMLSchema.BLOCK_NONE;
+ if ("#all".equals(value))
+ {
+ ret = XMLSchema.BLOCK_ALL;
+ }
+ else
+ {
+ StringTokenizer st = new StringTokenizer(value, " ");
+ while (st.hasMoreTokens())
+ {
+ String token = st.nextToken();
+ if ("extension".equals(token))
+ {
+ ret |= XMLSchema.BLOCK_EXTENSION;
+ }
+ else if ("restriction".equals(token))
+ {
+ ret |= XMLSchema.BLOCK_RESTRICTION;
+ }
+ else if ("substitution".equals(token))
+ {
+ ret |= XMLSchema.BLOCK_SUBSTITUTION;
+ }
+ }
+ }
+ return ret;
+ }
+
+ int parseComplexTypeBlockSet(String value)
+ {
+ int ret = XMLSchema.BLOCK_NONE;
+ if ("#all".equals(value))
+ {
+ ret = XMLSchema.BLOCK_EXTENSION | XMLSchema.BLOCK_RESTRICTION;
+ }
+ else
+ {
+ StringTokenizer st = new StringTokenizer(value, " ");
+ while (st.hasMoreTokens())
+ {
+ String token = st.nextToken();
+ if ("extension".equals(token))
+ {
+ ret |= XMLSchema.BLOCK_EXTENSION;
+ }
+ else if ("restriction".equals(token))
+ {
+ ret |= XMLSchema.BLOCK_RESTRICTION;
+ }
+ }
+ }
+ return ret;
+ }
+
+ Object parseElement(Node node, ElementDeclaration parent)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = node.getAttributes();
+ Integer minOccurs = null;
+ Integer maxOccurs = null;
+ Node parentNode = node.getParentNode();
+ boolean notTopLevel = !"schema".equals(parentNode.getLocalName());
+ if (notTopLevel)
+ {
+ String ref = getAttribute(attrs, "ref");
+ if (ref != null)
+ {
+ minOccurs = getOccurrence(getAttribute(attrs, "minOccurs"));
+ maxOccurs = getOccurrence(getAttribute(attrs, "maxOccurs"));
+ // TODO resolve top-level element declaration
+ ElementDeclaration ad = null;
+ return new Particle(minOccurs, maxOccurs, ad);
+ }
+ }
+ String elementName = getAttribute(attrs, "name");
+ String elementNamespace = getAttribute(attrs, "targetNamespace");
+ String type = getAttribute(attrs, "type");
+ Type datatype = (type != null) ?
+ parseSimpleType(asQName(type, node)) : null;
+ int scope = (parent == null) ?
+ XMLSchema.GLOBAL :
+ XMLSchema.LOCAL;
+ String def = getAttribute(attrs, "default");
+ String fixed = getAttribute(attrs, "fixed");
+ int constraintType = AttributeDeclaration.NONE;
+ String constraintValue = null;
+ if (def != null)
+ {
+ constraintType = AttributeDeclaration.DEFAULT;
+ constraintValue = def;
+ }
+ else if (fixed != null)
+ {
+ constraintType = AttributeDeclaration.FIXED;
+ constraintValue = fixed;
+ }
+ String sg = getAttribute(attrs, "substitutionGroup");
+ QName substitutionGroup = QName.valueOf(sg);
+ String sgPrefix = substitutionGroup.getPrefix();
+ if (sgPrefix != null && !"".equals(sgPrefix))
+ {
+ String sgName = substitutionGroup.getLocalPart();
+ String sgNamespace = node.lookupNamespaceURI(sgPrefix);
+ substitutionGroup = new QName(sgNamespace, sgName);
+ }
+
+ String block = getAttribute(attrs, "block");
+ int substitutionGroupExclusions = (block == null) ?
+ schema.blockDefault :
+ parseBlockSet(block);
+ String final_ = getAttribute(attrs, "final");
+ int disallowedSubstitutions = (final_ == null) ?
+ schema.finalDefault :
+ parseFullDerivationSet(final_);
+
+ boolean nillable = "true".equals(getAttribute(attrs, "nillable"));
+ boolean isAbstract = "true".equals(getAttribute(attrs, "abstract"));
+
+ if (notTopLevel)
+ {
+ minOccurs = getOccurrence(getAttribute(attrs, "minOccurs"));
+ maxOccurs = getOccurrence(getAttribute(attrs, "maxOccurs"));
+ String form = getAttribute(attrs, "form");
+ if (form != null)
+ {
+ if ("qualified".equals(form))
+ {
+ elementNamespace = schema.targetNamespace;
+ }
+ }
+ else if (schema.elementFormQualified)
+ {
+ elementNamespace = schema.targetNamespace;
+ }
+ }
+ ElementDeclaration ed =
+ new ElementDeclaration(new QName(elementNamespace, elementName),
+ datatype,
+ scope, parent,
+ constraintType, constraintValue,
+ nillable,
+ substitutionGroup,
+ substitutionGroupExclusions,
+ disallowedSubstitutions,
+ isAbstract);
+
+ for (Node child = node.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ ed.annotation = parseAnnotation(child);
+ }
+ else if ("simpleType".equals(name) && datatype == null)
+ {
+ ed.datatype = parseSimpleType(child);
+ }
+ else if ("complexType".equals(name) && datatype == null)
+ {
+ ed.datatype = parseComplexType(child, ed);
+ }
+ else
+ {
+ // throw schema exception
+ }
+ }
+ }
+
+ if (notTopLevel)
+ {
+ return new Particle(minOccurs, maxOccurs, ed);
+ }
+ else
+ {
+ return ed;
+ }
+ }
+
+ Integer getOccurrence(String value)
+ {
+ if (value == null)
+ {
+ return new Integer(1);
+ }
+ else if ("unbounded".equals(value))
+ {
+ return null;
+ }
+ else
+ {
+ return new Integer(value);
+ }
+ }
+
+ SimpleType parseSimpleType(QName typeName)
+ throws DatatypeException
+ {
+ SimpleType type = (SimpleType) schema.types.get(typeName);
+ if (!XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(typeName.getNamespaceURI()))
+ return null;
+ String localName = typeName.getLocalPart();
+ return (SimpleType) typeLibrary.createDatatype(localName);
+ }
+
+ SimpleType parseSimpleType(Node simpleType)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = simpleType.getAttributes();
+ String typeFinal = getAttribute(attrs, "final");
+ if (typeFinal == null)
+ {
+ Node schema = simpleType.getParentNode();
+ while (schema != null && !"schema".equals(schema.getLocalName()))
+ {
+ schema = schema.getParentNode();
+ }
+ if (schema != null)
+ {
+ NamedNodeMap schemaAttrs = schema.getAttributes();
+ typeFinal = getAttribute(schemaAttrs, "finalDefault");
+ }
+ }
+ int typeFinality = parseSimpleTypeDerivationSet(typeFinal);
+ QName typeName = asQName(getAttribute(attrs, "name"), simpleType);
+ int variety = 0;
+ Set facets = new LinkedHashSet();
+ int fundamentalFacets = 0; // TODO
+ SimpleType baseType = null; // TODO
+ Annotation annotation = null;
+ // TODO use DatatypeBuilder
+ for (Node child = simpleType.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ annotation = parseAnnotation(child);
+ }
+ else if ("restriction".equals(name))
+ {
+ // TODO
+ }
+ else if ("list".equals(name))
+ {
+ variety = SimpleType.LIST;
+ // TODO
+ }
+ else if ("union".equals(name))
+ {
+ variety = SimpleType.UNION;
+ // TODO
+ }
+ }
+ }
+ return new SimpleType(typeName, variety, facets, fundamentalFacets,
+ baseType, annotation);
+ }
+
+ Type parseComplexType(Node complexType, ElementDeclaration parent)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = complexType.getAttributes();
+ QName typeName = asQName(getAttribute(attrs, "name"), complexType);
+ boolean isAbstract = "true".equals(getAttribute(attrs, "abstract"));
+ String block = getAttribute(attrs, "block");
+ int prohibitedSubstitutions = (block == null) ?
+ schema.blockDefault :
+ parseComplexTypeBlockSet(block);
+ String final_ = getAttribute(attrs, "final");
+ int finality = (final_ == null) ?
+ schema.finalDefault :
+ parseComplexTypeDerivationSet(final_);
+ ComplexType type = new ComplexType(typeName, isAbstract,
+ prohibitedSubstitutions, finality);
+ boolean mixed = "true".equals(getAttribute(attrs, "mixed"));
+ for (Node child = complexType.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("simpleContent".equals(name))
+ {
+ parseSimpleContent(child, type);
+ }
+ }
+ }
+ if (mixed)
+ {
+ type.contentType = XMLSchema.CONTENT_MIXED;
+ }
+ return type;
+ }
+
+ void parseSimpleContent(Node simpleContent, ComplexType type)
+ throws DatatypeException
+ {
+ for (Node child = simpleContent.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ type.annotations.add(parseAnnotation(child));
+ }
+ else if ("restriction".equals(name))
+ {
+ type.derivationMethod = XMLSchema.FINAL_RESTRICTION;
+ parseRestriction(child, type);
+ }
+ else if ("extension".equals(name))
+ {
+ type.derivationMethod = XMLSchema.FINAL_EXTENSION;
+ parseExtension(child, type);
+ }
+ }
+ }
+ }
+
+ void parseRestriction(Node restriction, ComplexType type)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = restriction.getAttributes();
+ String base = getAttribute(attrs, "base");
+ QName baseType = asQName(base, restriction);
+ SimpleType simpleType = null;
+ for (Node child = restriction.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ type.annotations.add(parseAnnotation(child));
+ }
+ else if ("simpleType".equals(name))
+ {
+ type.contentType = XMLSchema.CONTENT_SIMPLE;
+ simpleType = parseSimpleType(child);
+ }
+ else if ("minExclusive".equals(name))
+ {
+ }
+ else if ("minInclusive".equals(name))
+ {
+ }
+ else if ("maxExclusive".equals(name))
+ {
+ }
+ else if ("maxInclusive".equals(name))
+ {
+ }
+ else if ("totalDigits".equals(name))
+ {
+ }
+ else if ("fractionDigits".equals(name))
+ {
+ }
+ else if ("length".equals(name))
+ {
+ }
+ else if ("minLength".equals(name))
+ {
+ }
+ else if ("maxLength".equals(name))
+ {
+ }
+ else if ("enumeration".equals(name))
+ {
+ }
+ else if ("whiteSpace".equals(name))
+ {
+ }
+ else if ("pattern".equals(name))
+ {
+ }
+ else if ("attribute".equals(name))
+ {
+ AttributeUse use =
+ (AttributeUse) parseAttribute(child, false);
+ schema.attributeDeclarations.put(use.declaration.name,
+ use.declaration);
+ type.attributeUses.add(use);
+ }
+ else if ("attributeGroup".equals(name))
+ {
+ NamedNodeMap agAttrs = child.getAttributes();
+ String ref = getAttribute(agAttrs, "ref");
+ QName ag = asQName(ref, child);
+ type.attributeUses.add(ag);
+ }
+ else if ("anyAttribute".equals(name))
+ {
+ type.attributeWildcard = parseAnyAttribute(child);
+ }
+ }
+ }
+ }
+
+ void parseExtension(Node extension, ComplexType type)
+ throws DatatypeException
+ {
+ NamedNodeMap attrs = extension.getAttributes();
+ String base = getAttribute(attrs, "base");
+ QName baseType = asQName(base, extension);
+ for (Node child = extension.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ type.annotations.add(parseAnnotation(child));
+ }
+ else if ("attribute".equals(name))
+ {
+ AttributeUse use =
+ (AttributeUse) parseAttribute(child, false);
+ schema.attributeDeclarations.put(use.declaration.name,
+ use.declaration);
+ type.attributeUses.add(use);
+ }
+ else if ("attributeGroup".equals(name))
+ {
+ NamedNodeMap agAttrs = child.getAttributes();
+ String ref = getAttribute(agAttrs, "ref");
+ QName ag = asQName(ref, child);
+ type.attributeUses.add(ag);
+ }
+ else if ("anyAttribute".equals(name))
+ {
+ type.attributeWildcard = parseAnyAttribute(child);
+ }
+ }
+ }
+ }
+
+ AnyAttribute parseAnyAttribute(Node node)
+ {
+ NamedNodeMap attrs = node.getAttributes();
+ String namespace = getAttribute(attrs, "namespace");
+ String pc = getAttribute(attrs, "processContents");
+ int processContents = AnyAttribute.STRICT;
+ if ("lax".equals(pc))
+ {
+ processContents = AnyAttribute.LAX;
+ }
+ else if ("skip".equals(pc))
+ {
+ processContents = AnyAttribute.SKIP;
+ }
+ AnyAttribute ret = new AnyAttribute(namespace, processContents);
+ for (Node child = node.getFirstChild(); child != null;
+ child = child.getNextSibling())
+ {
+ String uri = child.getNamespaceURI();
+ String name = child.getLocalName();
+ if (XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri) &&
+ child.getNodeType() == Node.ELEMENT_NODE)
+ {
+ if ("annotation".equals(name))
+ {
+ ret.annotation = parseAnnotation(child);
+ }
+ }
+ }
+ return ret;
+ }
+
+ Annotation parseAnnotation(Node node)
+ {
+ // TODO
+ return null;
+ }
+
+ private static String getAttribute(NamedNodeMap attrs, String name)
+ {
+ Node attr = attrs.getNamedItem(name);
+ return (attr == null) ? null : attr.getNodeValue();
+ }
+
+ private static QName asQName(String text, Node resolver)
+ {
+ QName name = QName.valueOf(text);
+ String prefix = name.getPrefix();
+ if (prefix != null && prefix.length() > 0)
+ {
+ String uri = resolver.lookupNamespaceURI(prefix);
+ name = new QName(uri, name.getLocalPart());
+ }
+ return name;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaElementTypeInfo.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaElementTypeInfo.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaElementTypeInfo.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaElementTypeInfo.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,93 @@
+/* XMLSchemaElementTypeInfo.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import org.w3c.dom.TypeInfo;
+import gnu.xml.validation.datatype.SimpleType;
+import gnu.xml.validation.datatype.Type;
+
+/**
+ * Element type information provided by validation against an XML Schema.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchemaElementTypeInfo
+ extends XMLSchemaTypeInfo
+{
+
+ final XMLSchema schema;
+ final ElementDeclaration decl;
+ final Type type;
+ boolean nil;
+
+ XMLSchemaElementTypeInfo(XMLSchema schema, ElementDeclaration decl,
+ Type type)
+ {
+ this.schema = schema;
+ this.decl = decl;
+ this.type = type;
+ }
+
+ public String getTypeName()
+ {
+ return type.name.getLocalPart();
+ }
+
+ public String getTypeNamespace()
+ {
+ return type.name.getNamespaceURI();
+ }
+
+ public boolean isDerivedFrom(String typeNamespace, String typeName,
+ int derivationMethod)
+ {
+ if (type instanceof SimpleType)
+ {
+ SimpleType simpleType = (SimpleType) type;
+ return simpleTypeIsDerivedFrom(simpleType, typeNamespace, typeName,
+ derivationMethod);
+ }
+ else
+ {
+ // TODO
+ return false;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaSchemaFactory.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaSchemaFactory.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaSchemaFactory.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaSchemaFactory.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,172 @@
+/* XMLSchemaSchemaFactory.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.io.IOException;
+import java.net.URL;
+import javax.xml.XMLConstants;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.transform.Source;
+import javax.xml.transform.dom.DOMSource;
+import javax.xml.transform.stream.StreamSource;
+import javax.xml.validation.Schema;
+import javax.xml.validation.SchemaFactory;
+import org.relaxng.datatype.DatatypeException;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.ls.LSResourceResolver;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * Schema factory for W3C XML Schema schemata.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XMLSchemaSchemaFactory
+ extends SchemaFactory
+{
+
+ LSResourceResolver resourceResolver;
+ ErrorHandler errorHandler;
+
+ public LSResourceResolver getResourceResolver()
+ {
+ return resourceResolver;
+ }
+
+ public void setResourceResolver(LSResourceResolver resourceResolver)
+ {
+ this.resourceResolver = resourceResolver;
+ }
+
+ public ErrorHandler getErrorHandler()
+ {
+ return this.errorHandler;
+ }
+
+ public void setErrorHandler(ErrorHandler errorHandler)
+ {
+ this.errorHandler = errorHandler;
+ }
+
+
+ public boolean isSchemaLanguageSupported(String schemaLanguage)
+ {
+ return XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(schemaLanguage);
+ }
+
+ public Schema newSchema()
+ throws SAXException
+ {
+ // TODO
+ throw new UnsupportedOperationException();
+ }
+
+ public Schema newSchema(Source[] schemata)
+ throws SAXException
+ {
+ if (schemata == null || schemata.length != 1)
+ throw new IllegalArgumentException("must specify one source");
+ // TODO multiple sources
+ try
+ {
+ Document doc = getDocument(schemata[0]);
+ XMLSchemaBuilder builder = new XMLSchemaBuilder();
+ builder.parseSchema(doc);
+ return builder.schema;
+ }
+ catch (IOException e)
+ {
+ SAXException e2 = new SAXException(e.getMessage());
+ e2.initCause(e);
+ throw e2;
+ }
+ catch (DatatypeException e)
+ {
+ SAXException e2 = new SAXException(e.getMessage());
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+ private static Document getDocument(Source source)
+ throws SAXException, IOException
+ {
+ if (source instanceof DOMSource)
+ {
+ Node node = ((DOMSource) source).getNode();
+ if (node != null && node instanceof Document)
+ return (Document) node;
+ }
+ String url = source.getSystemId();
+ try
+ {
+ InputSource input = new InputSource(url);
+ if (source instanceof StreamSource)
+ {
+ StreamSource streamSource = (StreamSource) source;
+ input.setByteStream(streamSource.getInputStream());
+ input.setCharacterStream(streamSource.getReader());
+ }
+ if (input.getByteStream() == null &&
+ input.getCharacterStream() == null &&
+ url != null)
+ input.setByteStream(new URL(url).openStream());
+ DocumentBuilderFactory f = DocumentBuilderFactory.newInstance();
+ f.setNamespaceAware(true);
+ f.setCoalescing(true);
+ f.setExpandEntityReferences(true);
+ f.setIgnoringComments(true);
+ f.setIgnoringElementContentWhitespace(true);
+ DocumentBuilder b = f.newDocumentBuilder();
+ return b.parse(input);
+ }
+ catch (ParserConfigurationException e)
+ {
+ SAXException e2 = new SAXException(e.getMessage());
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfo.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfo.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfo.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfo.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,77 @@
+/* XMLSchemaTypeInfo.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import org.w3c.dom.TypeInfo;
+import gnu.xml.validation.datatype.SimpleType;
+
+/**
+ * Abstract superclass providing simple type derivation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+abstract class XMLSchemaTypeInfo
+ implements TypeInfo
+{
+
+ protected boolean simpleTypeIsDerivedFrom(SimpleType simpleType,
+ String typeNamespace,
+ String typeName,
+ int derivationMethod)
+ {
+ switch (derivationMethod)
+ {
+ case TypeInfo.DERIVATION_RESTRICTION:
+ SimpleType baseType = simpleType.baseType;
+ while (baseType != null)
+ {
+ if (baseType.name.getNamespaceURI().equals(typeNamespace) &&
+ baseType.name.getLocalPart().equals(typeName))
+ {
+ return true;
+ }
+ baseType = baseType.baseType;
+ }
+ break;
+ // TODO other methods
+ }
+ return false;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfoProvider.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfoProvider.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfoProvider.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaTypeInfoProvider.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,82 @@
+/* XMLSchemaTypeInfoProvider.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import javax.xml.validation.TypeInfoProvider;
+import org.w3c.dom.TypeInfo;
+
+/**
+ * TypeInfo provider for XML Schema validator handler.
+ * This simply delegates to the handler. It wouldn't be required if
+ * TypeInfoProvider were an interface instead of an abstract class.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchemaTypeInfoProvider
+ extends TypeInfoProvider
+{
+
+ final XMLSchemaValidatorHandler handler;
+
+ XMLSchemaTypeInfoProvider(XMLSchemaValidatorHandler handler)
+ {
+ this.handler = handler;
+ }
+
+ public TypeInfo getElementTypeInfo()
+ {
+ return handler.getElementTypeInfo();
+ }
+
+ public TypeInfo getAttributeTypeInfo(int index)
+ {
+ return handler.getAttributeTypeInfo(index);
+ }
+
+ public boolean isIdAttribute(int index)
+ {
+ return handler.isIdAttribute(index);
+ }
+
+ public boolean isSpecified(int index)
+ {
+ return handler.isSpecified(index);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidator.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidator.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidator.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidator.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,98 @@
+/* XMLSchemaValidator.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.io.IOException;
+import javax.xml.validation.Validator;
+import javax.xml.transform.Result;
+import javax.xml.transform.Source;
+import org.w3c.dom.ls.LSResourceResolver;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.SAXException;
+
+/**
+ * JAXP validator for an XML Schema.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchemaValidator
+ extends Validator
+{
+
+ final XMLSchema schema;
+
+ ErrorHandler errorHandler;
+ LSResourceResolver resourceResolver;
+
+ XMLSchemaValidator(XMLSchema schema)
+ {
+ this.schema = schema;
+ }
+
+ public void reset()
+ {
+ }
+
+ public void validate(Source source, Result result)
+ throws SAXException, IOException
+ {
+ // TODO
+ }
+
+ public ErrorHandler getErrorHandler()
+ {
+ return errorHandler;
+ }
+
+ public void setErrorHandler(ErrorHandler errorHandler)
+ {
+ this.errorHandler = errorHandler;
+ }
+
+ public LSResourceResolver getResourceResolver()
+ {
+ return resourceResolver;
+ }
+
+ public void setResourceResolver(LSResourceResolver resourceResolver)
+ {
+ this.resourceResolver = resourceResolver;
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidatorHandler.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidatorHandler.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidatorHandler.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/validation/xmlschema/XMLSchemaValidatorHandler.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,394 @@
+/* XMLSchemaValidatorHandler.java --
+ Copyright (C) 2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.validation.xmlschema;
+
+import java.util.ArrayList;
+import java.util.LinkedList;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import javax.xml.validation.TypeInfoProvider;
+import javax.xml.validation.ValidatorHandler;
+import org.relaxng.datatype.DatatypeException;
+import org.relaxng.datatype.DatatypeLibrary;
+import org.relaxng.datatype.helpers.DatatypeLibraryLoader;
+import org.w3c.dom.TypeInfo;
+import org.w3c.dom.ls.LSResourceResolver;
+import org.xml.sax.Attributes;
+import org.xml.sax.ContentHandler;
+import org.xml.sax.ErrorHandler;
+import org.xml.sax.Locator;
+import org.xml.sax.SAXException;
+import org.xml.sax.ext.Attributes2Impl;
+import org.xml.sax.helpers.NamespaceSupport;
+import gnu.xml.validation.datatype.SimpleType;
+import gnu.xml.validation.datatype.Type;
+
+/**
+ * Streaming validator.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class XMLSchemaValidatorHandler
+ extends ValidatorHandler
+{
+
+ final XMLSchema schema;
+ final TypeInfoProvider typeInfoProvider;
+ final NamespaceSupport namespaceSupport;
+ final DatatypeLibrary typeLibrary;
+ Locator loc;
+ ContentHandler contentHandler;
+ ErrorHandler errorHandler;
+ LSResourceResolver resourceResolver;
+ final LinkedList context; // element context
+ final ArrayList attributes; // attribute context;
+
+ XMLSchemaValidatorHandler(XMLSchema schema)
+ {
+ this.schema = schema;
+ typeInfoProvider = new XMLSchemaTypeInfoProvider(this);
+ namespaceSupport = new NamespaceSupport();
+ context = new LinkedList();
+ attributes = new ArrayList();
+ final String ns = XMLConstants.W3C_XML_SCHEMA_NS_URI;
+ typeLibrary = new DatatypeLibraryLoader().createDatatypeLibrary(ns);
+ }
+
+ public ContentHandler getContentHandler()
+ {
+ return contentHandler;
+ }
+
+ public void setContentHandler(ContentHandler contentHandler)
+ {
+ this.contentHandler = contentHandler;
+ }
+
+ public ErrorHandler getErrorHandler()
+ {
+ return errorHandler;
+ }
+
+ public void setErrorHandler(ErrorHandler errorHandler)
+ {
+ this.errorHandler = errorHandler;
+ }
+
+ public LSResourceResolver getResourceResolver()
+ {
+ return resourceResolver;
+ }
+
+ public void setResourceResolver(LSResourceResolver resourceResolver)
+ {
+ this.resourceResolver = resourceResolver;
+ }
+
+ public TypeInfoProvider getTypeInfoProvider()
+ {
+ return typeInfoProvider;
+ }
+
+ TypeInfo getElementTypeInfo()
+ {
+ return (XMLSchemaElementTypeInfo) context.getFirst();
+ }
+
+ TypeInfo getAttributeTypeInfo(int index)
+ {
+ return (XMLSchemaAttributeTypeInfo) attributes.get(index);
+ }
+
+ boolean isIdAttribute(int index)
+ {
+ XMLSchemaAttributeTypeInfo typeInfo =
+ (XMLSchemaAttributeTypeInfo) attributes.get(index);
+ return typeInfo.id;
+ }
+
+ boolean isSpecified(int index)
+ {
+ XMLSchemaAttributeTypeInfo typeInfo =
+ (XMLSchemaAttributeTypeInfo) attributes.get(index);
+ return typeInfo.specified;
+ }
+
+ public void setDocumentLocator(Locator locator)
+ {
+ loc = locator;
+ if (contentHandler != null)
+ {
+ contentHandler.setDocumentLocator(locator);
+ }
+ }
+
+ public void startDocument()
+ throws SAXException
+ {
+ namespaceSupport.reset();
+ context.clear();
+ attributes.clear();
+ if (contentHandler != null)
+ {
+ contentHandler.startDocument();
+ }
+ }
+
+ public void endDocument()
+ throws SAXException
+ {
+ if (contentHandler != null)
+ {
+ contentHandler.endDocument();
+ }
+ }
+
+ public void startPrefixMapping(String prefix, String uri)
+ throws SAXException
+ {
+ namespaceSupport.declarePrefix(prefix, uri);
+ if (contentHandler != null)
+ {
+ contentHandler.startPrefixMapping(prefix, uri);
+ }
+ }
+
+ public void endPrefixMapping(String prefix)
+ throws SAXException
+ {
+ if (contentHandler != null)
+ {
+ contentHandler.endPrefixMapping(prefix);
+ }
+ }
+
+ public void startElement(String uri, String localName, String qName,
+ Attributes atts)
+ throws SAXException
+ {
+ namespaceSupport.pushContext();
+ QName name = new QName(uri, localName);
+ ElementDeclaration decl =
+ (ElementDeclaration) schema.elementDeclarations.get(name);
+ // Validation Rule: Element Locally Valid (Element)
+ String xsiType =
+ atts.getValue(XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI, "type");
+ xsiType = xsiType.trim(); // normalise
+ String xsiNil =
+ atts.getValue(XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI, "nil");
+ Type type = decl.datatype;
+ if (xsiType.length() > 0)
+ {
+ try
+ {
+ Type specifiedType = resolveType(xsiType);
+ // TODO 4.3
+ type = specifiedType;
+ }
+ catch (DatatypeException e) // 4.1, 4.2
+ {
+ ValidationException e2 =
+ new ValidationException("Can't resolve type " + xsiType,
+ loc);
+ e2.initCause(e);
+ throw e2;
+ }
+ }
+ XMLSchemaElementTypeInfo typeInfo =
+ new XMLSchemaElementTypeInfo(schema, decl, type);
+ if (decl == null) // 1
+ {
+ throw new ValidationException("No declaration for " + name, loc);
+ }
+ if (decl.isAbstract) // 2
+ {
+ throw new ValidationException("Declaration for " + name +
+ " is abstract", loc);
+ }
+ if (xsiNil.length() > 0)
+ {
+ if (!decl.nillable) // 3.1
+ {
+ throw new ValidationException("Declaration for " + name +
+ " is nillable but xsi:nil present",
+ loc);
+ }
+ else if ("true".equals(xsiNil)) // 3.2
+ {
+ typeInfo.nil = true;
+ if (decl.type == XMLSchema.CONSTRAINT_FIXED) // 3.2.2
+ {
+ throw new ValidationException("Declaration for " + name +
+ " is fixed but xsi:nil is true",
+ loc);
+ }
+ }
+ }
+ // TODO 5, 6, 7
+
+ // parent
+ if (!context.isEmpty())
+ {
+ XMLSchemaElementTypeInfo parent =
+ (XMLSchemaElementTypeInfo) context.getFirst();
+ if (parent.nil) // Element Locally Valid (Element) 3.2.1
+ {
+ throw new ValidationException("Parent of " + qName +
+ " is declared xsi:nil", loc);
+ }
+ // TODO
+ }
+ context.addFirst(typeInfo);
+ // attributes
+ int len = atts.getLength();
+ Attributes2Impl atts2 = new Attributes2Impl();
+ int count = 0;
+ for (int i = 0; i < len; i++)
+ {
+ String attUri = atts.getURI(i);
+ String attLocalName = atts.getLocalName(i);
+ String attQName = atts.getQName(i);
+ String attValue = atts.getValue(i);
+
+ if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI.equals(attUri))
+ {
+ continue; // ?
+ }
+
+ QName attName = new QName(attUri, attLocalName);
+ AttributeDeclaration attDecl =
+ (AttributeDeclaration) schema.attributeDeclarations.get(attName);
+ boolean declared = (attDecl != null);
+
+ String attType = (attDecl != null) ?
+ attDecl.datatype.toString() : "CDATA";
+ XMLSchemaAttributeTypeInfo attTypeInfo =
+ new XMLSchemaAttributeTypeInfo(schema, attDecl, true);
+ attributes.add(attTypeInfo);
+
+ atts2.addAttribute(attUri, attLocalName, attQName, attType, attValue);
+ atts2.setDeclared(count, declared);
+ atts2.setSpecified(count, true);
+ count++;
+ }
+ // add defaulted attributes to atts2
+ // TODO
+ // atts2.setSpecified(count, false);
+ if (contentHandler != null)
+ {
+ contentHandler.startElement(uri, localName, qName, atts2);
+ }
+ }
+
+ public void endElement(String uri, String localName, String qName)
+ throws SAXException
+ {
+ // TODO check all required have been seen
+ context.removeFirst();
+ attributes.clear();
+ namespaceSupport.popContext();
+ if (contentHandler != null)
+ {
+ contentHandler.endElement(uri, localName, qName);
+ }
+ }
+
+ public void characters(char[] ch, int start, int length)
+ throws SAXException
+ {
+ XMLSchemaElementTypeInfo parent =
+ (XMLSchemaElementTypeInfo) context.getFirst();
+ if (parent.nil) // Element Locally Valid (Element) 3.2.1
+ {
+ throw new ValidationException(parent.decl.name.toString() +
+ " is declared xsi:nil",
+ loc);
+ }
+ // TODO
+ if (contentHandler != null)
+ {
+ contentHandler.characters(ch, start, length);
+ }
+ }
+
+ public void ignorableWhitespace(char[] ch, int start, int length)
+ throws SAXException
+ {
+ if (contentHandler != null)
+ {
+ contentHandler.ignorableWhitespace(ch, start, length);
+ }
+ }
+
+ public void processingInstruction(String target, String data)
+ throws SAXException
+ {
+ if (contentHandler != null)
+ {
+ contentHandler.processingInstruction(target, data);
+ }
+ }
+
+ public void skippedEntity(String name)
+ throws SAXException
+ {
+ if (contentHandler != null)
+ {
+ contentHandler.skippedEntity(name);
+ }
+ }
+
+ Type resolveType(String value)
+ throws DatatypeException
+ {
+ QName name = QName.valueOf(value);
+ String prefix = name.getPrefix();
+ String localName = name.getLocalPart();
+ if (prefix != null && prefix.length() > 0)
+ {
+ String uri = namespaceSupport.getURI(prefix);
+ if (!XMLConstants.W3C_XML_SCHEMA_NS_URI.equals(uri))
+ return null;
+ }
+ if ("anyType".equals(localName))
+ return Type.ANY_TYPE;
+ return (SimpleType) typeLibrary.createDatatype(localName);
+ }
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/AndExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/AndExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/AndExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/AndExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,87 @@
+/* AndExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Logical and.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class AndExpr
+ extends Expr
+{
+
+ final Expr lhs;
+ final Expr rhs;
+
+ public AndExpr(Expr lhs, Expr rhs)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ if (!_boolean(context, left))
+ {
+ return Boolean.FALSE;
+ }
+ Object right = rhs.evaluate(context, pos, len);
+ return _boolean(context, right) ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new AndExpr(lhs.clone(context), rhs.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ return lhs + " and " + rhs;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ArithmeticExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ArithmeticExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ArithmeticExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ArithmeticExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,168 @@
+/* ArithmeticExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Binary arithmetic expression.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class ArithmeticExpr
+ extends Expr
+{
+
+ static final int ADD = 0;
+ static final int SUBTRACT = 1;
+ static final int MULTIPLY = 2;
+ static final int DIVIDE = 3;
+ static final int MODULO = 4;
+
+ final Expr lhs;
+ final Expr rhs;
+ final int op;
+
+ ArithmeticExpr(Expr lhs, Expr rhs, int op)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ switch (op)
+ {
+ case ADD:
+ case SUBTRACT:
+ case MULTIPLY:
+ case DIVIDE:
+ case MODULO:
+ this.op = op;
+ break;
+ default:
+ throw new IllegalArgumentException();
+ }
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ Object right = rhs.evaluate(context, pos, len);
+
+ double ln = _number(context, left);
+ double rn = _number(context, right);
+ switch (op)
+ {
+ case ADD:
+ return new Double(ln + rn);
+ case SUBTRACT:
+ return new Double(ln - rn);
+ case MULTIPLY:
+ return new Double(ln * rn);
+ case DIVIDE:
+ if (rn == 0.0d || rn == -0.0d)
+ {
+ if (ln == 0.0d || ln == -0.0d)
+ {
+ return new Double(Double.NaN);
+ }
+ else
+ {
+ return new Double(ln < 0.0d ?
+ Double.NEGATIVE_INFINITY :
+ Double.POSITIVE_INFINITY);
+ }
+ }
+ return new Double(ln / rn);
+ case MODULO:
+ if (rn == 0.0d || rn == 0.0d)
+ {
+ if (ln == 0.0d || ln == -0.0d)
+ {
+ return new Double(Double.NaN);
+ }
+ else
+ {
+ return new Double(ln < 0.0d ?
+ Double.NEGATIVE_INFINITY :
+ Double.POSITIVE_INFINITY);
+ }
+ }
+ return new Double(ln % rn);
+ default:
+ throw new IllegalStateException();
+ }
+ }
+
+ public Expr clone(Object context)
+ {
+ return new ArithmeticExpr(lhs.clone(context), rhs.clone(context), op);
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer();
+ buf.append(lhs);
+ buf.append(' ');
+ switch (op)
+ {
+ case ADD:
+ buf.append('+');
+ break;
+ case SUBTRACT:
+ buf.append('-');
+ break;
+ case MULTIPLY:
+ buf.append('*');
+ break;
+ case DIVIDE:
+ buf.append("div");
+ break;
+ case MODULO:
+ buf.append("mod");
+ break;
+ }
+ buf.append(' ');
+ buf.append(rhs);
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/BooleanFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/BooleanFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/BooleanFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/BooleanFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,95 @@
+/* BooleanFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>boolean</code> function converts its argument to a boolean as
+ * follows:
+ * <ul>
+ * <li>a number is true if and only if it is neither positive or negative
+ * zero nor NaN</li>
+ * <li>a node-set is true if and only if it is non-empty</li>
+ * <li>a string is true if and only if its length is non-zero</li>
+ * <li>an object of a type other than the four basic types is converted to a
+ * boolean in a way that is dependent on that type</li>
+ * </ul>
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class BooleanFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ BooleanFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ BooleanFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ return _boolean(context, val) ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new BooleanFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "boolean(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CeilingFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CeilingFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CeilingFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CeilingFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,89 @@
+/* CeilingFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>ceiling</code> function returns the smallest (closest to
+ * negative infinity) number that is not less than the argument and that
+ * is an integer.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class CeilingFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ CeilingFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ CeilingFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ double n = _number(context, val);
+ return new Double(Math.ceil(n));
+ }
+
+ public Expr clone(Object context)
+ {
+ return new CeilingFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "ceiling(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ConcatFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ConcatFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ConcatFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ConcatFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,113 @@
+/* ConcatFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>concat</code> function returns the concatenation of its arguments.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class ConcatFunction
+ extends Expr
+{
+
+ final List args;
+
+ ConcatFunction(List args)
+ {
+ this.args = args;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ StringBuffer buf = new StringBuffer();
+ for (Iterator i = args.iterator(); i.hasNext(); )
+ {
+ Expr arg = (Expr) i.next();
+ Object val = arg.evaluate(context, pos, len);
+ buf.append(_string(context, val));
+ }
+ return buf.toString();
+ }
+
+ public Expr clone(Object context)
+ {
+ int len = args.size();
+ List args2 = new ArrayList(len);
+ for (int i = 0; i < len; i++)
+ {
+ args2.add(((Expr) args.get(i)).clone(context));
+ }
+ return new ConcatFunction(args2);
+ }
+
+ public boolean references(QName var)
+ {
+ for (Iterator i = args.iterator(); i.hasNext(); )
+ {
+ if (((Expr) i.next()).references(var))
+ {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer("concat(");
+ int len = args.size();
+ for (int i = 0; i < len; i++)
+ {
+ if (i > 0)
+ {
+ buf.append(',');
+ }
+ buf.append(args.get(i));
+ }
+ buf.append(')');
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Constant.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Constant.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Constant.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Constant.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,98 @@
+/* Constant.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Constant value (string literal or number).
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class Constant
+ extends Expr
+{
+
+ final Object value;
+
+ public Constant(Object value)
+ {
+ this.value = value;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return value;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new Constant(value);
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ String ret = value.toString();
+ if (value instanceof String)
+ {
+ if (ret.indexOf('\'') == -1)
+ {
+ return '\'' + ret + '\'';
+ }
+ else
+ {
+ return '"' + ret + '"';
+ }
+ }
+ if (value instanceof Double)
+ {
+ if (ret.endsWith(".0"))
+ {
+ ret = ret.substring(0, ret.length() - 2);
+ }
+ }
+ return ret;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ContainsFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ContainsFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ContainsFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ContainsFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,92 @@
+/* ContainsFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>contains</code> function returns true if the first argument
+ * string contains the second argument string, and otherwise returns false.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class ContainsFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+
+ ContainsFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1));
+ }
+
+ ContainsFunction(Expr arg1, Expr arg2)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ String s1 = _string(context, val1);
+ String s2 = _string(context, val2);
+ return (s1.indexOf(s2) != -1) ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new ContainsFunction(arg1.clone(context), arg2.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var));
+ }
+
+ public String toString()
+ {
+ return "contains(" + arg1 + "," + arg2 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CountFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CountFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CountFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/CountFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,88 @@
+/* CountFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>count</code> function returns the number of nodes in the
+ * argument node-set.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class CountFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ CountFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ CountFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ return new Double((double) ((Collection) val).size());
+ }
+
+ public Expr clone(Object context)
+ {
+ return new CountFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "count(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/DocumentOrderComparator.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/DocumentOrderComparator.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/DocumentOrderComparator.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/DocumentOrderComparator.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,63 @@
+/* DocumentOrderComparator.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Comparator;
+import org.w3c.dom.Node;
+
+/**
+ * Sorts nodes into document order.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class DocumentOrderComparator
+ implements Comparator
+{
+
+ public int compare(Object o1, Object o2)
+ {
+ if (o1 instanceof Node && o2 instanceof Node)
+ {
+ Node n1 = (Node)o1;
+ Node n2 = (Node)o2;
+ return (int) n1.compareDocumentPosition(n2);
+ }
+ return 0;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/EqualityExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/EqualityExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/EqualityExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/EqualityExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,268 @@
+/* EqualityExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Iterator;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Boolean equality expression.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class EqualityExpr
+ extends Expr
+{
+
+ final Expr lhs;
+ final Expr rhs;
+ final boolean invert;
+
+ EqualityExpr(Expr lhs, Expr rhs, boolean invert)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ this.invert = invert;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ boolean val = evaluateImpl(context, pos, len);
+ if (invert)
+ {
+ return val ? Boolean.FALSE : Boolean.TRUE;
+ }
+ else
+ {
+ return val ? Boolean.TRUE : Boolean.FALSE;
+ }
+ }
+
+ private boolean evaluateImpl(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ Object right = rhs.evaluate(context, pos, len);
+
+ /*
+ * If both objects to be compared are node-sets, then the comparison
+ * will be true if and only if there is a node in the first node-set and
+ * a node in the second node-set such that the result of performing the
+ * comparison on the string-values of the two nodes is true.
+ */
+ boolean flns = left instanceof Collection;
+ boolean frns = right instanceof Collection;
+ if (flns && frns)
+ {
+ Collection lns = (Collection) left;
+ Collection rns = (Collection) right;
+ if (lns.isEmpty())
+ {
+ return false;
+ }
+ boolean all = true;
+ for (Iterator i = lns.iterator(); i.hasNext(); )
+ {
+ Node ltest = (Node) i.next();
+ for (Iterator j = rns.iterator(); j.hasNext(); )
+ {
+ Node rtest = (Node) j.next();
+ if (ltest == rtest || ltest.equals(rtest))
+ {
+ // much shorter
+ if (!invert)
+ {
+ return true;
+ }
+ }
+ else if (stringValue(ltest).equals(stringValue(rtest)))
+ {
+ if (!invert)
+ {
+ return true;
+ }
+ }
+ else
+ {
+ all = false;
+ }
+ }
+ }
+ return all;
+ }
+ /*
+ * If one object to be compared is a node-set and the other is a number,
+ * then the comparison will be true if and only if there is a node in
+ * the node-set such that the result of performing the comparison on the
+ * number to be compared and on the result of converting the
+ * string-value of that node to a number using the number function is
+ * true.
+ */
+ boolean fln = left instanceof Double;
+ boolean frn = right instanceof Double;
+ if ((flns && frn) || (frns && fln))
+ {
+ Collection ns = flns ? (Collection) left : (Collection) right;
+ double n = fln ? ((Double) left).doubleValue() :
+ ((Double) right).doubleValue();
+ boolean all = true;
+ for (Iterator i = ns.iterator(); i.hasNext(); )
+ {
+ Node test = (Node) i.next();
+ double nn = _number(context, stringValue(test));
+ if (nn == n)
+ {
+ if (!invert)
+ {
+ return true;
+ }
+ }
+ else
+ {
+ all = false;
+ }
+ }
+ return invert ? all : false;
+ }
+ /*
+ * If one object to be compared is a node-set and the other is a
+ * string, then the comparison will be true if and only if there is a
+ * node in the node-set such that the result of performing the
+ * comparison on the string-value of the node and the other string is
+ * true.
+ */
+ boolean fls = left instanceof String;
+ boolean frs = right instanceof String;
+ if ((flns && frs) || (frns && fls))
+ {
+ Collection ns = flns ? (Collection) left : (Collection) right;
+ String s = fls ? (String) left : (String) right;
+ boolean all = true;
+ for (Iterator i = ns.iterator(); i.hasNext(); )
+ {
+ Node test = (Node) i.next();
+ if (stringValue(test).equals(s))
+ {
+ if (!invert)
+ {
+ return true;
+ }
+ }
+ else
+ {
+ all = false;
+ }
+ }
+ return invert ? all : false;
+ }
+ /*
+ * If one object to be compared is a node-set and the other is a
+ * boolean, then the comparison will be true if and only if the result
+ * of performing the comparison on the boolean and on the result of
+ * converting the node-set to a boolean using the boolean function is
+ * true.
+ */
+ boolean flb = left instanceof Boolean;
+ boolean frb = right instanceof Boolean;
+ if ((flns && frb) || (frns && flb))
+ {
+ Collection ns = flns ? (Collection) left : (Collection) right;
+ boolean b = flb ? ((Boolean) left).booleanValue() :
+ ((Boolean) right).booleanValue();
+ return _boolean(context, ns) == b;
+ }
+ /*
+ * If at least one object to be compared is a boolean, then each object
+ * to be compared is converted to a boolean as if by applying the
+ * boolean function.
+ */
+ if (flb || frb)
+ {
+ boolean lb = flb ? ((Boolean) left).booleanValue() :
+ _boolean(context, left);
+ boolean rb = frb ? ((Boolean) right).booleanValue() :
+ _boolean(context, right);
+ return lb == rb;
+ }
+ /*
+ * Otherwise, if at least one object to be compared is
+ * a number, then each object to be compared is converted to a number as
+ * if by applying the number function.
+ */
+ if (fln || frn)
+ {
+ double ln = fln ? ((Double) left).doubleValue() :
+ _number(context, left);
+ double rn = frn ? ((Double) right).doubleValue() :
+ _number(context, right);
+ return ln == rn;
+ }
+ /*
+ * Otherwise, both objects to be
+ * compared are converted to strings as if by applying the string
+ * function.
+ */
+ String ls = fls ? (String) left : _string(context, left);
+ String rs = frs ? (String) right : _string(context, right);
+ return ls.equals(rs);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new EqualityExpr(lhs.clone(context), rhs.clone(context), invert);
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ if (invert)
+ {
+ return lhs + " != " + rhs;
+ }
+ else
+ {
+ return lhs + " = " + rhs;
+ }
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Expr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Expr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Expr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Expr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,495 @@
+/* Expr.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.io.IOException;
+import java.text.DecimalFormat;
+import java.text.DecimalFormatSymbols;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Locale;
+import java.util.Set;
+import java.util.StringTokenizer;
+import javax.xml.namespace.QName;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+import javax.xml.xpath.XPathConstants;
+import javax.xml.xpath.XPathExpression;
+import javax.xml.xpath.XPathExpressionException;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * An XPath expression.
+ * This can be evaluated in the context of a node to produce a result.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public abstract class Expr
+ implements XPathExpression
+{
+
+ protected static final Comparator documentOrderComparator =
+ new DocumentOrderComparator();
+
+ protected static final DecimalFormat decimalFormat =
+ new DecimalFormat("####################################################" +
+ ".####################################################",
+ new DecimalFormatSymbols(Locale.US));
+
+ public Object evaluate(Object item, QName returnType)
+ throws XPathExpressionException
+ {
+ Object ret = null;
+ Node context = null;
+ if (item instanceof Node)
+ {
+ context = (Node) item;
+ ret = evaluate(context, 1, 1);
+ if (XPathConstants.STRING == returnType &&
+ !(ret instanceof String))
+ {
+ ret = _string(context, ret);
+ }
+ else if (XPathConstants.NUMBER == returnType &&
+ !(ret instanceof Double))
+ {
+ ret = new Double(_number(context, ret));
+ }
+ else if (XPathConstants.BOOLEAN == returnType &&
+ !(ret instanceof Boolean))
+ {
+ ret = _boolean(context, ret) ? Boolean.TRUE : Boolean.FALSE;
+ }
+ else if (XPathConstants.NODE == returnType)
+ {
+ if (ret instanceof Collection)
+ {
+ Collection ns = (Collection) ret;
+ switch (ns.size())
+ {
+ case 0:
+ ret = null;
+ break;
+ case 1:
+ ret = (Node) ns.iterator().next();
+ break;
+ default:
+ throw new XPathExpressionException("multiple nodes in node-set");
+ }
+ }
+ else if (ret != null)
+ {
+ throw new XPathExpressionException("return value is not a node-set");
+ }
+ }
+ else if (XPathConstants.NODESET == returnType)
+ {
+ if (ret != null && !(ret instanceof Collection))
+ {
+ throw new XPathExpressionException("return value is not a node-set");
+ }
+ }
+ }
+ return ret;
+ }
+
+ public String evaluate(Object item)
+ throws XPathExpressionException
+ {
+ return (String) evaluate(item, XPathConstants.STRING);
+ }
+
+ public Object evaluate(InputSource source, QName returnType)
+ throws XPathExpressionException
+ {
+ try
+ {
+ DocumentBuilderFactory factory =
+ new gnu.xml.dom.JAXPFactory();
+ DocumentBuilder builder = factory.newDocumentBuilder();
+ Document doc = builder.parse(source);
+ return evaluate(doc, returnType);
+ }
+ catch (ParserConfigurationException e)
+ {
+ throw new XPathExpressionException(e);
+ }
+ catch (SAXException e)
+ {
+ throw new XPathExpressionException(e);
+ }
+ catch (IOException e)
+ {
+ throw new XPathExpressionException(e);
+ }
+ }
+
+ public String evaluate(InputSource source)
+ throws XPathExpressionException
+ {
+ return (String) evaluate(source, XPathConstants.STRING);
+ }
+
+ public abstract Object evaluate(Node context, int pos, int len);
+
+ public abstract Expr clone(Object context);
+
+ public abstract boolean references(QName var);
+
+ /* -- 4.1 Node Set Functions -- */
+
+ /**
+ * The id function selects elements by their unique ID.
+ * When the argument to id is of type node-set, then the result is
+ * the union of the result of applying id to the string-value of each of
+ * the nodes in the argument node-set. When the argument to id is of any
+ * other type, the argument is converted to a string as if by a call to
+ * the string function; the string is split into a whitespace-separated
+ * list of tokens (whitespace is any sequence of characters matching the
+ * production S); the result is a node-set containing the elements in the
+ * same document as the context node that have a unique ID equal to any of
+ * the tokens in the list.
+ */
+ public static Collection _id(Node context, Object object)
+ {
+ Set ret = new HashSet();
+ if (object instanceof Collection)
+ {
+ Collection nodeSet = (Collection) object;
+ for (Iterator i = nodeSet.iterator(); i.hasNext(); )
+ {
+ String string = stringValue((Node) i.next());
+ ret.addAll(_id (context, string));
+ }
+ }
+ else
+ {
+ Document doc = (context instanceof Document) ? (Document) context :
+ context.getOwnerDocument();
+ String string = _string(context, object);
+ StringTokenizer st = new StringTokenizer(string, " \t\r\n");
+ while (st.hasMoreTokens())
+ {
+ Node element = doc.getElementById(st.nextToken());
+ if (element != null)
+ {
+ ret.add(element);
+ }
+ }
+ }
+ return ret;
+ }
+
+ /**
+ * The local-name function returns the local part of the expanded-name of
+ * the node in the argument node-set that is first in document order. If
+ * the argument node-set is empty or the first node has no expanded-name,
+ * an empty string is returned. If the argument is omitted, it defaults to
+ * a node-set with the context node as its only member.
+ */
+ public static String _local_name(Node context, Collection nodeSet)
+ {
+ if (nodeSet == null || nodeSet.isEmpty())
+ return "";
+ Node node = firstNode(nodeSet);
+ String ret = node.getLocalName();
+ return (ret == null) ? "" : ret;
+ }
+
+ /**
+ * The namespace-uri function returns the namespace URI of the
+ * expanded-name of the node in the argument node-set that is first in
+ * document order. If the argument node-set is empty, the first node has
+ * no expanded-name, or the namespace URI of the expanded-name is null, an
+ * empty string is returned. If the argument is omitted, it defaults to a
+ * node-set with the context node as its only member.
+ */
+ public static String _namespace_uri(Node context, Collection nodeSet)
+ {
+ if (nodeSet == null || nodeSet.isEmpty())
+ return "";
+ Node node = firstNode(nodeSet);
+ String ret = node.getNamespaceURI();
+ return (ret == null) ? "" : ret;
+ }
+
+ /**
+ * The name function returns a string containing a QName representing the
+ * expanded-name of the node in the argument node-set that is first in
+ * document order. The QName must represent the expanded-name with respect
+ * to the namespace declarations in effect on the node whose expanded-name
+ * is being represented. Typically, this will be the QName that occurred
+ * in the XML source. This need not be the case if there are namespace
+ * declarations in effect on the node that associate multiple prefixes
+ * with the same namespace. However, an implementation may include
+ * information about the original prefix in its representation of nodes;
+ * in this case, an implementation can ensure that the returned string is
+ * always the same as the QName used in the XML source. If the argument
+ * node-set is empty or the first node has no expanded-name, an empty
+ * string is returned. If the argument it omitted, it defaults to a
+ * node-set with the context node as its only member.
+ */
+ public static String _name(Node context, Collection nodeSet)
+ {
+ if (nodeSet == null || nodeSet.isEmpty())
+ return "";
+ Node node = firstNode(nodeSet);
+ String ret = null;
+ switch (node.getNodeType())
+ {
+ case Node.ATTRIBUTE_NODE:
+ case Node.ELEMENT_NODE:
+ case Node.PROCESSING_INSTRUCTION_NODE:
+ ret = node.getNodeName();
+ }
+ return (ret == null) ? "" : ret;
+ }
+
+ /**
+ * Returns the first node in the set in document order.
+ */
+ static Node firstNode(Collection nodeSet)
+ {
+ List list = new ArrayList(nodeSet);
+ Collections.sort(list, documentOrderComparator);
+ return (Node) list.get(0);
+ }
+
+ /* -- 4.2 String Functions -- */
+
+ /**
+ * Implementation of the XPath <code>string</code> function.
+ */
+ public static String _string(Node context, Object object)
+ {
+ if (object == null)
+ {
+ return stringValue(context);
+ }
+ if (object instanceof String)
+ {
+ return (String) object;
+ }
+ if (object instanceof Boolean)
+ {
+ return object.toString();
+ }
+ if (object instanceof Double)
+ {
+ double d = ((Double) object).doubleValue();
+ if (Double.isNaN(d))
+ {
+ return "NaN";
+ }
+ else if (d == 0.0d)
+ {
+ return "0";
+ }
+ else if (Double.isInfinite(d))
+ {
+ if (d < 0)
+ {
+ return "-Infinity";
+ }
+ else
+ {
+ return "Infinity";
+ }
+ }
+ else
+ {
+ String ret = decimalFormat.format(d);
+ if (ret.endsWith (".0"))
+ {
+ ret = ret.substring(0, ret.length() - 2);
+ }
+ return ret;
+ }
+ }
+ if (object instanceof Collection)
+ {
+ Collection nodeSet = (Collection) object;
+ if (nodeSet.isEmpty())
+ {
+ return "";
+ }
+ Node node = firstNode(nodeSet);
+ return stringValue(node);
+ }
+ throw new IllegalArgumentException(object.toString());
+ }
+
+ /* -- 4.3 Boolean Functions -- */
+
+ /**
+ * Implementation of the XPath <code>boolean</code> function.
+ */
+ public static boolean _boolean(Node context, Object object)
+ {
+ if (object instanceof Boolean)
+ {
+ return ((Boolean) object).booleanValue();
+ }
+ if (object instanceof Double)
+ {
+ Double value = (Double) object;
+ if (value.isNaN())
+ return false;
+ return value.doubleValue() != 0.0;
+ }
+ if (object instanceof String)
+ {
+ return ((String) object).length() != 0;
+ }
+ if (object instanceof Collection)
+ {
+ return ((Collection) object).size() != 0;
+ }
+ return false; // TODO user defined types
+ }
+
+ /* -- 4.4 Number Functions -- */
+
+ /**
+ * Implementation of the XPath <code>number</code> function.
+ */
+ public static double _number(Node context, Object object)
+ {
+ if (object == null)
+ {
+ object = Collections.singleton(context);
+ }
+ if (object instanceof Double)
+ {
+ return ((Double) object).doubleValue();
+ }
+ if (object instanceof Boolean)
+ {
+ return ((Boolean) object).booleanValue() ? 1.0 : 0.0;
+ }
+ if (object instanceof Collection)
+ {
+ // Convert node-set to string
+ object = stringValue((Collection) object);
+ }
+ if (object instanceof String)
+ {
+ String string = ((String) object).trim();
+ try
+ {
+ return Double.parseDouble(string);
+ }
+ catch (NumberFormatException e)
+ {
+ return Double.NaN;
+ }
+ }
+ return Double.NaN; // TODO user-defined types
+ }
+
+ /**
+ * Computes the XPath string-value of the specified node-set.
+ */
+ public static String stringValue(Collection nodeSet)
+ {
+ StringBuffer buf = new StringBuffer();
+ for (Iterator i = nodeSet.iterator(); i.hasNext(); )
+ {
+ buf.append(stringValue((Node) i.next()));
+ }
+ return buf.toString();
+ }
+
+ /**
+ * Computes the XPath string-value of the specified node.
+ */
+ public static String stringValue(Node node)
+ {
+ return stringValue(node, false);
+ }
+
+ static String stringValue(Node node, boolean elementMode)
+ {
+ switch (node.getNodeType())
+ {
+ case Node.DOCUMENT_NODE: // 5.1 Root Node
+ case Node.DOCUMENT_FRAGMENT_NODE:
+ case Node.ELEMENT_NODE: // 5.2 Element Nodes
+ StringBuffer buf = new StringBuffer();
+ for (Node ctx = node.getFirstChild(); ctx != null;
+ ctx = ctx.getNextSibling())
+ {
+ buf.append(stringValue(ctx, true));
+ }
+ return buf.toString();
+ case Node.TEXT_NODE: // 5.7 Text Nodes
+ case Node.CDATA_SECTION_NODE:
+ return node.getNodeValue();
+ case Node.ATTRIBUTE_NODE: // 5.3 Attribute Nodes
+ case Node.PROCESSING_INSTRUCTION_NODE: // 5.5 Processing Instruction
+ case Node.COMMENT_NODE: // 5.6 Comment Nodes
+ if (!elementMode)
+ {
+ return node.getNodeValue();
+ }
+ default:
+ return "";
+ }
+ }
+
+ static int intValue(Object val)
+ {
+ if (val instanceof Double)
+ {
+ Double d = (Double) val;
+ return d.isNaN() ? 0 : d.intValue();
+ }
+ else
+ return (int) Math.ceil(_number(null, val));
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FalseFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FalseFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FalseFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FalseFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,72 @@
+/* FalseFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>false</code> function returns false.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class FalseFunction
+ extends Expr
+{
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new FalseFunction();
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ return "false()";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FloorFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FloorFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FloorFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FloorFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,89 @@
+/* FloorFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>floor</code> function returns the largest (closest to positive
+ * infinity) number that is not greater than the argument and that is an
+ * integer.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class FloorFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ FloorFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ FloorFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ double n = _number(context, val);
+ return new Double(Math.floor(n));
+ }
+
+ public Expr clone(Object context)
+ {
+ return new FloorFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "floor(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Function.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Function.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Function.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Function.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,57 @@
+/* Function.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+
+/**
+ * Interface to be implemented by external functions that need to receive
+ * parameter values.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public interface Function
+{
+
+ /**
+ * Sets the list of expressions to evaluate as parameter values.
+ */
+ void setArguments(List args);
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FunctionCall.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FunctionCall.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FunctionCall.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/FunctionCall.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,163 @@
+/* FunctionCall.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import javax.xml.namespace.QName;
+import javax.xml.xpath.XPathFunction;
+import javax.xml.xpath.XPathFunctionException;
+import javax.xml.xpath.XPathFunctionResolver;
+import org.w3c.dom.Node;
+
+/**
+ * Executes an XPath core or extension function.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class FunctionCall
+ extends Expr
+{
+
+ final XPathFunctionResolver resolver;
+ final String name;
+ final List args;
+
+ public FunctionCall(XPathFunctionResolver resolver, String name)
+ {
+ this(resolver, name, Collections.EMPTY_LIST);
+ }
+
+ public FunctionCall(XPathFunctionResolver resolver, String name, List args)
+ {
+ this.resolver = resolver;
+ this.name = name;
+ this.args = args;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ if (resolver != null)
+ {
+ QName qname = QName.valueOf(name);
+ int arity = args.size();
+ XPathFunction function = resolver.resolveFunction(qname, arity);
+ if (function != null)
+ {
+ //System.err.println("Calling "+toString()+" with "+values);
+ if (function instanceof Expr)
+ {
+ if (function instanceof Function)
+ {
+ ((Function) function).setArguments(args);
+ }
+ return ((Expr) function).evaluate(context, pos, len);
+ }
+ else
+ {
+ List values = new ArrayList(arity);
+ for (int i = 0; i < arity; i++)
+ {
+ Expr arg = (Expr) args.get(i);
+ values.add(arg.evaluate(context, pos, len));
+ }
+ try
+ {
+ return function.evaluate(values);
+ }
+ catch (XPathFunctionException e)
+ {
+ e.printStackTrace(System.err); // FIXME
+ throw new RuntimeException(e.getMessage(), e);
+ }
+ }
+ }
+ }
+ throw new IllegalArgumentException("Invalid function call: " +
+ toString());
+ }
+
+ public Expr clone(Object context)
+ {
+ int len = args.size();
+ List args2 = new ArrayList(len);
+ for (int i = 0; i < len; i++)
+ {
+ args2.add(((Expr) args.get(i)).clone(context));
+ }
+ XPathFunctionResolver r = resolver;
+ if (context instanceof XPathFunctionResolver)
+ {
+ r = (XPathFunctionResolver) context;
+ }
+ return new FunctionCall(r, name, args2);
+ }
+
+ public boolean references(QName var)
+ {
+ for (Iterator i = args.iterator(); i.hasNext(); )
+ {
+ if (((Expr) i.next()).references(var))
+ {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer();
+ buf.append(name);
+ buf.append('(');
+ int len = args.size();
+ for (int i = 0; i < len; i++)
+ {
+ if (i > 0)
+ {
+ buf.append(',');
+ }
+ buf.append(args.get(i));
+ }
+ buf.append(')');
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/IdFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/IdFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/IdFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/IdFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,102 @@
+/* IdFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>id</code> function selects elements by their unique ID.
+ * When the argument to id is of type node-set, then the result is
+ * the union of the result of applying id to the string-value of each of the
+ * nodes in the argument node-set. When the argument to id is of any other
+ * type, the argument is converted to a string as if by a call to the string
+ * function; the string is split into a whitespace-separated list of tokens
+ * (whitespace is any sequence of characters matching the production S); the
+ * result is a node-set containing the elements in the same document as the
+ * context node that have a unique ID equal to any of the tokens in the
+ * list.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class IdFunction
+ extends Pattern
+{
+
+ final Expr arg;
+
+ IdFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ public IdFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public boolean matches(Node context)
+ {
+ Object ret = evaluate(context, 1, 1);
+ return !((Collection) ret).isEmpty();
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ return _id(context, val);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new IdFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "id(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LangFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LangFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LangFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LangFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,122 @@
+/* LangFunction.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>lang</code> function returns true or false depending on whether
+ * the language of the context node as specified by xml:lang attributes is
+ * the same as or is a sublanguage of the language specified by the argument
+ * string. The language of the context node is determined by the value of
+ * the xml:lang attribute on the context node, or, if the context node has
+ * no xml:lang attribute, by the value of the xml:lang attribute on the
+ * nearest ancestor of the context node that has an xml:lang attribute. If
+ * there is no such attribute, then lang returns false. If there is such an
+ * attribute, then lang returns true if the attribute value is equal to the
+ * argument ignoring case, or if there is some suffix starting with - such
+ * that the attribute value is equal to the argument ignoring that suffix of
+ * the attribute value and ignoring case.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class LangFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ LangFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ LangFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ String lang = _string(context, val);
+ String clang = getLang(context);
+ while (clang == null && context != null)
+ {
+ context = context.getParentNode();
+ clang = getLang(context);
+ }
+ boolean ret = (clang == null) ? false :
+ clang.toLowerCase().startsWith(lang.toLowerCase());
+ return ret ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ String getLang(Node node)
+ {
+ while (node != null)
+ {
+ if (node.getNodeType() == Node.ELEMENT_NODE)
+ {
+ String lang = ((Element) node).getAttribute("xml:lang");
+ if (lang != null)
+ return lang;
+ }
+ node = node.getParentNode();
+ }
+ return null;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new IdFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "lang(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LastFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LastFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LastFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LastFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,73 @@
+/* LastFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>last</code> function returns a number equal to the context
+ * size from the expression evaluation context.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class LastFunction
+ extends Expr
+{
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return new Double((double) len);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new LastFunction();
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ return "last()";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LocalNameFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LocalNameFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LocalNameFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/LocalNameFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,95 @@
+/* LocalNameFunction.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>local-name</code> function returns the local part of the
+ * expanded-name of the node in the argument node-set that is first in
+ * document order.
+ * If the argument node-set is empty or the first node has no expanded-name,
+ * an empty string is returned. If the argument is omitted, it defaults to a
+ * node-set with the context node as its only member.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class LocalNameFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ LocalNameFunction(List args)
+ {
+ this(args.size() > 0 ? (Expr) args.get(0) : null);
+ }
+
+ LocalNameFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? Collections.singleton(context) :
+ arg.evaluate(context, pos, len);
+ return _local_name(context, (Collection) val);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new LocalNameFunction((arg == null) ? null :
+ arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "local-name()" : "local-name(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,103 @@
+/* NameFunction.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>name</code> function returns a string containing a QName
+ * representing the expanded-name of the node in the argument node-set that
+ * is first in document order. The QName must represent the expanded-name
+ * with respect to the namespace declarations in effect on the node whose
+ * expanded-name is being represented. Typically, this will be the QName
+ * that occurred in the XML source. This need not be the case if there are
+ * namespace declarations in effect on the node that associate multiple
+ * prefixes with the same namespace. However, an implementation may include
+ * information about the original prefix in its representation of nodes; in
+ * this case, an implementation can ensure that the returned string is
+ * always the same as the QName used in the XML source. If the argument
+ * node-set is empty or the first node has no expanded-name, an empty string
+ * is returned. If the argument it omitted, it defaults to a node-set with
+ * the context node as its only member.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NameFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ NameFunction(List args)
+ {
+ this(args.size() > 0 ? (Expr) args.get(0) : null);
+ }
+
+ NameFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? Collections.singleton(context) :
+ arg.evaluate(context, pos, len);
+ return _name(context, (Collection) val);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NameFunction((arg == null) ? null :
+ arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "name()" : "name(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameTest.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameTest.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameTest.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NameTest.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,143 @@
+/* NameTest.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Tests whether a node has the specified name.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class NameTest
+ extends Test
+{
+
+ final QName qName;
+ final boolean anyLocalName;
+ final boolean any;
+
+ public NameTest(QName qName, boolean anyLocalName, boolean any)
+ {
+ this.anyLocalName = anyLocalName;
+ this.any = any;
+ this.qName = qName;
+ }
+
+ public boolean matchesAny()
+ {
+ return any;
+ }
+
+ public boolean matchesAnyLocalName()
+ {
+ return anyLocalName;
+ }
+
+ public boolean matches(Node node, int pos, int len)
+ {
+ switch (node.getNodeType())
+ {
+ case Node.ATTRIBUTE_NODE:
+ // Do not match namespace attributes
+ String uri = node.getNamespaceURI();
+ if (XMLConstants.XMLNS_ATTRIBUTE_NS_URI.equals(uri) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getPrefix()) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getNodeName()))
+ {
+ return false;
+ }
+ // Fall through
+ case Node.ELEMENT_NODE:
+ break;
+ default:
+ return false;
+ }
+ if (any)
+ return true;
+ String uri = qName.getNamespaceURI();
+ String nodeUri = node.getNamespaceURI();
+ if (!equal(uri, nodeUri))
+ return false;
+ if (anyLocalName)
+ return true;
+ String localName = qName.getLocalPart();
+ String nodeLocalName = getLocalName(node);
+ return (localName.equals(nodeLocalName));
+ }
+
+ static String getLocalName(Node node)
+ {
+ String localName = node.getLocalName();
+ if (localName == null)
+ {
+ localName = node.getNodeName();
+ int ci = localName.indexOf(':');
+ if (ci != -1)
+ localName = localName.substring(ci + 1);
+ }
+ return localName;
+ }
+
+ static boolean equal(String s1, String s2)
+ {
+ return (((s1 == null || s1.length() == 0) &&
+ (s2 == null || s2.length() == 0)) ||
+ s1 != null && s1.equals(s2));
+ }
+
+ public Test clone(Object context)
+ {
+ return new NameTest(qName, anyLocalName, any);
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString ()
+ {
+ if (any)
+ return "*";
+ return qName.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceTest.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceTest.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceTest.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceTest.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,120 @@
+/* NamespaceTest.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Tests whether a namespace attribute has the specified name.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class NamespaceTest
+ extends Test
+{
+
+ final QName qName;
+ final boolean anyLocalName;
+ final boolean any;
+
+ public NamespaceTest(QName qName, boolean anyLocalName, boolean any)
+ {
+ this.anyLocalName = anyLocalName;
+ this.any = any;
+ this.qName = qName;
+ }
+
+ public boolean matchesAny()
+ {
+ return any;
+ }
+
+ public boolean matchesAnyLocalName()
+ {
+ return anyLocalName;
+ }
+
+ public boolean matches(Node node, int pos, int len)
+ {
+ switch (node.getNodeType())
+ {
+ case Node.ATTRIBUTE_NODE:
+ // Only match namespace attributes
+ String uri = node.getNamespaceURI();
+ if (XMLConstants.XMLNS_ATTRIBUTE_NS_URI.equals(uri) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getPrefix()) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getNodeName()))
+ break;
+ // Fall through
+ default:
+ // Only process namespace attributes
+ return false;
+ }
+ if (any)
+ return true;
+ String uri = qName.getNamespaceURI();
+ String nodeUri = node.getNamespaceURI();
+ if (!NameTest.equal(uri, nodeUri))
+ return false;
+ if (anyLocalName)
+ return true;
+ String localName = qName.getLocalPart();
+ String nodeLocalName = NameTest.getLocalName(node);
+ return (localName.equals(nodeLocalName));
+ }
+
+ public Test clone(Object context)
+ {
+ return new NamespaceTest(qName, anyLocalName, any);
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString ()
+ {
+ if (any)
+ return "*";
+ return qName.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceUriFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceUriFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceUriFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NamespaceUriFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,95 @@
+/* NamespaceUriFunction.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>namespace-uri</code> function returns the namespace URI of the
+ * expanded-name of the node in the argument node-set that is first in
+ * document order. If the argument node-set is empty, the first node has no
+ * expanded-name, or the namespace URI of the expanded-name is null, an
+ * empty string is returned. If the argument is omitted, it defaults to a
+ * node-set with the context node as its only member.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NamespaceUriFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ NamespaceUriFunction(List args)
+ {
+ this(args.size() > 0 ? (Expr) args.get(0) : null);
+ }
+
+ NamespaceUriFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? Collections.singleton(context) :
+ arg.evaluate(context, pos, len);
+ return _namespace_uri(context, (Collection) val);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NamespaceUriFunction((arg == null) ? null :
+ arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "namespace-uri()" : "namespace-uri(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NegativeExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NegativeExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NegativeExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NegativeExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,81 @@
+/* NegativeExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Unary negative.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NegativeExpr
+ extends Expr
+{
+
+ final Expr expr;
+
+ NegativeExpr(Expr expr)
+ {
+ this.expr = expr;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = expr.evaluate(context, pos, len);
+ double n = _number(context, val);
+ return new Double(-n);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NegativeExpr(expr.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return expr.references(var);
+ }
+
+ public String toString()
+ {
+ return "-" + expr;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NodeTypeTest.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NodeTypeTest.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NodeTypeTest.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NodeTypeTest.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,141 @@
+/* NodeTypeTest.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+import org.w3c.dom.ProcessingInstruction;
+
+/**
+ * Tests whether a node is of a given type.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class NodeTypeTest
+ extends Test
+{
+
+ final short type;
+ final String data;
+
+ public NodeTypeTest(short type)
+ {
+ this(type, null);
+ }
+
+ public NodeTypeTest(short type, String data)
+ {
+ this.type = type;
+ this.data = data;
+ }
+
+ public short getNodeType()
+ {
+ return type;
+ }
+
+ public String getData()
+ {
+ return data;
+ }
+
+ public boolean matches(Node node, int pos, int len)
+ {
+ short nodeType = node.getNodeType();
+ switch (nodeType)
+ {
+ case Node.ELEMENT_NODE:
+ case Node.ATTRIBUTE_NODE:
+ case Node.TEXT_NODE:
+ case Node.CDATA_SECTION_NODE:
+ case Node.COMMENT_NODE:
+ case Node.DOCUMENT_NODE:
+ if (type > 0)
+ {
+ if (nodeType != type)
+ return false;
+ }
+ return true;
+ case Node.PROCESSING_INSTRUCTION_NODE:
+ if (type > 0)
+ {
+ if (nodeType != type)
+ return false;
+ if (data != null &&
+ !data.equals(((ProcessingInstruction) node).getTarget()))
+ return false;
+ }
+ return true;
+ default:
+ // Not part of XPath data model
+ return false;
+ }
+ }
+
+ public Test clone(Object context)
+ {
+ return new NodeTypeTest(type, data);
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ switch (type)
+ {
+ case 0:
+ return "node()";
+ case Node.TEXT_NODE:
+ return "text()";
+ case Node.COMMENT_NODE:
+ return "comment()";
+ case Node.PROCESSING_INSTRUCTION_NODE:
+ if (data != null)
+ {
+ return "processing-instruction('" + data + "')";
+ }
+ return "processing-instruction()";
+ default:
+ throw new IllegalStateException();
+ }
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NormalizeSpaceFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NormalizeSpaceFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NormalizeSpaceFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NormalizeSpaceFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,105 @@
+/* NormalizeSpaceFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import java.util.StringTokenizer;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>normalize-space</code> function returns the argument string
+ * with whitespace normalized by stripping leading and trailing whitespace
+ * and replacing sequences of whitespace characters by a single space.
+ * Whitespace characters are the same as those allowed by the S production
+ * in XML. If the argument is omitted, it defaults to the context node
+ * converted to a string, in other words the string-value of the context
+ * node.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NormalizeSpaceFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ NormalizeSpaceFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ NormalizeSpaceFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? null : arg.evaluate(context, pos, len);
+ String s = _string(context, val);
+ StringTokenizer st = new StringTokenizer(s, " \t\r\n");
+ StringBuffer buf = new StringBuffer();
+ if (st.hasMoreTokens())
+ {
+ buf.append(st.nextToken());
+ while (st.hasMoreTokens())
+ {
+ buf.append(' ');
+ buf.append(st.nextToken());
+ }
+ }
+ return buf.toString();
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NormalizeSpaceFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "normalize-space()" : "normalize-space(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NotFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NotFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NotFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NotFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,87 @@
+/* NotFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>not</code> function returns true if its argument is false,
+ * and false otherwise.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NotFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ NotFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ NotFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ return _boolean(context, val) ? Boolean.FALSE : Boolean.TRUE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NotFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "not(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NumberFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NumberFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NumberFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/NumberFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,102 @@
+/* NumberFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>number</code> function converts its argument to a number as
+ * follows:
+ * <ul>
+ * <li>a string that consists of optional whitespace followed by an optional
+ * minus sign followed by a Number followed by whitespace is converted to
+ * the IEEE 754 number that is nearest (according to the IEEE 754
+ * round-to-nearest rule) to the mathematical value represented by the
+ * string; any other string is converted to NaN</li>
+ * <li>boolean true is converted to 1; boolean false is converted to 0</li>
+ * <li>a node-set is first converted to a string as if by a call to the
+ * string function and then converted in the same way as a string
+ * argument</li>
+ * <li>an object of a type other than the four basic types is converted to a
+ * number in a way that is dependent on that type</li>
+ * </ul>
+ * If the argument is omitted, it defaults to a node-set with the context
+ * node as its only member.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class NumberFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ NumberFunction(List args)
+ {
+ this(args.size() > 0 ? (Expr) args.get(0) : null);
+ }
+
+ NumberFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? null : arg.evaluate(context, pos, len);
+ return new Double(_number(context, val));
+ }
+
+ public Expr clone(Object context)
+ {
+ return new NumberFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "number(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/OrExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/OrExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/OrExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/OrExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,87 @@
+/* OrExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Logical or.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class OrExpr
+ extends Expr
+{
+
+ final Expr lhs;
+ final Expr rhs;
+
+ public OrExpr(Expr lhs, Expr rhs)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ if (_boolean(context, left))
+ {
+ return Boolean.TRUE;
+ }
+ Object right = rhs.evaluate(context, pos, len);
+ return _boolean(context, right) ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new OrExpr(lhs.clone(context), rhs.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ return lhs + " or " + rhs;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ParenthesizedExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ParenthesizedExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ParenthesizedExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/ParenthesizedExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,90 @@
+/* ParenthesizedExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Simple subexpression.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class ParenthesizedExpr
+ extends Expr
+{
+
+ final Expr expr;
+
+ ParenthesizedExpr(Expr expr)
+ {
+ this.expr = expr;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object ret = expr.evaluate(context, pos, len);
+ if (ret instanceof Collection)
+ {
+ List list = new ArrayList((Collection) ret);
+ Collections.sort(list, documentOrderComparator);
+ ret = list;
+ }
+ return ret;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new ParenthesizedExpr(expr.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return expr.references(var);
+ }
+
+ public String toString()
+ {
+ return "(" + expr + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Path.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Path.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Path.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Path.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,54 @@
+/* Path.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import org.w3c.dom.Node;
+
+/**
+ * An XPath path component expression.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+abstract class Path
+ extends Pattern
+{
+
+ abstract Collection evaluate(Node context, Collection nodeSet);
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Pattern.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Pattern.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Pattern.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Pattern.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,54 @@
+/* Pattern.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import org.w3c.dom.Node;
+
+/**
+ * Interface implemented by expressions that can form part of XSL patterns.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public abstract class Pattern
+ extends Expr
+{
+
+ public abstract boolean matches(Node context);
+
+}
+
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/PositionFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/PositionFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/PositionFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/PositionFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,73 @@
+/* PositionFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>position</code> function returns a number equal to the context
+ * position from the expression evaluation context.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class PositionFunction
+ extends Expr
+{
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return new Double((double) pos);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new PositionFunction();
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ return "position()";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Predicate.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Predicate.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Predicate.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Predicate.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,85 @@
+/* Predicate.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Tests whether an expression matches against a given context node.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+class Predicate
+ extends Test
+{
+
+ final Expr expr;
+
+ Predicate(Expr expr)
+ {
+ this.expr = expr;
+ }
+
+ public boolean matches(Node node, int pos, int len)
+ {
+ Object ret = expr.evaluate(node, pos, len);
+ if (ret instanceof Double)
+ {
+ // Same as [position() = x]
+ return ((Double) ret).intValue() == pos;
+ }
+ return Expr._boolean(node, expr.evaluate(node, pos, len));
+ }
+
+ public Test clone(Object context)
+ {
+ return new Predicate(expr.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return expr.references(var);
+ }
+
+ public String toString()
+ {
+ return "[" + expr + "]";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RelationalExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RelationalExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RelationalExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RelationalExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,107 @@
+/* RelationalExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * Numerical comparison expression.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class RelationalExpr
+ extends Expr
+{
+
+ final Expr lhs;
+ final Expr rhs;
+ final boolean lt;
+ final boolean eq;
+
+ RelationalExpr(Expr lhs, Expr rhs, boolean lt, boolean eq)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ this.lt = lt;
+ this.eq = eq;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ Object right = rhs.evaluate(context, pos, len);
+ double ln = _number(context, left);
+ double rn = _number(context, right);
+ if (eq && ln == rn)
+ {
+ return Boolean.TRUE;
+ }
+ if (lt)
+ {
+ if (ln < rn || Double.isInfinite(rn))
+ {
+ return Boolean.TRUE;
+ }
+ }
+ else
+ {
+ if (ln > rn || Double.isInfinite(ln))
+ {
+ return Boolean.TRUE;
+ }
+ }
+ return Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new RelationalExpr(lhs.clone(context), rhs.clone(context), lt, eq);
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ return lhs + " " + (lt ? "<" : ">") + (eq ? "=" : "") + " " + rhs;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Root.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Root.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Root.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Root.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,87 @@
+/* Root.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Collections;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+
+/**
+ * Expression that evaluates to the document root.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class Root
+ extends Path
+{
+
+ public boolean matches(Node node)
+ {
+ return (node.getNodeType() == Node.DOCUMENT_NODE);
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return evaluate(context, Collections.EMPTY_SET);
+ }
+
+ Collection evaluate(Node context, Collection ns)
+ {
+ Document doc = (context instanceof Document) ? (Document) context :
+ context.getOwnerDocument();
+ return Collections.singleton(doc);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new Root();
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ return "/";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RoundFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RoundFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RoundFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/RoundFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,96 @@
+/* RoundFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>round</code> function returns the number that is closest to the
+ * argument and that is an integer. If there are two such numbers, then the
+ * one that is closest to positive infinity is returned. If the argument is
+ * NaN, then NaN is returned. If the argument is positive infinity, then
+ * positive infinity is returned. If the argument is negative infinity, then
+ * negative infinity is returned. If the argument is positive zero, then
+ * positive zero is returned. If the argument is negative zero, then
+ * negative zero is returned. If the argument is less than zero, but greater
+ * than or equal to -0.5, then negative zero is returned.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class RoundFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ RoundFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ RoundFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ double n = _number(context, val);
+ return (Double.isNaN(n) || Double.isInfinite(n)) ?
+ new Double(n) : new Double(Math.round(n));
+ }
+
+ public Expr clone(Object context)
+ {
+ return new RoundFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "round(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Selector.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Selector.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Selector.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Selector.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,499 @@
+/* Selector.java --
+ Copyright (C) 2004,2006 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.LinkedHashSet;
+import java.util.List;
+import java.util.Set;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Attr;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+
+/**
+ * A single component of a location path.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class Selector
+ extends Path
+{
+
+ public static final int ANCESTOR = 0;
+ public static final int ANCESTOR_OR_SELF = 1;
+ public static final int ATTRIBUTE = 2;
+ public static final int CHILD = 3;
+ public static final int DESCENDANT = 4;
+ public static final int DESCENDANT_OR_SELF = 5;
+ public static final int FOLLOWING = 6;
+ public static final int FOLLOWING_SIBLING = 7;
+ public static final int NAMESPACE = 8;
+ public static final int PARENT = 9;
+ public static final int PRECEDING = 10;
+ public static final int PRECEDING_SIBLING = 11;
+ public static final int SELF = 12;
+
+ /**
+ * Axis to select nodes in.
+ */
+ final int axis;
+
+ /**
+ * List of tests to perform on candidates.
+ */
+ final Test[] tests;
+
+ public Selector(int axis, List tests)
+ {
+ this.axis = axis;
+ int len = tests.size();
+ this.tests = new Test[(len == 0) ? 1 : len];
+ if (len > 0)
+ tests.toArray(this.tests);
+ else
+ this.tests[0] = new NodeTypeTest((short) 0);
+ if (axis == NAMESPACE && this.tests[0] instanceof NameTest)
+ {
+ NameTest nt = (NameTest) this.tests[0];
+ this.tests[0] = new NamespaceTest(nt.qName, nt.anyLocalName, nt.any);
+ }
+ }
+
+ /**
+ * Returns the list of tests to perform on candidates.
+ */
+ public Test[] getTests()
+ {
+ return tests;
+ }
+
+ public boolean matches(Node context)
+ {
+ // If called directly, selector is the top level of the path
+ return matches(context,
+ getContextPosition(context),
+ getContextSize(context));
+ }
+
+ boolean matches(Node context, int pos, int len)
+ {
+ short nodeType = context.getNodeType();
+ switch (axis)
+ {
+ case CHILD:
+ if (nodeType == Node.ATTRIBUTE_NODE)
+ return false;
+ break;
+ case ATTRIBUTE:
+ case NAMESPACE:
+ if (nodeType != Node.ATTRIBUTE_NODE)
+ return false;
+ break;
+ case DESCENDANT_OR_SELF:
+ return true;
+ default:
+ return false;
+ }
+ for (int j = 0; j < tests.length && len > 0; j++)
+ {
+ Test test = tests[j];
+ if (!test.matches(context, pos, len))
+ return false;
+ }
+ return true;
+ }
+
+ private int getContextPosition(Node ctx)
+ {
+ int pos = 1;
+ for (ctx = ctx.getPreviousSibling(); ctx != null;
+ ctx = ctx.getPreviousSibling())
+ {
+ if (tests[0].matches(ctx, 1, 1))
+ pos++;
+ }
+ return pos;
+ }
+
+ private int getContextSize(Node ctx)
+ {
+ if (ctx.getNodeType() == Node.ATTRIBUTE_NODE)
+ {
+ Node owner = ((Attr) ctx).getOwnerElement();
+ return owner.getAttributes().getLength();
+ }
+ int count = 1;
+ Node sib = ctx.getPreviousSibling();
+ for (; sib != null; sib = sib.getPreviousSibling())
+ {
+ if (tests[0].matches(ctx, 1, 1))
+ count++;
+ }
+ sib = ctx.getNextSibling();
+ for (; sib != null; sib = sib.getNextSibling())
+ {
+ if (tests[0].matches(ctx, 1, 1))
+ count++;
+ }
+ return count;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Set acc = new LinkedHashSet();
+ addCandidates(context, acc);
+ List candidates = new ArrayList(acc);
+ List ret = filterCandidates(candidates, false);
+ return ret;
+ }
+
+ Collection evaluate(Node context, Collection ns)
+ {
+ Set acc = new LinkedHashSet();
+ for (Iterator i = ns.iterator(); i.hasNext(); )
+ addCandidates((Node) i.next(), acc);
+ List candidates = new ArrayList(acc);
+ List ret = filterCandidates(candidates, true);
+ return ret;
+ }
+
+ /**
+ * Filter the given list of candidates according to the node tests.
+ */
+ List filterCandidates(List candidates, boolean cascade)
+ {
+ int len = candidates.size();
+ int tlen = tests.length;
+ if (tlen > 0 && len > 0)
+ {
+ // Present the result of each successful generation to the next test
+ for (int j = 0; j < tlen && len > 0; j++)
+ {
+ Test test = tests[j];
+ List successful = new ArrayList(len);
+ for (int i = 0; i < len; i++)
+ {
+ Node node = (Node) candidates.get(i);
+ if (cascade)
+ {
+ // Documents and DocumentFragments should be considered
+ // if part of a location path where the axis involves
+ // the SELF concept
+ short nodeType = node.getNodeType();
+ if ((nodeType == Node.DOCUMENT_NODE ||
+ nodeType == Node.DOCUMENT_FRAGMENT_NODE) &&
+ (axis == DESCENDANT_OR_SELF ||
+ axis == ANCESTOR_OR_SELF ||
+ axis == SELF) &&
+ (tests.length == 1 &&
+ tests[0] instanceof NodeTypeTest &&
+ ((NodeTypeTest) tests[0]).type == (short) 0))
+ {
+ successful.add(node);
+ continue;
+ }
+ }
+ if (test.matches(node, i + 1, len))
+ successful.add(node);
+ }
+ candidates = successful;
+ len = candidates.size();
+ }
+ }
+ return candidates;
+ }
+
+ void addCandidates(Node context, Collection candidates)
+ {
+ // Build list of candidates
+ switch (axis)
+ {
+ case CHILD:
+ addChildNodes(context, candidates, false);
+ break;
+ case DESCENDANT:
+ addChildNodes(context, candidates, true);
+ break;
+ case DESCENDANT_OR_SELF:
+ candidates.add (context);
+ addChildNodes(context, candidates, true);
+ break;
+ case PARENT:
+ addParentNode(context, candidates, false);
+ break;
+ case ANCESTOR:
+ addParentNode(context, candidates, true);
+ break;
+ case ANCESTOR_OR_SELF:
+ candidates.add(context);
+ addParentNode(context, candidates, true);
+ break;
+ case FOLLOWING_SIBLING:
+ addFollowingNodes(context, candidates, false);
+ break;
+ case PRECEDING_SIBLING:
+ addPrecedingNodes(context, candidates, false);
+ break;
+ case FOLLOWING:
+ addFollowingNodes(context, candidates, true);
+ break;
+ case PRECEDING:
+ addPrecedingNodes(context, candidates, true);
+ break;
+ case ATTRIBUTE:
+ addAttributes(context, candidates);
+ break;
+ case NAMESPACE:
+ addNamespaceAttributes(context, candidates);
+ break;
+ case SELF:
+ candidates.add(context);
+ break;
+ }
+ }
+
+ void addChildNodes(Node context, Collection acc, boolean recurse)
+ {
+ Node child = context.getFirstChild();
+ while (child != null)
+ {
+ acc.add(child);
+ if (recurse)
+ addChildNodes(child, acc, recurse);
+ child = child.getNextSibling();
+ }
+ }
+
+ void addParentNode(Node context, Collection acc, boolean recurse)
+ {
+ Node parent = (context.getNodeType() == Node.ATTRIBUTE_NODE) ?
+ ((Attr) context).getOwnerElement() : context.getParentNode();
+ if (parent != null)
+ {
+ acc.add(parent);
+ if (recurse)
+ addParentNode(parent, acc, recurse);
+ }
+ }
+
+ void addFollowingNodes(Node context, Collection acc, boolean recurse)
+ {
+ if (context != null && recurse)
+ addChildNodes(context, acc, true);
+ Node cur = (context.getNodeType() == Node.ATTRIBUTE_NODE) ? null :
+ context.getNextSibling();
+ while (cur != null)
+ {
+ acc.add(cur);
+ if (recurse)
+ addChildNodes(cur, acc, true);
+ cur = cur.getNextSibling();
+ }
+ if (recurse)
+ {
+ while (context != null)
+ {
+ context = (context.getNodeType() == Node.ATTRIBUTE_NODE) ?
+ ((Attr) context).getOwnerElement() : context.getParentNode();
+ if (context != null)
+ {
+ cur = context.getNextSibling();
+ while (cur != null)
+ {
+ acc.add(cur);
+ if (recurse)
+ addChildNodes(cur, acc, true);
+ cur = cur.getNextSibling();
+ }
+ }
+ }
+ }
+ }
+
+ void addPrecedingNodes(Node context, Collection acc, boolean recurse)
+ {
+ Node cur = (context.getNodeType() == Node.ATTRIBUTE_NODE) ? null :
+ context.getPreviousSibling();
+ while (cur != null)
+ {
+ acc.add(cur);
+ if (recurse)
+ addChildNodes(cur, acc, true);
+ cur = cur.getPreviousSibling();
+ }
+ if (recurse)
+ {
+ cur = context;
+ cur = (cur.getNodeType() == Node.ATTRIBUTE_NODE) ?
+ ((Attr) cur).getOwnerElement() : cur.getParentNode();
+ if (cur != null)
+ addPrecedingNodes(cur, acc, recurse);
+ }
+ }
+
+ void addAttributes(Node context, Collection acc)
+ {
+ NamedNodeMap attrs = context.getAttributes();
+ if (attrs != null)
+ {
+ int attrLen = attrs.getLength();
+ for (int i = 0; i < attrLen; i++)
+ {
+ Node attr = attrs.item(i);
+ if (!isNamespaceAttribute(attr))
+ {
+ acc.add(attr);
+ }
+ }
+ }
+ }
+
+ void addNamespaceAttributes(Node context, Collection acc)
+ {
+ NamedNodeMap attrs = context.getAttributes();
+ if (attrs != null)
+ {
+ int attrLen = attrs.getLength();
+ for (int i = 0; i < attrLen; i++)
+ {
+ Node attr = attrs.item(i);
+ if (isNamespaceAttribute(attr))
+ acc.add(attr);
+ }
+ }
+ }
+
+ final boolean isNamespaceAttribute(Node node)
+ {
+ String uri = node.getNamespaceURI();
+ return (XMLConstants.XMLNS_ATTRIBUTE_NS_URI.equals(uri) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getPrefix()) ||
+ XMLConstants.XMLNS_ATTRIBUTE.equals(node.getNodeName()));
+ }
+
+ public Expr clone(Object context)
+ {
+ int len = tests.length;
+ List tests2 = new ArrayList(len);
+ for (int i = 0; i < len; i++)
+ tests2.add(tests[i].clone(context));
+ return new Selector(axis, tests2);
+ }
+
+ public boolean references(QName var)
+ {
+ for (int i = 0; i < tests.length; i++)
+ {
+ if (tests[i].references(var))
+ return true;
+ }
+ return false;
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer();
+ switch (axis)
+ {
+ case ANCESTOR:
+ buf.append("ancestor::");
+ break;
+ case ANCESTOR_OR_SELF:
+ buf.append("ancestor-or-self::");
+ break;
+ case ATTRIBUTE:
+ if (tests.length == 0 ||
+ (tests[0] instanceof NameTest))
+ buf.append('@');
+ else
+ buf.append("attribute::");
+ break;
+ case CHILD:
+ //buf.append("child::");
+ break;
+ case DESCENDANT:
+ buf.append("descendant::");
+ break;
+ case DESCENDANT_OR_SELF:
+ buf.append("descendant-or-self::");
+ break;
+ case FOLLOWING:
+ buf.append("following::");
+ break;
+ case FOLLOWING_SIBLING:
+ buf.append("following-sibling::");
+ break;
+ case NAMESPACE:
+ buf.append("namespace::");
+ break;
+ case PARENT:
+ if (tests.length == 0 ||
+ (tests[0] instanceof NodeTypeTest &&
+ ((NodeTypeTest) tests[0]).type == 0))
+ return "..";
+ buf.append("parent::");
+ break;
+ case PRECEDING:
+ buf.append("preceding::");
+ break;
+ case PRECEDING_SIBLING:
+ buf.append("preceding-sibling::");
+ break;
+ case SELF:
+ if (tests.length == 0 ||
+ (tests[0] instanceof NodeTypeTest &&
+ ((NodeTypeTest) tests[0]).type == 0))
+ return ".";
+ buf.append("self::");
+ break;
+ }
+ if (tests.length == 0)
+ buf.append("[error]");
+ else
+ {
+ for (int i = 0; i < tests.length; i++)
+ buf.append(tests[i]);
+ }
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StartsWithFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StartsWithFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StartsWithFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StartsWithFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,92 @@
+/* StartsWithFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>starts-with</code> function returns true if the first argument
+ * string starts with the second argument string, and otherwise returns false.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class StartsWithFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+
+ StartsWithFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1));
+ }
+
+ StartsWithFunction(Expr arg1, Expr arg2)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ String s1 = _string(context, val1);
+ String s2 = _string(context, val2);
+ return s1.startsWith(s2) ? Boolean.TRUE : Boolean.FALSE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new StartsWithFunction(arg1.clone(context), arg2.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var));
+ }
+
+ public String toString()
+ {
+ return "starts-with(" + arg1 + "," + arg2 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Steps.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Steps.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Steps.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Steps.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,253 @@
+/* Steps.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.LinkedHashSet;
+import java.util.LinkedList;
+import java.util.Set;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Attr;
+import org.w3c.dom.Node;
+
+/**
+ * A list of transitions between components in a location path.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class Steps
+ extends Path
+{
+
+ final LinkedList path;
+
+ public Steps()
+ {
+ this(new LinkedList());
+ }
+
+ Steps(LinkedList path)
+ {
+ this.path = path;
+ }
+
+ public boolean matches(Node context)
+ {
+ // Right to left
+ return matches(context, path.size() - 1);
+ }
+
+ boolean matches(Node context, int pos)
+ {
+ Pattern right = (Pattern) path.get(pos);
+ if (!right.matches(context))
+ {
+ return false;
+ }
+ if (pos > 0)
+ {
+ Pattern left = (Pattern) path.get(pos - 1);
+ Iterator j = possibleContexts(right, context).iterator();
+ while (j.hasNext())
+ {
+ Node candidate = (Node) j.next();
+ if (left.matches(candidate) &&
+ matches(candidate, pos - 1))
+ {
+ return true;
+ }
+ // keep going, there may be another candidate
+ }
+ return false;
+ }
+ return true;
+ }
+
+ /**
+ * Essentially the reverse of Selector.addCandidates.
+ * The idea is to determine possible context nodes for a match.
+ */
+ Collection possibleContexts(Pattern pattern, Node context)
+ {
+ if (pattern instanceof Selector)
+ {
+ Selector s = (Selector) pattern;
+ Collection candidates = new LinkedHashSet();
+ switch (s.axis)
+ {
+ case Selector.PARENT:
+ s.addChildNodes(context, candidates, false);
+ break;
+ case Selector.ANCESTOR:
+ s.addChildNodes(context, candidates, true);
+ break;
+ case Selector.ANCESTOR_OR_SELF:
+ candidates.add (context);
+ s.addChildNodes(context, candidates, true);
+ break;
+ case Selector.CHILD:
+ s.addParentNode(context, candidates, false);
+ break;
+ case Selector.DESCENDANT:
+ s.addParentNode(context, candidates, true);
+ break;
+ case Selector.DESCENDANT_OR_SELF:
+ candidates.add(context);
+ s.addParentNode(context, candidates, true);
+ break;
+ case Selector.PRECEDING_SIBLING:
+ s.addFollowingNodes(context, candidates, false);
+ break;
+ case Selector.FOLLOWING_SIBLING:
+ s.addPrecedingNodes(context, candidates, false);
+ break;
+ case Selector.PRECEDING:
+ s.addFollowingNodes(context, candidates, true);
+ break;
+ case Selector.FOLLOWING:
+ s.addPrecedingNodes(context, candidates, true);
+ break;
+ case Selector.ATTRIBUTE:
+ case Selector.NAMESPACE:
+ if (context.getNodeType() == Node.ATTRIBUTE_NODE)
+ {
+ candidates.add(((Attr) context).getOwnerElement());
+ }
+ break;
+ case Selector.SELF:
+ candidates.add(context);
+ break;
+ }
+ return candidates;
+ }
+ return Collections.EMPTY_SET;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ //System.err.println(toString()+" evaluate");
+ // Left to right
+ Iterator i = path.iterator();
+ Expr lhs = (Expr) i.next();
+ Object val = lhs.evaluate(context, pos, len);
+ //System.err.println("\tevaluate "+lhs+" = "+val);
+ while (val instanceof Collection && i.hasNext())
+ {
+ Path rhs = (Path) i.next();
+ val = rhs.evaluate(context, (Collection) val);
+ //System.err.println("\tevaluate "+rhs+" = "+val);
+ }
+ return val;
+ }
+
+ Collection evaluate(Node context, Collection ns)
+ {
+ // Left to right
+ Iterator i = path.iterator();
+ Expr lhs = (Expr) i.next();
+ if (lhs instanceof Path)
+ {
+ ns = ((Path) lhs).evaluate(context, ns);
+ }
+ else
+ {
+ Set acc = new LinkedHashSet();
+ int pos = 1, len = ns.size();
+ for (Iterator j = ns.iterator(); j.hasNext(); )
+ {
+ Node node = (Node) j.next();
+ Object ret = lhs.evaluate(node, pos++, len);
+ if (ret instanceof Collection)
+ {
+ acc.addAll((Collection) ret);
+ }
+ }
+ ns = acc;
+ }
+ while (i.hasNext())
+ {
+ Path rhs = (Path) i.next();
+ ns = rhs.evaluate(context, ns);
+ }
+ return ns;
+ }
+
+ public Expr clone(Object context)
+ {
+ int len = path.size();
+ LinkedList path2 = new LinkedList();
+ for (int i = 0; i < len; i++)
+ {
+ path2.add(((Expr) path.get(i)).clone(context));
+ }
+ return new Steps(path2);
+ }
+
+ public boolean references(QName var)
+ {
+ for (Iterator i = path.iterator(); i.hasNext(); )
+ {
+ if (((Expr) i.next()).references(var))
+ {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer();
+ Iterator i = path.iterator();
+ Expr expr = (Expr) i.next();
+ if (!(expr instanceof Root))
+ {
+ buf.append(expr);
+ }
+ while (i.hasNext())
+ {
+ expr = (Expr) i.next();
+ buf.append('/');
+ buf.append(expr);
+ }
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,119 @@
+/* StringFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>string function converts an object to a string as follows:
+ * <ul>
+ * <li>A node-set is converted to a string by returning the string-value of
+ * the node in the node-set that is first in document order. If the node-set
+ * is empty, an empty string is returned.</li>
+ * <li>A number is converted to a string as follows
+ * <ul>
+ * <li>NaN is converted to the string NaN</li>
+ * <li>positive zero is converted to the string 0</li>
+ * <li>negative zero is converted to the string 0</li>
+ * <li>positive infinity is converted to the string Infinity</li>
+ * <li>negative infinity is converted to the string -Infinity</li>
+ * <li>if the number is an integer, the number is represented in decimal
+ * form as a Number with no decimal point and no leading zeros, preceded by
+ * a minus sign (-) if the number is negative</li>
+ * <li>otherwise, the number is represented in decimal form as a Number
+ * including a decimal point with at least one digit before the decimal
+ * point and at least one digit after the decimal point, preceded by a minus
+ * sign (-) if the number is negative; there must be no leading zeros before
+ * the decimal point apart possibly from the one required digit immediately
+ * before the decimal point; beyond the one required digit after the decimal
+ * point there must be as many, but only as many, more digits as are needed
+ * to uniquely distinguish the number from all other IEEE 754 numeric
+ * values.</li>
+ * </ul>
+ * </li>
+ * <li>The boolean false value is converted to the string false. The boolean
+ * true value is converted to the string true.</li>
+ * <li>An object of a type other than the four basic types is converted to a
+ * string in a way that is dependent on that type.</li>
+ * </ul>
+ * If the argument is omitted, it defaults to a node-set with the context
+ * node as its only member.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class StringFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ StringFunction(List args)
+ {
+ this(args.size() > 0 ? (Expr) args.get(0) : null);
+ }
+
+ StringFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? null : arg.evaluate(context, pos, len);
+ return _string(context, val);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new StringFunction((arg == null) ? null :
+ arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "string()" : "string(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringLengthFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringLengthFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringLengthFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/StringLengthFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,91 @@
+/* StringLengthFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>string-length</code> function returns the number of characters
+ * in the string.
+ * If the argument is omitted, it defaults to the context node converted to
+ * a string, in other words the string-value of the context node.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class StringLengthFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ StringLengthFunction(List args)
+ {
+ this(args.isEmpty() ? null : (Expr) args.get(0));
+ }
+
+ StringLengthFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = (arg == null) ? null : arg.evaluate(context, pos, len);
+ String s = _string(context, val);
+ return new Double((double) s.length());
+ }
+
+ public Expr clone(Object context)
+ {
+ return new StringLengthFunction((arg == null) ? null :
+ arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg == null) ? false : arg.references(var);
+ }
+
+ public String toString()
+ {
+ return (arg == null) ? "string-length()" : "string-length(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringAfterFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringAfterFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringAfterFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringAfterFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,98 @@
+/* SubstringAfterFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>substring-after</code> function returns the substring of the
+ * first argument string that follows the first occurrence of the second
+ * argument string in the first argument string, or the empty string if the
+ * first argument string does not contain the second argument string. For
+ * example, substring-after("1999/04/01","/") returns 04/01, and
+ * substring-after("1999/04/01","19") returns 99/04/01.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class SubstringAfterFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+
+ SubstringAfterFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1));
+ }
+
+ SubstringAfterFunction(Expr arg1, Expr arg2)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ String s1 = _string(context, val1);
+ String s2 = _string(context, val2);
+ int index = s1.indexOf(s2);
+ return (index == -1) ? "" : s1.substring(index + s2.length());
+ }
+
+ public Expr clone(Object context)
+ {
+ return new SubstringAfterFunction(arg1.clone(context),
+ arg2.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var));
+ }
+
+ public String toString()
+ {
+ return "substring-after(" + arg1 + "," + arg2 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringBeforeFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringBeforeFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringBeforeFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringBeforeFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,97 @@
+/* SubstringBeforeFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>substring-before</code> function returns the substring of the
+ * first argument string that precedes the first occurrence of the second
+ * argument string in the first argument string, or the empty string if the
+ * first argument string does not contain the second argument string. For
+ * example, substring-before("1999/04/01","/") returns 1999.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class SubstringBeforeFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+
+ SubstringBeforeFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1));
+ }
+
+ SubstringBeforeFunction(Expr arg1, Expr arg2)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ String s1 = _string(context, val1);
+ String s2 = _string(context, val2);
+ int index = s1.indexOf(s2);
+ return (index == -1) ? "" : s1.substring(0, index);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new SubstringBeforeFunction(arg1.clone(context),
+ arg2.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var));
+ }
+
+ public String toString()
+ {
+ return "substring-before(" + arg1 + "," + arg2 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SubstringFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,118 @@
+/* SubstringFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The substring function returns the substring of the first argument
+ * starting at the position specified in the second argument with length
+ * specified in the third argument. For example, substring("12345",2,3)
+ * returns "234". If the third argument is not specified, it returns the
+ * substring starting at the position specified in the second argument and
+ * continuing to the end of the string. For example, substring("12345",2)
+ * returns "2345".
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class SubstringFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+ final Expr arg3;
+
+ SubstringFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1),
+ (args.size() > 2) ? (Expr) args.get(2) : null);
+ }
+
+ SubstringFunction(Expr arg1, Expr arg2, Expr arg3)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ this.arg3 = arg3;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ String s = _string(context, val1);
+ int p = Expr.intValue(val2) - 1;
+ if (p < 0)
+ p = 0;
+
+ int l = s.length() - p;
+ if (l <= 0)
+ return "";
+
+ if (arg3 != null)
+ {
+ Object val3 = arg3.evaluate(context, pos, len);
+ int v3 = Expr.intValue(val3);
+ if (v3 < l)
+ l = v3;
+ }
+
+ return s.substring(p, p + l);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new SubstringFunction(arg1.clone(context), arg2.clone(context),
+ (arg3 == null) ? null : arg3.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var) ||
+ (arg3 == null) ? false : arg3.references(var));
+ }
+
+ public String toString()
+ {
+ return (arg3 == null) ? "substring(" + arg1 + "," + arg2 + ")" :
+ "substring(" + arg1 + "," + arg2 + "," + arg3 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SumFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SumFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SumFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/SumFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,100 @@
+/* SumFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>sum</code> function returns the sum, for each node in the
+ * argument node-set, of the result of converting the string-values of the
+ * node to a number.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class SumFunction
+ extends Expr
+{
+
+ final Expr arg;
+
+ SumFunction(List args)
+ {
+ this((Expr) args.get(0));
+ }
+
+ SumFunction(Expr arg)
+ {
+ this.arg = arg;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val = arg.evaluate(context, pos, len);
+ double sum = 0.0d;
+ if (val instanceof Collection)
+ {
+ for (Iterator i = ((Collection) val).iterator(); i.hasNext(); )
+ {
+ Node node = (Node) i.next();
+ String s = stringValue(node);
+ sum += _number(context, s);
+ }
+ }
+ return new Double(sum);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new SumFunction(arg.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return arg.references(var);
+ }
+
+ public String toString()
+ {
+ return "sum(" + arg + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Test.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Test.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Test.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/Test.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,58 @@
+/* Test.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * A test that can be performed on a node to determine whether to include it
+ * in a selection.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public abstract class Test
+{
+
+ public abstract boolean matches(Node node, int pos, int len);
+
+ public abstract Test clone(Object context);
+
+ public abstract boolean references(QName var);
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TranslateFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TranslateFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TranslateFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TranslateFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,133 @@
+/* TranslateFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.List;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>translate</code> function returns the first argument string
+ * with occurrences of characters in the second argument string replaced by
+ * the character at the corresponding position in the third argument string.
+ * For example, translate("bar","abc","ABC") returns the string BAr. If
+ * there is a character in the second argument string with no character at a
+ * corresponding position in the third argument string (because the second
+ * argument string is longer than the third argument string), then
+ * occurrences of that character in the first argument string are removed.
+ * For example, translate("--aaa--","abc-","ABC") returns "AAA". If a
+ * character occurs more than once in the second argument string, then the
+ * first occurrence determines the replacement character. If the third
+ * argument string is longer than the second argument string, then excess
+ * characters are ignored.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class TranslateFunction
+ extends Expr
+{
+
+ final Expr arg1;
+ final Expr arg2;
+ final Expr arg3;
+
+ TranslateFunction(List args)
+ {
+ this((Expr) args.get(0), (Expr) args.get(1), (Expr) args.get(2));
+ }
+
+ TranslateFunction(Expr arg1, Expr arg2, Expr arg3)
+ {
+ this.arg1 = arg1;
+ this.arg2 = arg2;
+ this.arg3 = arg3;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object val1 = arg1.evaluate(context, pos, len);
+ Object val2 = arg2.evaluate(context, pos, len);
+ Object val3 = arg3.evaluate(context, pos, len);
+ String string = _string(context, val1);
+ String search = _string(context, val2);
+ String replace = _string(context, val3);
+ StringBuffer buf = new StringBuffer();
+ int l1 = string.length();
+ int l2 = search.length();
+ int l3 = replace.length();
+ for (int i = 0; i < l1; i++)
+ {
+ char c = string.charAt(i);
+ boolean replaced = false;
+ for (int j = 0; j < l2; j++)
+ {
+ if (c == search.charAt(j))
+ {
+ if (j < l3)
+ {
+ buf.append(replace.charAt(j));
+ }
+ replaced = true;
+ }
+ }
+ if (!replaced)
+ {
+ buf.append(c);
+ }
+ }
+ return new String(buf);
+ }
+
+ public Expr clone(Object context)
+ {
+ return new TranslateFunction(arg1.clone(context), arg2.clone(context),
+ arg3.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (arg1.references(var) || arg2.references(var) ||
+ arg3.references(var));
+ }
+
+ public String toString()
+ {
+ return "translate(" + arg1 + "," + arg2 + "," + arg3 + ")";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TrueFunction.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TrueFunction.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TrueFunction.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/TrueFunction.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,72 @@
+/* TrueFunction.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The <code>true</code> function returns true.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+final class TrueFunction
+ extends Expr
+{
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ return Boolean.TRUE;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new TrueFunction();
+ }
+
+ public boolean references(QName var)
+ {
+ return false;
+ }
+
+ public String toString()
+ {
+ return "true()";
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/UnionExpr.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/UnionExpr.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/UnionExpr.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/UnionExpr.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,108 @@
+/* UnionExpr.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import javax.xml.namespace.QName;
+import org.w3c.dom.Node;
+
+/**
+ * The union of two node-sets.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public final class UnionExpr
+ extends Pattern
+{
+
+ final Expr lhs;
+ final Expr rhs;
+
+ public UnionExpr(Expr lhs, Expr rhs)
+ {
+ this.lhs = lhs;
+ this.rhs = rhs;
+ }
+
+ public boolean matches(Node context)
+ {
+ if (lhs instanceof Pattern && rhs instanceof Pattern)
+ {
+ return ((Pattern) lhs).matches(context) ||
+ ((Pattern) rhs).matches(context);
+ }
+ return false;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ Object left = lhs.evaluate(context, pos, len);
+ Object right = rhs.evaluate(context, pos, len);
+ if (left instanceof Collection && right instanceof Collection)
+ {
+ Set set = new HashSet();
+ set.addAll ((Collection) left);
+ set.addAll ((Collection) right);
+ List list = new ArrayList(set);
+ Collections.sort(list, documentOrderComparator);
+ return list;
+ }
+ return Collections.EMPTY_SET;
+ }
+
+ public Expr clone(Object context)
+ {
+ return new UnionExpr(lhs.clone(context), rhs.clone(context));
+ }
+
+ public boolean references(QName var)
+ {
+ return (lhs.references(var) || rhs.references(var));
+ }
+
+ public String toString()
+ {
+ return lhs + " | " + rhs;
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/VariableReference.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/VariableReference.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/VariableReference.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/VariableReference.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,100 @@
+/* VariableReference.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.namespace.QName;
+import javax.xml.xpath.XPathVariableResolver;
+import org.w3c.dom.Node;
+import gnu.xml.transform.Bindings;
+
+public class VariableReference
+ extends Expr
+{
+
+ final XPathVariableResolver resolver;
+ final QName name;
+
+ public VariableReference(XPathVariableResolver resolver, QName name)
+ {
+ this.resolver = resolver;
+ this.name = name;
+ }
+
+ public Object evaluate(Node context, int pos, int len)
+ {
+ if (resolver != null)
+ {
+ if (resolver instanceof Bindings)
+ {
+ // Needs context to operate properly
+ return ((Bindings) resolver).get(name, context, pos, len);
+ }
+ return resolver.resolveVariable(name);
+ }
+ throw new IllegalStateException("no variable resolver");
+ }
+
+ public Expr clone(Object context)
+ {
+ XPathVariableResolver r = resolver;
+ if (context instanceof XPathVariableResolver)
+ {
+ r = (XPathVariableResolver) context;
+ }
+ return new VariableReference(r, name);
+ }
+
+ public boolean references(QName var)
+ {
+ return name.equals(var);
+ }
+
+ public String toString()
+ {
+ StringBuffer buf = new StringBuffer("$");
+ String prefix = name.getPrefix();
+ if (prefix != null && !"".equals(prefix))
+ {
+ buf.append(prefix);
+ buf.append(':');
+ }
+ buf.append(name.getLocalPart());
+ return buf.toString();
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathFactoryImpl.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathFactoryImpl.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathFactoryImpl.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathFactoryImpl.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,90 @@
+/* XPathFactoryImpl.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import javax.xml.xpath.XPath;
+import javax.xml.xpath.XPathFactory;
+import javax.xml.xpath.XPathFactoryConfigurationException;
+import javax.xml.xpath.XPathFunctionResolver;
+import javax.xml.xpath.XPathVariableResolver;
+
+/**
+ * GNU XPath factory implementation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XPathFactoryImpl
+ extends XPathFactory
+{
+
+ XPathVariableResolver variableResolver;
+ XPathFunctionResolver functionResolver;
+
+ public boolean isObjectModelSupported(String objectModel)
+ {
+ return XPathFactory.DEFAULT_OBJECT_MODEL_URI.equals(objectModel);
+ }
+
+ public void setFeature(String name, boolean value)
+ throws XPathFactoryConfigurationException
+ {
+ throw new XPathFactoryConfigurationException(name);
+ }
+
+ public boolean getFeature(String name)
+ throws XPathFactoryConfigurationException
+ {
+ throw new XPathFactoryConfigurationException(name);
+ }
+
+ public void setXPathVariableResolver(XPathVariableResolver resolver)
+ {
+ variableResolver = resolver;
+ }
+
+ public void setXPathFunctionResolver(XPathFunctionResolver resolver)
+ {
+ functionResolver = resolver;
+ }
+
+ public XPath newXPath()
+ {
+ return new XPathImpl(null, variableResolver, functionResolver);
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathImpl.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathImpl.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathImpl.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathImpl.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,164 @@
+/* XPathImpl.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.io.IOException;
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+import javax.xml.xpath.XPath;
+import javax.xml.xpath.XPathExpression;
+import javax.xml.xpath.XPathExpressionException;
+import javax.xml.xpath.XPathFunctionResolver;
+import javax.xml.xpath.XPathVariableResolver;
+import org.xml.sax.InputSource;
+
+/**
+ * JAXP XPath implementation.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XPathImpl
+ implements XPath
+{
+
+ XPathParser parser;
+ NamespaceContext namespaceContext;
+ XPathVariableResolver variableResolver;
+ XPathFunctionResolver functionResolver;
+
+ XPathImpl(NamespaceContext namespaceContext,
+ XPathVariableResolver variableResolver,
+ XPathFunctionResolver functionResolver)
+ {
+ parser = new XPathParser();
+ this.namespaceContext = namespaceContext;
+ this.variableResolver = variableResolver;
+ this.functionResolver = functionResolver;
+ reset();
+ }
+
+ public void reset()
+ {
+ parser.namespaceContext = namespaceContext;
+ parser.variableResolver = variableResolver;
+ parser.functionResolver = functionResolver;
+ }
+
+ public void setXPathVariableResolver(XPathVariableResolver resolver)
+ {
+ parser.variableResolver = resolver;
+ }
+
+ public XPathVariableResolver getXPathVariableResolver()
+ {
+ return parser.variableResolver;
+ }
+
+ public void setXPathFunctionResolver(XPathFunctionResolver resolver)
+ {
+ parser.functionResolver = resolver;
+ }
+
+ public XPathFunctionResolver getXPathFunctionResolver()
+ {
+ return parser.functionResolver;
+ }
+
+ public void setNamespaceContext(NamespaceContext nsContext)
+ {
+ parser.namespaceContext = nsContext;
+ }
+
+ public NamespaceContext getNamespaceContext()
+ {
+ return parser.namespaceContext;
+ }
+
+ public XPathExpression compile(String expression)
+ throws XPathExpressionException
+ {
+ XPathTokenizer tokenizer = new XPathTokenizer(expression);
+ try
+ {
+ return (Expr) parser.yyparse(tokenizer);
+ }
+ catch (IOException e)
+ {
+ throw new XPathExpressionException(e);
+ }
+ catch (XPathParser.yyException e)
+ {
+ throw new XPathExpressionException(expression);
+ }
+ }
+
+ public Object evaluate(String expression,
+ Object item,
+ QName returnType)
+ throws XPathExpressionException
+ {
+ XPathExpression expr = compile(expression);
+ return expr.evaluate(item, returnType);
+ }
+
+ public String evaluate(String expression,
+ Object item)
+ throws XPathExpressionException
+ {
+ XPathExpression expr = compile(expression);
+ return expr.evaluate(item);
+ }
+
+ public Object evaluate(String expression,
+ InputSource source,
+ QName returnType)
+ throws XPathExpressionException
+ {
+ XPathExpression expr = compile(expression);
+ return expr.evaluate(source, returnType);
+ }
+
+ public String evaluate(String expression,
+ InputSource source)
+ throws XPathExpressionException
+ {
+ XPathExpression expr = compile(expression);
+ return expr.evaluate(source);
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,1464 @@
+// created by jay 0.8 (c) 1998 Axel.Schreiner at informatik.uni-osnabrueck.de
+
+ // line 2 "XPathParser.y"
+/* XPathParser.y - An XPath 1.0 parser.
+ Copyright (C) 2004 The Free Software Foundation
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+import javax.xml.xpath.XPathFunctionResolver;
+import javax.xml.xpath.XPathVariableResolver;
+import org.w3c.dom.Node;
+
+/**
+ * An XPath 1.0 parser.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XPathParser
+{
+
+ NamespaceContext namespaceContext;
+ XPathVariableResolver variableResolver;
+ XPathFunctionResolver functionResolver;
+
+ QName getQName(String name)
+ {
+ QName qName = QName.valueOf(name);
+ if (namespaceContext != null)
+ {
+ String prefix = qName.getPrefix();
+ String uri = qName.getNamespaceURI();
+ if (prefix != null && (uri == null || uri.length() == 0))
+ {
+ uri = namespaceContext.getNamespaceURI(prefix);
+ String localName = qName.getLocalPart();
+ qName = new QName(uri, localName, prefix);
+ }
+ }
+ return qName;
+ }
+
+ Expr lookupFunction(String name, List args)
+ {
+ int arity = args.size();
+ if ("position".equals(name) && arity == 0)
+ {
+ return new PositionFunction();
+ }
+ else if ("last".equals(name) && arity == 0)
+ {
+ return new LastFunction();
+ }
+ else if ("string".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new StringFunction(args);
+ }
+ else if ("number".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NumberFunction(args);
+ }
+ else if ("boolean".equals(name) && arity == 1)
+ {
+ return new BooleanFunction(args);
+ }
+ else if ("count".equals(name) && arity == 1)
+ {
+ return new CountFunction(args);
+ }
+ else if ("not".equals(name) && arity == 1)
+ {
+ return new NotFunction(args);
+ }
+ else if ("id".equals(name) && arity == 1)
+ {
+ return new IdFunction(args);
+ }
+ else if ("concat".equals(name) && arity > 1)
+ {
+ return new ConcatFunction(args);
+ }
+ else if ("true".equals(name) && arity == 0)
+ {
+ return new TrueFunction();
+ }
+ else if ("false".equals(name) && arity == 0)
+ {
+ return new FalseFunction();
+ }
+ else if ("name".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NameFunction(args);
+ }
+ else if ("local-name".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new LocalNameFunction(args);
+ }
+ else if ("namespace-uri".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NamespaceUriFunction(args);
+ }
+ else if ("starts-with".equals(name) && arity == 2)
+ {
+ return new StartsWithFunction(args);
+ }
+ else if ("contains".equals(name) && arity == 2)
+ {
+ return new ContainsFunction(args);
+ }
+ else if ("string-length".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new StringLengthFunction(args);
+ }
+ else if ("translate".equals(name) && arity == 3)
+ {
+ return new TranslateFunction(args);
+ }
+ else if ("normalize-space".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NormalizeSpaceFunction(args);
+ }
+ else if ("substring".equals(name) && (arity == 2 || arity == 3))
+ {
+ return new SubstringFunction(args);
+ }
+ else if ("substring-before".equals(name) && arity == 2)
+ {
+ return new SubstringBeforeFunction(args);
+ }
+ else if ("substring-after".equals(name) && arity == 2)
+ {
+ return new SubstringAfterFunction(args);
+ }
+ else if ("lang".equals(name) && arity == 1)
+ {
+ return new LangFunction(args);
+ }
+ else if ("sum".equals(name) && arity == 1)
+ {
+ return new SumFunction(args);
+ }
+ else if ("floor".equals(name) && arity == 1)
+ {
+ return new FloorFunction(args);
+ }
+ else if ("ceiling".equals(name) && arity == 1)
+ {
+ return new CeilingFunction(args);
+ }
+ else if ("round".equals(name) && arity == 1)
+ {
+ return new RoundFunction(args);
+ }
+ else if (functionResolver != null)
+ {
+ QName qName = QName.valueOf(name);
+ Object function = functionResolver.resolveFunction(qName, arity);
+ if (function != null &&
+ function instanceof Function &&
+ function instanceof Expr)
+ {
+ Function f = (Function) function;
+ f.setArguments(args);
+ return (Expr) function;
+ }
+ }
+ return new FunctionCall(functionResolver, name, args);
+ }
+
+ // line 211 "-"
+// %token constants
+
+ public static final int LITERAL = 257;
+ public static final int DIGITS = 258;
+ public static final int NAME = 259;
+ public static final int LP = 260;
+ public static final int RP = 261;
+ public static final int LB = 262;
+ public static final int RB = 263;
+ public static final int COMMA = 264;
+ public static final int PIPE = 265;
+ public static final int SLASH = 266;
+ public static final int DOUBLE_SLASH = 267;
+ public static final int EQ = 268;
+ public static final int NE = 269;
+ public static final int GT = 270;
+ public static final int LT = 271;
+ public static final int GTE = 272;
+ public static final int LTE = 273;
+ public static final int PLUS = 274;
+ public static final int MINUS = 275;
+ public static final int AT = 276;
+ public static final int STAR = 277;
+ public static final int DOLLAR = 278;
+ public static final int COLON = 279;
+ public static final int DOUBLE_COLON = 280;
+ public static final int DOT = 281;
+ public static final int DOUBLE_DOT = 282;
+ public static final int ANCESTOR = 283;
+ public static final int ANCESTOR_OR_SELF = 284;
+ public static final int ATTRIBUTE = 285;
+ public static final int CHILD = 286;
+ public static final int DESCENDANT = 287;
+ public static final int DESCENDANT_OR_SELF = 288;
+ public static final int FOLLOWING = 289;
+ public static final int FOLLOWING_SIBLING = 290;
+ public static final int NAMESPACE = 291;
+ public static final int PARENT = 292;
+ public static final int PRECEDING = 293;
+ public static final int PRECEDING_SIBLING = 294;
+ public static final int SELF = 295;
+ public static final int DIV = 296;
+ public static final int MOD = 297;
+ public static final int OR = 298;
+ public static final int AND = 299;
+ public static final int COMMENT = 300;
+ public static final int PROCESSING_INSTRUCTION = 301;
+ public static final int TEXT = 302;
+ public static final int NODE = 303;
+ public static final int UNARY = 304;
+ public static final int yyErrorCode = 256;
+
+ /** thrown for irrecoverable syntax errors and stack overflow.
+ */
+ public static class yyException extends java.lang.Exception {
+ public yyException (String message) {
+ super(message);
+ }
+ }
+
+ /** must be implemented by a scanner object to supply input to the parser.
+ */
+ public interface yyInput {
+ /** move on to next token.
+ @return false if positioned beyond tokens.
+ @throws IOException on input error.
+ */
+ boolean advance () throws java.io.IOException;
+ /** classifies current token.
+ Should not be called if advance() returned false.
+ @return current %token or single character.
+ */
+ int token ();
+ /** associated with current token.
+ Should not be called if advance() returned false.
+ @return value for token().
+ */
+ Object value ();
+ }
+
+ /** simplified error message.
+ @see <a href="#yyerror(java.lang.String, java.lang.String[])">yyerror</a>
+ */
+ public void yyerror (String message) {
+ yyerror(message, null);
+ }
+
+ /** (syntax) error message.
+ Can be overwritten to control message format.
+ @param message text to be displayed.
+ @param expected vector of acceptable tokens, if available.
+ */
+ public void yyerror (String message, String[] expected) {
+ if (expected != null && expected.length > 0) {
+ System.err.print(message+", expecting");
+ for (int n = 0; n < expected.length; ++ n)
+ System.err.print(" "+expected[n]);
+ System.err.println();
+ } else
+ System.err.println(message);
+ }
+
+ /** debugging support, requires the package jay.yydebug.
+ Set to null to suppress debugging messages.
+ */
+//t protected jay.yydebug.yyDebug yydebug;
+
+ protected static final int yyFinal = 30;
+
+ /** index-checked interface to yyName[].
+ @param token single character or %token value.
+ @return token name or [illegal] or [unknown].
+ */
+//t public static final String yyname (int token) {
+//t if (token < 0 || token > YyNameClass.yyName.length) return "[illegal]";
+//t String name;
+//t if ((name = YyNameClass.yyName[token]) != null) return name;
+//t return "[unknown]";
+//t }
+
+ /** computes list of expected tokens on error by tracing the tables.
+ @param state for which to compute the list.
+ @return list of token names.
+ */
+ protected String[] yyExpecting (int state) {
+ int token, n, len = 0;
+ boolean[] ok = new boolean[YyNameClass.yyName.length];
+
+ if ((n = YySindexClass.yySindex[state]) != 0)
+ for (token = n < 0 ? -n : 0;
+ token < YyNameClass.yyName.length && n+token < YyTableClass.yyTable.length; ++ token)
+ if (YyCheckClass.yyCheck[n+token] == token && !ok[token] && YyNameClass.yyName[token] != null) {
+ ++ len;
+ ok[token] = true;
+ }
+ if ((n = YyRindexClass.yyRindex[state]) != 0)
+ for (token = n < 0 ? -n : 0;
+ token < YyNameClass.yyName.length && n+token < YyTableClass.yyTable.length; ++ token)
+ if (YyCheckClass.yyCheck[n+token] == token && !ok[token] && YyNameClass.yyName[token] != null) {
+ ++ len;
+ ok[token] = true;
+ }
+
+ String result[] = new String[len];
+ for (n = token = 0; n < len; ++ token)
+ if (ok[token]) result[n++] = YyNameClass.yyName[token];
+ return result;
+ }
+
+ /** the generated parser, with debugging messages.
+ Maintains a state and a value stack, currently with fixed maximum size.
+ @param yyLex scanner.
+ @param yydebug debug message writer implementing yyDebug, or null.
+ @return result of the last reduction, if any.
+ @throws yyException on irrecoverable parse error.
+ */
+ public Object yyparse (yyInput yyLex, Object yydebug)
+ throws java.io.IOException, yyException {
+//t this.yydebug = (jay.yydebug.yyDebug)yydebug;
+ return yyparse(yyLex);
+ }
+
+ /** initial size and increment of the state/value stack [default 256].
+ This is not final so that it can be overwritten outside of invocations
+ of yyparse().
+ */
+ protected int yyMax;
+
+ /** executed at the beginning of a reduce action.
+ Used as $$ = yyDefault($1), prior to the user-specified action, if any.
+ Can be overwritten to provide deep copy, etc.
+ @param first value for $1, or null.
+ @return first.
+ */
+ protected Object yyDefault (Object first) {
+ return first;
+ }
+
+ /** the generated parser.
+ Maintains a state and a value stack, currently with fixed maximum size.
+ @param yyLex scanner.
+ @return result of the last reduction, if any.
+ @throws yyException on irrecoverable parse error.
+ */
+ public Object yyparse (yyInput yyLex)
+ throws java.io.IOException, yyException {
+ if (yyMax <= 0) yyMax = 256; // initial size
+ int yyState = 0, yyStates[] = new int[yyMax]; // state stack
+ Object yyVal = null, yyVals[] = new Object[yyMax]; // value stack
+ int yyToken = -1; // current input
+ int yyErrorFlag = 0; // #tks to shift
+
+ yyLoop: for (int yyTop = 0;; ++ yyTop) {
+ if (yyTop >= yyStates.length) { // dynamically increase
+ int[] i = new int[yyStates.length+yyMax];
+ System.arraycopy(yyStates, 0, i, 0, yyStates.length);
+ yyStates = i;
+ Object[] o = new Object[yyVals.length+yyMax];
+ System.arraycopy(yyVals, 0, o, 0, yyVals.length);
+ yyVals = o;
+ }
+ yyStates[yyTop] = yyState;
+ yyVals[yyTop] = yyVal;
+//t if (yydebug != null) yydebug.push(yyState, yyVal);
+
+ yyDiscarded: for (;;) { // discarding a token does not change stack
+ int yyN;
+ if ((yyN = YyDefRedClass.yyDefRed[yyState]) == 0) { // else [default] reduce (yyN)
+ if (yyToken < 0) {
+ yyToken = yyLex.advance() ? yyLex.token() : 0;
+//t if (yydebug != null)
+//t yydebug.lex(yyState, yyToken, yyname(yyToken), yyLex.value());
+ }
+ if ((yyN = YySindexClass.yySindex[yyState]) != 0 && (yyN += yyToken) >= 0
+ && yyN < YyTableClass.yyTable.length && YyCheckClass.yyCheck[yyN] == yyToken) {
+//t if (yydebug != null)
+//t yydebug.shift(yyState, YyTableClass.yyTable[yyN], yyErrorFlag-1);
+ yyState = YyTableClass.yyTable[yyN]; // shift to yyN
+ yyVal = yyLex.value();
+ yyToken = -1;
+ if (yyErrorFlag > 0) -- yyErrorFlag;
+ continue yyLoop;
+ }
+ if ((yyN = YyRindexClass.yyRindex[yyState]) != 0 && (yyN += yyToken) >= 0
+ && yyN < YyTableClass.yyTable.length && YyCheckClass.yyCheck[yyN] == yyToken)
+ yyN = YyTableClass.yyTable[yyN]; // reduce (yyN)
+ else
+ switch (yyErrorFlag) {
+
+ case 0:
+ yyerror("syntax error", yyExpecting(yyState));
+//t if (yydebug != null) yydebug.error("syntax error");
+
+ case 1: case 2:
+ yyErrorFlag = 3;
+ do {
+ if ((yyN = YySindexClass.yySindex[yyStates[yyTop]]) != 0
+ && (yyN += yyErrorCode) >= 0 && yyN < YyTableClass.yyTable.length
+ && YyCheckClass.yyCheck[yyN] == yyErrorCode) {
+//t if (yydebug != null)
+//t yydebug.shift(yyStates[yyTop], YyTableClass.yyTable[yyN], 3);
+ yyState = YyTableClass.yyTable[yyN];
+ yyVal = yyLex.value();
+ continue yyLoop;
+ }
+//t if (yydebug != null) yydebug.pop(yyStates[yyTop]);
+ } while (-- yyTop >= 0);
+//t if (yydebug != null) yydebug.reject();
+ throw new yyException("irrecoverable syntax error");
+
+ case 3:
+ if (yyToken == 0) {
+//t if (yydebug != null) yydebug.reject();
+ throw new yyException("irrecoverable syntax error at end-of-file");
+ }
+//t if (yydebug != null)
+//t yydebug.discard(yyState, yyToken, yyname(yyToken),
+//t yyLex.value());
+ yyToken = -1;
+ continue yyDiscarded; // leave stack alone
+ }
+ }
+ int yyV = yyTop + 1-YyLenClass.yyLen[yyN];
+//t if (yydebug != null)
+//t yydebug.reduce(yyState, yyStates[yyV-1], yyN, YyRuleClass.yyRule[yyN], YyLenClass.yyLen[yyN]);
+ yyVal = yyDefault(yyV > yyTop ? null : yyVals[yyV]);
+ switch (yyN) {
+case 4:
+ // line 277 "XPathParser.y"
+ {
+ yyVal = new Root();
+ }
+ break;
+case 5:
+ // line 281 "XPathParser.y"
+ {
+ Steps steps;
+ if (yyVals[0+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[0+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[0+yyTop]);
+ }
+ steps.path.addFirst(new Root());
+ yyVal = steps;
+ /*$$ = new Step(new Root(), (Path) $2);*/
+ }
+ break;
+case 6:
+ // line 297 "XPathParser.y"
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList (nt));
+ Steps steps;
+ if (yyVals[0+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[0+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[0+yyTop]);
+ }
+ steps.path.addFirst(s);
+ steps.path.addFirst(new Root());
+ yyVal = steps;
+ /*Step step = new Step(s, (Path) $2);*/
+ /*$$ = new Step(new Root(), step);*/
+ }
+ break;
+case 8:
+ // line 322 "XPathParser.y"
+ {
+ Steps steps;
+ if (yyVals[-2+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[-2+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[-2+yyTop]);
+ }
+ steps.path.addLast(yyVals[0+yyTop]);
+ yyVal = steps;
+ /*$$ = new Step((Expr) $1, (Path) $3);*/
+ }
+ break;
+case 9:
+ // line 338 "XPathParser.y"
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList (nt));
+ Steps steps;
+ if (yyVals[-2+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[-2+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[-2+yyTop]);
+ }
+ steps.path.addLast(s);
+ steps.path.addLast(yyVals[0+yyTop]);
+ yyVal = steps;
+ /*Step step = new Step(s, (Path) $3);*/
+ /*$$ = new Step((Expr) $1, step);*/
+ }
+ break;
+case 10:
+ // line 362 "XPathParser.y"
+ {
+ yyVal = new Selector (Selector.CHILD, (List) yyVals[0+yyTop]);
+ }
+ break;
+case 11:
+ // line 366 "XPathParser.y"
+ {
+ yyVal = new Selector (Selector.ATTRIBUTE, (List) yyVals[0+yyTop]);
+ }
+ break;
+case 12:
+ // line 370 "XPathParser.y"
+ {
+ yyVal = new Selector (((Integer) yyVals[-2+yyTop]).intValue (), (List) yyVals[0+yyTop]);
+ }
+ break;
+case 13:
+ // line 374 "XPathParser.y"
+ {
+ yyVal = new Selector (Selector.SELF, Collections.EMPTY_LIST);
+ }
+ break;
+case 14:
+ // line 378 "XPathParser.y"
+ {
+ yyVal = new Selector (Selector.PARENT, Collections.EMPTY_LIST);
+ }
+ break;
+case 15:
+ // line 385 "XPathParser.y"
+ {
+ List list = new ArrayList();
+ list.add(yyVals[0+yyTop]);
+ yyVal = list;
+ }
+ break;
+case 16:
+ // line 391 "XPathParser.y"
+ {
+ List list = (List)yyVals[-1+yyTop];
+ list.add(yyVals[0+yyTop]);
+ yyVal = list;
+ }
+ break;
+case 17:
+ // line 415 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.ANCESTOR);
+ }
+ break;
+case 18:
+ // line 419 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.ANCESTOR_OR_SELF);
+ }
+ break;
+case 19:
+ // line 423 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.ATTRIBUTE);
+ }
+ break;
+case 20:
+ // line 427 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.CHILD);
+ }
+ break;
+case 21:
+ // line 431 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.DESCENDANT);
+ }
+ break;
+case 22:
+ // line 435 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.DESCENDANT_OR_SELF);
+ }
+ break;
+case 23:
+ // line 439 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.FOLLOWING);
+ }
+ break;
+case 24:
+ // line 443 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.FOLLOWING_SIBLING);
+ }
+ break;
+case 25:
+ // line 447 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.NAMESPACE);
+ }
+ break;
+case 26:
+ // line 451 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.PARENT);
+ }
+ break;
+case 27:
+ // line 455 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.PRECEDING);
+ }
+ break;
+case 28:
+ // line 459 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.PRECEDING_SIBLING);
+ }
+ break;
+case 29:
+ // line 463 "XPathParser.y"
+ {
+ yyVal = new Integer(Selector.SELF);
+ }
+ break;
+case 31:
+ // line 472 "XPathParser.y"
+ {
+ yyVal = new NodeTypeTest(Node.PROCESSING_INSTRUCTION_NODE, (String) yyVals[-1+yyTop]);
+ }
+ break;
+case 32:
+ // line 477 "XPathParser.y"
+ {
+ yyVal = new NodeTypeTest(((Short) yyVals[-1+yyTop]).shortValue());
+ }
+ break;
+case 33:
+ // line 484 "XPathParser.y"
+ {
+ yyVal = new Predicate((Expr) yyVals[-1+yyTop]);
+ }
+ break;
+case 35:
+ // line 492 "XPathParser.y"
+ {
+ yyVal = new ParenthesizedExpr((Expr) yyVals[-1+yyTop]);
+ }
+ break;
+case 36:
+ // line 496 "XPathParser.y"
+ {
+ yyVal = new Constant(yyVals[0+yyTop]);
+ }
+ break;
+case 37:
+ // line 500 "XPathParser.y"
+ {
+ yyVal = new Constant(yyVals[0+yyTop]);
+ }
+ break;
+case 39:
+ // line 508 "XPathParser.y"
+ {
+ yyVal = lookupFunction((String) yyVals[-2+yyTop], Collections.EMPTY_LIST);
+ }
+ break;
+case 40:
+ // line 512 "XPathParser.y"
+ {
+ yyVal = lookupFunction((String) yyVals[-3+yyTop], (List) yyVals[-1+yyTop]);
+ }
+ break;
+case 41:
+ // line 519 "XPathParser.y"
+ {
+ List list = new ArrayList();
+ list.add(yyVals[0+yyTop]);
+ yyVal = list;
+ }
+ break;
+case 42:
+ // line 525 "XPathParser.y"
+ {
+ List list = (List) yyVals[0+yyTop];
+ list.add(0, yyVals[-2+yyTop]);
+ yyVal = list;
+ }
+ break;
+case 44:
+ // line 535 "XPathParser.y"
+ {
+ yyVal = new UnionExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop]);
+ }
+ break;
+case 47:
+ // line 544 "XPathParser.y"
+ {
+ Steps steps;
+ if (yyVals[0+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[0+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[0+yyTop]);
+ }
+ steps.path.addFirst(yyVals[-2+yyTop]);
+ yyVal = steps;
+ /*$$ = new Step ((Expr) $1, (Path) $3);*/
+ }
+ break;
+case 48:
+ // line 560 "XPathParser.y"
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList(nt));
+ Steps steps;
+ if (yyVals[0+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[0+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[0+yyTop]);
+ }
+ steps.path.addFirst(s);
+ steps.path.addFirst(yyVals[-2+yyTop]);
+ yyVal = steps;
+ /*Step step = new Step (s, (Path) $3);*/
+ /*$$ = new Step ((Expr) $1, step);*/
+ }
+ break;
+case 50:
+ // line 585 "XPathParser.y"
+ {
+ Predicate filter = (Predicate) yyVals[0+yyTop];
+ Selector s = new Selector(Selector.SELF,
+ Collections.singletonList(filter));
+ Steps steps;
+ if (yyVals[-1+yyTop] instanceof Steps)
+ {
+ steps = (Steps) yyVals[-1+yyTop];
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst(yyVals[-1+yyTop]);
+ }
+ steps.path.addLast(s);
+ yyVal = steps;
+ /*$$ = new Step ((Expr) $1, s);*/
+ }
+ break;
+case 52:
+ // line 608 "XPathParser.y"
+ {
+ yyVal = new OrExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop]);
+ }
+ break;
+case 54:
+ // line 616 "XPathParser.y"
+ {
+ yyVal = new AndExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop]);
+ }
+ break;
+case 56:
+ // line 624 "XPathParser.y"
+ {
+ yyVal = new EqualityExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], false);
+ }
+ break;
+case 57:
+ // line 628 "XPathParser.y"
+ {
+ yyVal = new EqualityExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], true);
+ }
+ break;
+case 59:
+ // line 636 "XPathParser.y"
+ {
+ yyVal = new RelationalExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], true, false);
+ }
+ break;
+case 60:
+ // line 640 "XPathParser.y"
+ {
+ yyVal = new RelationalExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], false, false);
+ }
+ break;
+case 61:
+ // line 644 "XPathParser.y"
+ {
+ yyVal = new RelationalExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], true, true);
+ }
+ break;
+case 62:
+ // line 648 "XPathParser.y"
+ {
+ yyVal = new RelationalExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], false, true);
+ }
+ break;
+case 64:
+ // line 656 "XPathParser.y"
+ {
+ yyVal = new ArithmeticExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], ArithmeticExpr.ADD);
+ }
+ break;
+case 65:
+ // line 660 "XPathParser.y"
+ {
+ yyVal = new ArithmeticExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], ArithmeticExpr.SUBTRACT);
+ }
+ break;
+case 67:
+ // line 668 "XPathParser.y"
+ {
+ yyVal = new ArithmeticExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], ArithmeticExpr.MULTIPLY);
+ }
+ break;
+case 68:
+ // line 672 "XPathParser.y"
+ {
+ yyVal = new ArithmeticExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], ArithmeticExpr.DIVIDE);
+ }
+ break;
+case 69:
+ // line 676 "XPathParser.y"
+ {
+ yyVal = new ArithmeticExpr((Expr) yyVals[-2+yyTop], (Expr) yyVals[0+yyTop], ArithmeticExpr.MODULO);
+ }
+ break;
+case 71:
+ // line 684 "XPathParser.y"
+ {
+ yyVal = new NegativeExpr((Expr) yyVals[0+yyTop]);
+ }
+ break;
+case 72:
+ // line 691 "XPathParser.y"
+ {
+ yyVal = new Double((String) yyVals[0+yyTop] + ".0");
+ }
+ break;
+case 73:
+ // line 695 "XPathParser.y"
+ {
+ yyVal = new Double((String) yyVals[-1+yyTop] + ".0");
+ }
+ break;
+case 74:
+ // line 699 "XPathParser.y"
+ {
+ yyVal = new Double((String) yyVals[-2+yyTop] + "." + (String) yyVals[0+yyTop]);
+ }
+ break;
+case 75:
+ // line 703 "XPathParser.y"
+ {
+ yyVal = new Double("0." + (String) yyVals[0+yyTop]);
+ }
+ break;
+case 77:
+ // line 732 "XPathParser.y"
+ {
+ String name = (String) yyVals[0+yyTop];
+ yyVal = new VariableReference(variableResolver, getQName(name));
+ }
+ break;
+case 78:
+ // line 740 "XPathParser.y"
+ {
+ yyVal = new NameTest(null, true, true);
+ }
+ break;
+case 79:
+ // line 744 "XPathParser.y"
+ {
+ QName qName = getQName((String) yyVals[-2+yyTop]);
+ yyVal = new NameTest(qName, true, false);
+ }
+ break;
+case 80:
+ // line 749 "XPathParser.y"
+ {
+ QName qName = getQName((String) yyVals[0+yyTop]);
+ yyVal = new NameTest(qName, false, false);
+ }
+ break;
+case 82:
+ // line 758 "XPathParser.y"
+ {
+ yyVal = (String) yyVals[-2+yyTop] + ':' + (String) yyVals[0+yyTop];
+ }
+ break;
+case 83:
+ // line 765 "XPathParser.y"
+ {
+ yyVal = new Short(Node.COMMENT_NODE);
+ }
+ break;
+case 84:
+ // line 769 "XPathParser.y"
+ {
+ yyVal = new Short(Node.TEXT_NODE);
+ }
+ break;
+case 85:
+ // line 773 "XPathParser.y"
+ {
+ yyVal = new Short(Node.PROCESSING_INSTRUCTION_NODE);
+ }
+ break;
+case 86:
+ // line 777 "XPathParser.y"
+ {
+ yyVal = new Short((short) 0);
+ }
+ break;
+ // line 988 "-"
+ }
+ yyTop -= YyLenClass.yyLen[yyN];
+ yyState = yyStates[yyTop];
+ int yyM = YyLhsClass.yyLhs[yyN];
+ if (yyState == 0 && yyM == 0) {
+//t if (yydebug != null) yydebug.shift(0, yyFinal);
+ yyState = yyFinal;
+ if (yyToken < 0) {
+ yyToken = yyLex.advance() ? yyLex.token() : 0;
+//t if (yydebug != null)
+//t yydebug.lex(yyState, yyToken,yyname(yyToken), yyLex.value());
+ }
+ if (yyToken == 0) {
+//t if (yydebug != null) yydebug.accept(yyVal);
+ return yyVal;
+ }
+ continue yyLoop;
+ }
+ if ((yyN = YyGindexClass.yyGindex[yyM]) != 0 && (yyN += yyState) >= 0
+ && yyN < YyTableClass.yyTable.length && YyCheckClass.yyCheck[yyN] == yyState)
+ yyState = YyTableClass.yyTable[yyN];
+ else
+ yyState = YyDgotoClass.yyDgoto[yyM];
+//t if (yydebug != null) yydebug.shift(yyStates[yyTop], yyState);
+ continue yyLoop;
+ }
+ }
+ }
+
+ protected static final class YyLhsClass {
+
+ public static final short yyLhs [] = { -1,
+ 0, 2, 2, 4, 4, 4, 3, 3, 3, 5,
+ 5, 5, 5, 5, 6, 6, 7, 7, 7, 7,
+ 7, 7, 7, 7, 7, 7, 7, 7, 7, 8,
+ 8, 8, 9, 12, 12, 12, 12, 12, 15, 15,
+ 17, 17, 18, 18, 19, 19, 19, 19, 20, 20,
+ 1, 1, 21, 21, 22, 22, 22, 23, 23, 23,
+ 23, 23, 24, 24, 24, 25, 25, 25, 25, 26,
+ 26, 14, 14, 14, 14, 16, 13, 10, 10, 10,
+ 27, 27, 11, 11, 11, 11,
+ };
+ } /* End of class YyLhsClass */
+
+ protected static final class YyLenClass {
+
+ public static final short yyLen [] = { 2,
+ 1, 1, 1, 1, 2, 2, 1, 3, 3, 1,
+ 2, 3, 1, 1, 1, 2, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 3, 2, 3, 1, 3, 1, 1, 1, 3, 4,
+ 1, 3, 1, 3, 1, 1, 3, 3, 1, 2,
+ 1, 3, 1, 3, 1, 3, 3, 1, 3, 3,
+ 3, 3, 1, 3, 3, 1, 3, 3, 3, 1,
+ 2, 1, 2, 3, 2, 1, 2, 1, 3, 1,
+ 1, 3, 1, 1, 1, 1,
+ };
+ } /* End class YyLenClass */
+
+ protected static final class YyDefRedClass {
+
+ public static final short yyDefRed [] = { 0,
+ 36, 0, 0, 0, 0, 0, 0, 0, 78, 0,
+ 0, 14, 17, 18, 19, 20, 21, 22, 23, 24,
+ 25, 26, 27, 28, 29, 83, 0, 84, 86, 0,
+ 0, 45, 0, 3, 7, 0, 0, 15, 30, 0,
+ 49, 34, 37, 38, 0, 0, 43, 0, 0, 0,
+ 0, 0, 0, 66, 0, 0, 0, 0, 13, 0,
+ 80, 0, 71, 0, 0, 77, 75, 0, 0, 0,
+ 0, 0, 16, 0, 32, 0, 0, 0, 0, 50,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 74, 82, 79, 35, 0, 31, 0, 8,
+ 9, 0, 0, 39, 0, 0, 44, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 67, 68,
+ 69, 33, 0, 40, 42,
+ };
+ } /* End of class YyDefRedClass */
+
+ protected static final class YyDgotoClass {
+
+ public static final short yyDgoto [] = { 105,
+ 31, 32, 33, 34, 35, 36, 37, 38, 73, 39,
+ 40, 41, 42, 43, 44, 45, 106, 46, 47, 48,
+ 49, 50, 51, 52, 53, 54, 55,
+ };
+ } /* End of class YyDgotoClass */
+
+ protected static final class YySindexClass {
+
+ public static final short yySindex [] = { -97,
+ 0, -271, -267, -97, -239, -239, -97, -199, 0, -236,
+ -222, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, -218, 0, 0, 0,
+ -257, 0, -241, 0, 0, -205, -221, 0, 0, -194,
+ 0, 0, 0, 0, -190, -185, 0, -238, -211, -234,
+ -255, -209, -275, 0, 0, -169, -250, -168, 0, -241,
+ 0, -241, 0, -205, -187, 0, 0, -167, -97, -239,
+ -239, -97, 0, -199, 0, -151, -43, -239, -239, 0,
+ -97, -97, -97, -97, -97, -97, -97, -97, -97, -97,
+ -97, -97, 0, 0, 0, 0, -164, 0, -211, 0,
+ 0, -166, -205, 0, -165, -163, 0, -241, -241, -234,
+ -255, -255, -209, -209, -209, -209, -275, -275, 0, 0,
+ 0, 0, -97, 0, 0,
+ };
+ } /* End of class YySindexClass */
+
+ protected static final class YyRindexClass {
+
+ public static final short yyRindex [] = { 0,
+ 0, 58, 1, 0, 420, 0, 0, 0, 0, 0,
+ 129, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, -161, 0, 0, 0,
+ 40, 0, 237, 0, 0, 168, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 459, 0, 277, 557, 544,
+ 656, 561, 474, 0, 19, 75, 0, 0, 0, 295,
+ 0, 334, 0, 183, 114, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 686, 0,
+ 0, 0, 222, 0, -156, 0, 0, 351, 405, 553,
+ 665, 697, 577, 600, 617, 639, 513, 528, 0, 0,
+ 0, 0, 0, 0, 0,
+ };
+ } /* End of class YyRindexClass */
+
+ protected static final class YyGindexClass {
+
+ public static final short yyGindex [] = { 7,
+ 0, 0, 8, 0, 3, -3, 0, 0, 48, 0,
+ 0, 0, 0, 0, 0, 0, -12, 0, 35, 0,
+ 44, 36, -1, -54, 2, -7, -2,
+ };
+ } /* End of class YyGindexClass */
+
+ protected static final class YyTableClass {
+
+ public static final short yyTable [] = { 63,
+ 81, 90, 61, 61, 64, 61, 30, 66, 94, 56,
+ 58, 57, 60, 62, 84, 85, 86, 87, 80, 3,
+ 91, 92, 65, 72, 70, 71, 95, 78, 79, 113,
+ 114, 115, 116, 82, 83, 67, 8, 9, 68, 1,
+ 69, 59, 12, 13, 14, 15, 16, 17, 18, 19,
+ 20, 21, 22, 23, 24, 25, 72, 72, 74, 3,
+ 26, 27, 28, 29, 88, 89, 75, 61, 61, 76,
+ 103, 61, 100, 101, 73, 61, 61, 9, 102, 77,
+ 111, 112, 119, 120, 121, 108, 109, 81, 93, 117,
+ 118, 97, 96, 98, 94, 80, 122, 124, 123, 85,
+ 26, 27, 28, 29, 41, 1, 2, 3, 4, 104,
+ 125, 107, 99, 81, 5, 6, 110, 0, 0, 0,
+ 0, 0, 0, 7, 8, 9, 10, 0, 13, 11,
+ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 23, 24, 25, 0, 0, 0, 0, 26, 27,
+ 28, 29, 0, 0, 0, 0, 0, 0, 0, 1,
+ 2, 3, 4, 0, 0, 0, 0, 10, 5, 6,
+ 0, 0, 0, 0, 0, 0, 0, 7, 8, 9,
+ 10, 0, 11, 11, 12, 13, 14, 15, 16, 17,
+ 18, 19, 20, 21, 22, 23, 24, 25, 0, 0,
+ 0, 0, 26, 27, 28, 29, 0, 0, 0, 0,
+ 0, 0, 0, 1, 2, 3, 4, 0, 0, 0,
+ 0, 12, 5, 6, 0, 0, 0, 0, 0, 0,
+ 0, 0, 8, 9, 10, 0, 2, 11, 12, 13,
+ 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
+ 24, 25, 0, 0, 0, 0, 26, 27, 28, 29,
+ 81, 81, 81, 81, 81, 81, 81, 81, 81, 81,
+ 81, 81, 81, 81, 81, 81, 46, 81, 76, 80,
+ 80, 80, 80, 80, 80, 80, 80, 80, 80, 80,
+ 80, 80, 80, 80, 5, 80, 81, 81, 81, 81,
+ 1, 0, 1, 1, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 80, 80, 80, 80, 72, 72,
+ 72, 72, 72, 72, 72, 72, 72, 72, 72, 72,
+ 72, 72, 72, 6, 72, 73, 73, 73, 73, 73,
+ 73, 73, 73, 73, 73, 73, 73, 73, 73, 73,
+ 47, 73, 0, 72, 72, 72, 72, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 73, 73, 73, 73, 81, 81, 81, 81, 81, 81,
+ 81, 81, 81, 81, 81, 81, 81, 81, 81, 13,
+ 81, 13, 13, 13, 13, 13, 13, 13, 13, 13,
+ 13, 13, 13, 13, 48, 13, 0, 0, 0, 81,
+ 81, 81, 81, 0, 0, 0, 0, 0, 0, 4,
+ 0, 0, 0, 0, 13, 13, 13, 13, 10, 0,
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
+ 10, 10, 10, 11, 10, 11, 11, 11, 11, 11,
+ 11, 11, 11, 11, 11, 11, 11, 11, 70, 11,
+ 0, 0, 0, 10, 10, 10, 10, 0, 0, 0,
+ 0, 0, 0, 63, 0, 0, 0, 0, 11, 11,
+ 11, 11, 12, 0, 12, 12, 12, 12, 12, 12,
+ 12, 12, 12, 12, 12, 12, 12, 2, 12, 2,
+ 2, 2, 0, 0, 2, 2, 2, 2, 2, 2,
+ 2, 2, 64, 2, 0, 0, 0, 12, 12, 12,
+ 12, 0, 0, 0, 0, 0, 0, 65, 0, 0,
+ 0, 0, 2, 2, 2, 2, 0, 46, 0, 46,
+ 46, 46, 0, 53, 46, 46, 46, 46, 46, 46,
+ 46, 46, 54, 46, 0, 5, 51, 5, 5, 5,
+ 58, 0, 5, 5, 5, 5, 5, 5, 5, 5,
+ 0, 5, 46, 46, 46, 46, 60, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 5, 5, 5, 5, 6, 0, 6, 6, 6, 59,
+ 0, 6, 6, 6, 6, 6, 6, 6, 6, 0,
+ 6, 47, 0, 47, 47, 47, 62, 0, 47, 47,
+ 47, 47, 47, 47, 47, 47, 0, 47, 0, 6,
+ 6, 6, 6, 0, 0, 0, 0, 0, 61, 0,
+ 0, 0, 0, 0, 0, 0, 47, 47, 47, 47,
+ 0, 0, 0, 0, 0, 55, 0, 0, 0, 0,
+ 0, 0, 0, 0, 56, 48, 0, 48, 48, 48,
+ 0, 0, 48, 48, 48, 48, 48, 48, 48, 48,
+ 4, 48, 4, 4, 4, 52, 0, 4, 4, 4,
+ 4, 4, 4, 4, 4, 0, 57, 0, 0, 0,
+ 48, 48, 48, 48, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 4, 4, 4, 4, 70,
+ 0, 70, 70, 0, 0, 0, 70, 70, 70, 70,
+ 70, 70, 70, 70, 63, 70, 63, 63, 0, 0,
+ 0, 63, 63, 63, 63, 63, 63, 63, 63, 0,
+ 0, 0, 0, 0, 70, 70, 70, 70, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 63, 63, 64, 0, 64, 64, 0, 0, 0,
+ 64, 64, 64, 64, 64, 64, 64, 64, 65, 0,
+ 65, 65, 0, 0, 0, 65, 65, 65, 65, 65,
+ 65, 65, 65, 0, 53, 0, 53, 53, 0, 0,
+ 64, 64, 0, 54, 0, 54, 54, 51, 0, 51,
+ 51, 58, 0, 58, 58, 65, 65, 0, 58, 58,
+ 58, 58, 58, 58, 0, 0, 0, 60, 0, 60,
+ 60, 53, 53, 0, 60, 60, 60, 60, 60, 60,
+ 54, 54, 0, 0, 51, 0, 0, 0, 58, 58,
+ 59, 0, 59, 59, 0, 0, 0, 59, 59, 59,
+ 59, 59, 59, 0, 60, 60, 0, 62, 0, 62,
+ 62, 0, 0, 0, 62, 62, 62, 62, 62, 62,
+ 0, 0, 0, 0, 0, 0, 0, 59, 59, 61,
+ 0, 61, 61, 0, 0, 0, 61, 61, 61, 61,
+ 61, 61, 0, 0, 62, 62, 55, 0, 55, 55,
+ 0, 0, 0, 55, 55, 56, 0, 56, 56, 0,
+ 0, 0, 56, 56, 0, 0, 61, 61, 0, 0,
+ 0, 0, 0, 0, 0, 0, 52, 0, 52, 52,
+ 0, 0, 0, 55, 55, 0, 0, 57, 0, 57,
+ 57, 0, 56, 56, 57, 57, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 52, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 57, 57,
+ };
+ } /* End of class YyTableClass */
+
+ protected static final class YyCheckClass {
+
+ public static final short yyCheck [] = { 7,
+ 0, 277, 5, 6, 8, 8, 0, 10, 259, 281,
+ 4, 279, 5, 6, 270, 271, 272, 273, 0, 259,
+ 296, 297, 259, 262, 266, 267, 277, 266, 267, 84,
+ 85, 86, 87, 268, 269, 258, 276, 277, 257, 0,
+ 298, 281, 282, 283, 284, 285, 286, 287, 288, 289,
+ 290, 291, 292, 293, 294, 295, 262, 0, 280, 259,
+ 300, 301, 302, 303, 274, 275, 261, 70, 71, 260,
+ 74, 74, 70, 71, 0, 78, 79, 277, 72, 265,
+ 82, 83, 90, 91, 92, 78, 79, 299, 258, 88,
+ 89, 279, 261, 261, 259, 48, 263, 261, 264, 261,
+ 300, 301, 302, 303, 261, 257, 258, 259, 260, 261,
+ 123, 77, 69, 0, 266, 267, 81, -1, -1, -1,
+ -1, -1, -1, 275, 276, 277, 278, -1, 0, 281,
+ 282, 283, 284, 285, 286, 287, 288, 289, 290, 291,
+ 292, 293, 294, 295, -1, -1, -1, -1, 300, 301,
+ 302, 303, -1, -1, -1, -1, -1, -1, -1, 257,
+ 258, 259, 260, -1, -1, -1, -1, 0, 266, 267,
+ -1, -1, -1, -1, -1, -1, -1, 275, 276, 277,
+ 278, -1, 0, 281, 282, 283, 284, 285, 286, 287,
+ 288, 289, 290, 291, 292, 293, 294, 295, -1, -1,
+ -1, -1, 300, 301, 302, 303, -1, -1, -1, -1,
+ -1, -1, -1, 257, 258, 259, 260, -1, -1, -1,
+ -1, 0, 266, 267, -1, -1, -1, -1, -1, -1,
+ -1, -1, 276, 277, 278, -1, 0, 281, 282, 283,
+ 284, 285, 286, 287, 288, 289, 290, 291, 292, 293,
+ 294, 295, -1, -1, -1, -1, 300, 301, 302, 303,
+ 260, 261, 262, 263, 264, 265, 266, 267, 268, 269,
+ 270, 271, 272, 273, 274, 275, 0, 277, 260, 261,
+ 262, 263, 264, 265, 266, 267, 268, 269, 270, 271,
+ 272, 273, 274, 275, 0, 277, 296, 297, 298, 299,
+ 261, -1, 263, 264, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 296, 297, 298, 299, 261, 262,
+ 263, 264, 265, 266, 267, 268, 269, 270, 271, 272,
+ 273, 274, 275, 0, 277, 261, 262, 263, 264, 265,
+ 266, 267, 268, 269, 270, 271, 272, 273, 274, 275,
+ 0, 277, -1, 296, 297, 298, 299, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 296, 297, 298, 299, 261, 262, 263, 264, 265, 266,
+ 267, 268, 269, 270, 271, 272, 273, 274, 275, 261,
+ 277, 263, 264, 265, 266, 267, 268, 269, 270, 271,
+ 272, 273, 274, 275, 0, 277, -1, -1, -1, 296,
+ 297, 298, 299, -1, -1, -1, -1, -1, -1, 0,
+ -1, -1, -1, -1, 296, 297, 298, 299, 261, -1,
+ 263, 264, 265, 266, 267, 268, 269, 270, 271, 272,
+ 273, 274, 275, 261, 277, 263, 264, 265, 266, 267,
+ 268, 269, 270, 271, 272, 273, 274, 275, 0, 277,
+ -1, -1, -1, 296, 297, 298, 299, -1, -1, -1,
+ -1, -1, -1, 0, -1, -1, -1, -1, 296, 297,
+ 298, 299, 261, -1, 263, 264, 265, 266, 267, 268,
+ 269, 270, 271, 272, 273, 274, 275, 261, 277, 263,
+ 264, 265, -1, -1, 268, 269, 270, 271, 272, 273,
+ 274, 275, 0, 277, -1, -1, -1, 296, 297, 298,
+ 299, -1, -1, -1, -1, -1, -1, 0, -1, -1,
+ -1, -1, 296, 297, 298, 299, -1, 261, -1, 263,
+ 264, 265, -1, 0, 268, 269, 270, 271, 272, 273,
+ 274, 275, 0, 277, -1, 261, 0, 263, 264, 265,
+ 0, -1, 268, 269, 270, 271, 272, 273, 274, 275,
+ -1, 277, 296, 297, 298, 299, 0, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 296, 297, 298, 299, 261, -1, 263, 264, 265, 0,
+ -1, 268, 269, 270, 271, 272, 273, 274, 275, -1,
+ 277, 261, -1, 263, 264, 265, 0, -1, 268, 269,
+ 270, 271, 272, 273, 274, 275, -1, 277, -1, 296,
+ 297, 298, 299, -1, -1, -1, -1, -1, 0, -1,
+ -1, -1, -1, -1, -1, -1, 296, 297, 298, 299,
+ -1, -1, -1, -1, -1, 0, -1, -1, -1, -1,
+ -1, -1, -1, -1, 0, 261, -1, 263, 264, 265,
+ -1, -1, 268, 269, 270, 271, 272, 273, 274, 275,
+ 261, 277, 263, 264, 265, 0, -1, 268, 269, 270,
+ 271, 272, 273, 274, 275, -1, 0, -1, -1, -1,
+ 296, 297, 298, 299, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 296, 297, 298, 299, 261,
+ -1, 263, 264, -1, -1, -1, 268, 269, 270, 271,
+ 272, 273, 274, 275, 261, 277, 263, 264, -1, -1,
+ -1, 268, 269, 270, 271, 272, 273, 274, 275, -1,
+ -1, -1, -1, -1, 296, 297, 298, 299, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, 298, 299, 261, -1, 263, 264, -1, -1, -1,
+ 268, 269, 270, 271, 272, 273, 274, 275, 261, -1,
+ 263, 264, -1, -1, -1, 268, 269, 270, 271, 272,
+ 273, 274, 275, -1, 261, -1, 263, 264, -1, -1,
+ 298, 299, -1, 261, -1, 263, 264, 261, -1, 263,
+ 264, 261, -1, 263, 264, 298, 299, -1, 268, 269,
+ 270, 271, 272, 273, -1, -1, -1, 261, -1, 263,
+ 264, 298, 299, -1, 268, 269, 270, 271, 272, 273,
+ 298, 299, -1, -1, 298, -1, -1, -1, 298, 299,
+ 261, -1, 263, 264, -1, -1, -1, 268, 269, 270,
+ 271, 272, 273, -1, 298, 299, -1, 261, -1, 263,
+ 264, -1, -1, -1, 268, 269, 270, 271, 272, 273,
+ -1, -1, -1, -1, -1, -1, -1, 298, 299, 261,
+ -1, 263, 264, -1, -1, -1, 268, 269, 270, 271,
+ 272, 273, -1, -1, 298, 299, 261, -1, 263, 264,
+ -1, -1, -1, 268, 269, 261, -1, 263, 264, -1,
+ -1, -1, 268, 269, -1, -1, 298, 299, -1, -1,
+ -1, -1, -1, -1, -1, -1, 261, -1, 263, 264,
+ -1, -1, -1, 298, 299, -1, -1, 261, -1, 263,
+ 264, -1, 298, 299, 268, 269, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 298, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, 298, 299,
+ };
+ } /* End of class YyCheckClass */
+
+
+//t protected static final class YyRuleClass {
+
+//t public static final String yyRule [] = {
+//t "$accept : expr",
+//t "expr : or_expr",
+//t "location_path : relative_location_path",
+//t "location_path : absolute_location_path",
+//t "absolute_location_path : SLASH",
+//t "absolute_location_path : SLASH relative_location_path",
+//t "absolute_location_path : DOUBLE_SLASH relative_location_path",
+//t "relative_location_path : step",
+//t "relative_location_path : relative_location_path SLASH step",
+//t "relative_location_path : relative_location_path DOUBLE_SLASH step",
+//t "step : step_node_test",
+//t "step : AT step_node_test",
+//t "step : axis_name DOUBLE_COLON step_node_test",
+//t "step : DOT",
+//t "step : DOUBLE_DOT",
+//t "step_node_test : node_test",
+//t "step_node_test : step_node_test predicate",
+//t "axis_name : ANCESTOR",
+//t "axis_name : ANCESTOR_OR_SELF",
+//t "axis_name : ATTRIBUTE",
+//t "axis_name : CHILD",
+//t "axis_name : DESCENDANT",
+//t "axis_name : DESCENDANT_OR_SELF",
+//t "axis_name : FOLLOWING",
+//t "axis_name : FOLLOWING_SIBLING",
+//t "axis_name : NAMESPACE",
+//t "axis_name : PARENT",
+//t "axis_name : PRECEDING",
+//t "axis_name : PRECEDING_SIBLING",
+//t "axis_name : SELF",
+//t "node_test : name_test",
+//t "node_test : PROCESSING_INSTRUCTION LITERAL RP",
+//t "node_test : node_type RP",
+//t "predicate : LB expr RB",
+//t "primary_expr : variable_reference",
+//t "primary_expr : LP expr RP",
+//t "primary_expr : LITERAL",
+//t "primary_expr : number",
+//t "primary_expr : function_call",
+//t "function_call : function_name LP RP",
+//t "function_call : function_name LP argument_list RP",
+//t "argument_list : expr",
+//t "argument_list : expr COMMA argument_list",
+//t "union_expr : path_expr",
+//t "union_expr : union_expr PIPE path_expr",
+//t "path_expr : location_path",
+//t "path_expr : filter_expr",
+//t "path_expr : filter_expr SLASH relative_location_path",
+//t "path_expr : filter_expr DOUBLE_SLASH relative_location_path",
+//t "filter_expr : primary_expr",
+//t "filter_expr : filter_expr predicate",
+//t "or_expr : and_expr",
+//t "or_expr : or_expr OR and_expr",
+//t "and_expr : equality_expr",
+//t "and_expr : and_expr AND equality_expr",
+//t "equality_expr : relational_expr",
+//t "equality_expr : equality_expr EQ relational_expr",
+//t "equality_expr : equality_expr NE relational_expr",
+//t "relational_expr : additive_expr",
+//t "relational_expr : relational_expr LT additive_expr",
+//t "relational_expr : relational_expr GT additive_expr",
+//t "relational_expr : relational_expr LTE additive_expr",
+//t "relational_expr : relational_expr GTE additive_expr",
+//t "additive_expr : multiplicative_expr",
+//t "additive_expr : additive_expr PLUS multiplicative_expr",
+//t "additive_expr : additive_expr MINUS multiplicative_expr",
+//t "multiplicative_expr : unary_expr",
+//t "multiplicative_expr : multiplicative_expr STAR unary_expr",
+//t "multiplicative_expr : multiplicative_expr DIV unary_expr",
+//t "multiplicative_expr : multiplicative_expr MOD unary_expr",
+//t "unary_expr : union_expr",
+//t "unary_expr : MINUS unary_expr",
+//t "number : DIGITS",
+//t "number : DIGITS DOT",
+//t "number : DIGITS DOT DIGITS",
+//t "number : DOT DIGITS",
+//t "function_name : qname",
+//t "variable_reference : DOLLAR qname",
+//t "name_test : STAR",
+//t "name_test : NAME COLON STAR",
+//t "name_test : qname",
+//t "qname : NAME",
+//t "qname : NAME COLON NAME",
+//t "node_type : COMMENT",
+//t "node_type : TEXT",
+//t "node_type : PROCESSING_INSTRUCTION",
+//t "node_type : NODE",
+//t };
+//t } /* End of class YyRuleClass */
+
+ protected static final class YyNameClass {
+
+ public static final String yyName [] = {
+ "end-of-file",null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,null,null,null,null,null,null,null,
+ null,null,null,null,null,null,null,"LITERAL","DIGITS","NAME","LP",
+ "RP","LB","RB","COMMA","PIPE","SLASH","DOUBLE_SLASH","EQ","NE","GT",
+ "LT","GTE","LTE","PLUS","MINUS","AT","STAR","DOLLAR","COLON",
+ "DOUBLE_COLON","DOT","DOUBLE_DOT","ANCESTOR","ANCESTOR_OR_SELF",
+ "ATTRIBUTE","CHILD","DESCENDANT","DESCENDANT_OR_SELF","FOLLOWING",
+ "FOLLOWING_SIBLING","NAMESPACE","PARENT","PRECEDING",
+ "PRECEDING_SIBLING","SELF","DIV","MOD","OR","AND","COMMENT",
+ "PROCESSING_INSTRUCTION","TEXT","NODE","UNARY",
+ };
+ } /* End of class YyNameClass */
+
+
+ // line 783 "XPathParser.y"
+
+}
+ // line 1463 "-"
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.y
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.y?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.y (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathParser.y Thu Nov 8 16:56:19 2007
@@ -0,0 +1,784 @@
+%{
+/* XPathParser.y - An XPath 1.0 parser.
+ Copyright (C) 2004 The Free Software Foundation
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package gnu.xml.xpath;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+import javax.xml.xpath.XPathFunctionResolver;
+import javax.xml.xpath.XPathVariableResolver;
+import org.w3c.dom.Node;
+
+/**
+ * An XPath 1.0 parser.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XPathParser
+{
+
+ NamespaceContext namespaceContext;
+ XPathVariableResolver variableResolver;
+ XPathFunctionResolver functionResolver;
+
+ QName getQName(String name)
+ {
+ QName qName = QName.valueOf(name);
+ if (namespaceContext != null)
+ {
+ String prefix = qName.getPrefix();
+ String uri = qName.getNamespaceURI();
+ if (prefix != null && (uri == null || uri.length() == 0))
+ {
+ uri = namespaceContext.getNamespaceURI(prefix);
+ String localName = qName.getLocalPart();
+ qName = new QName(uri, localName, prefix);
+ }
+ }
+ return qName;
+ }
+
+ Expr lookupFunction(String name, List args)
+ {
+ int arity = args.size();
+ if ("position".equals(name) && arity == 0)
+ {
+ return new PositionFunction();
+ }
+ else if ("last".equals(name) && arity == 0)
+ {
+ return new LastFunction();
+ }
+ else if ("string".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new StringFunction(args);
+ }
+ else if ("number".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NumberFunction(args);
+ }
+ else if ("boolean".equals(name) && arity == 1)
+ {
+ return new BooleanFunction(args);
+ }
+ else if ("count".equals(name) && arity == 1)
+ {
+ return new CountFunction(args);
+ }
+ else if ("not".equals(name) && arity == 1)
+ {
+ return new NotFunction(args);
+ }
+ else if ("id".equals(name) && arity == 1)
+ {
+ return new IdFunction(args);
+ }
+ else if ("concat".equals(name) && arity > 1)
+ {
+ return new ConcatFunction(args);
+ }
+ else if ("true".equals(name) && arity == 0)
+ {
+ return new TrueFunction();
+ }
+ else if ("false".equals(name) && arity == 0)
+ {
+ return new FalseFunction();
+ }
+ else if ("name".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NameFunction(args);
+ }
+ else if ("local-name".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new LocalNameFunction(args);
+ }
+ else if ("namespace-uri".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NamespaceUriFunction(args);
+ }
+ else if ("starts-with".equals(name) && arity == 2)
+ {
+ return new StartsWithFunction(args);
+ }
+ else if ("contains".equals(name) && arity == 2)
+ {
+ return new ContainsFunction(args);
+ }
+ else if ("string-length".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new StringLengthFunction(args);
+ }
+ else if ("translate".equals(name) && arity == 3)
+ {
+ return new TranslateFunction(args);
+ }
+ else if ("normalize-space".equals(name) && (arity == 1 || arity == 0))
+ {
+ return new NormalizeSpaceFunction(args);
+ }
+ else if ("substring".equals(name) && (arity == 2 || arity == 3))
+ {
+ return new SubstringFunction(args);
+ }
+ else if ("substring-before".equals(name) && arity == 2)
+ {
+ return new SubstringBeforeFunction(args);
+ }
+ else if ("substring-after".equals(name) && arity == 2)
+ {
+ return new SubstringAfterFunction(args);
+ }
+ else if ("lang".equals(name) && arity == 1)
+ {
+ return new LangFunction(args);
+ }
+ else if ("sum".equals(name) && arity == 1)
+ {
+ return new SumFunction(args);
+ }
+ else if ("floor".equals(name) && arity == 1)
+ {
+ return new FloorFunction(args);
+ }
+ else if ("ceiling".equals(name) && arity == 1)
+ {
+ return new CeilingFunction(args);
+ }
+ else if ("round".equals(name) && arity == 1)
+ {
+ return new RoundFunction(args);
+ }
+ else if (functionResolver != null)
+ {
+ QName qName = QName.valueOf(name);
+ Object function = functionResolver.resolveFunction(qName, arity);
+ if (function != null &&
+ function instanceof Function &&
+ function instanceof Expr)
+ {
+ Function f = (Function) function;
+ f.setArguments(args);
+ return (Expr) function;
+ }
+ }
+ return new FunctionCall(functionResolver, name, args);
+ }
+
+%}
+
+%token LITERAL
+%token DIGITS
+%token NAME
+
+%token LP // '('
+%token RP // ')'
+%token LB // '['
+%token RB // ']'
+%token COMMA // ','
+%token PIPE // '|'
+%token SLASH // '/'
+%token DOUBLE_SLASH // '//'
+%token EQ // '='
+%token NE // '!='
+%token GT // '>'
+%token LT // '<'
+%token GTE // '>='
+%token LTE // '<='
+%token PLUS // '+'
+%token MINUS // '-'
+%token AT // '@'
+%token STAR // '*'
+%token DOLLAR // '$'
+%token COLON // ':'
+%token DOUBLE_COLON // '::'
+%token DOT // '.'
+%token DOUBLE_DOT // '..'
+
+%token ANCESTOR
+%token ANCESTOR_OR_SELF
+%token ATTRIBUTE
+%token CHILD
+%token DESCENDANT
+%token DESCENDANT_OR_SELF
+%token FOLLOWING
+%token FOLLOWING_SIBLING
+%token NAMESPACE
+%token PARENT
+%token PRECEDING
+%token PRECEDING_SIBLING
+%token SELF
+%token DIV
+%token MOD
+%token OR
+%token AND
+%token COMMENT
+%token PROCESSING_INSTRUCTION
+%token TEXT
+%token NODE
+
+%right UNARY
+
+%start expr
+
+%%
+
+expr:
+ or_expr
+ ;
+
+location_path:
+ relative_location_path
+ | absolute_location_path
+ ;
+
+absolute_location_path:
+ SLASH
+ {
+ $$ = new Root();
+ }
+ | SLASH relative_location_path
+ {
+ Steps steps;
+ if ($2 instanceof Steps)
+ {
+ steps = (Steps) $2;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($2);
+ }
+ steps.path.addFirst(new Root());
+ $$ = steps;
+ //$$ = new Step(new Root(), (Path) $2);
+ }
+ | DOUBLE_SLASH relative_location_path
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList (nt));
+ Steps steps;
+ if ($2 instanceof Steps)
+ {
+ steps = (Steps) $2;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($2);
+ }
+ steps.path.addFirst(s);
+ steps.path.addFirst(new Root());
+ $$ = steps;
+ //Step step = new Step(s, (Path) $2);
+ //$$ = new Step(new Root(), step);
+ }
+ ;
+
+relative_location_path:
+ step
+ | relative_location_path SLASH step
+ {
+ Steps steps;
+ if ($1 instanceof Steps)
+ {
+ steps = (Steps) $1;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($1);
+ }
+ steps.path.addLast($3);
+ $$ = steps;
+ //$$ = new Step((Expr) $1, (Path) $3);
+ }
+ | relative_location_path DOUBLE_SLASH step
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList (nt));
+ Steps steps;
+ if ($1 instanceof Steps)
+ {
+ steps = (Steps) $1;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($1);
+ }
+ steps.path.addLast(s);
+ steps.path.addLast($3);
+ $$ = steps;
+ //Step step = new Step(s, (Path) $3);
+ //$$ = new Step((Expr) $1, step);
+ }
+ ;
+
+step:
+ step_node_test
+ {
+ $$ = new Selector (Selector.CHILD, (List) $1);
+ }
+ | AT step_node_test
+ {
+ $$ = new Selector (Selector.ATTRIBUTE, (List) $2);
+ }
+ | axis_name DOUBLE_COLON step_node_test
+ {
+ $$ = new Selector (((Integer) $1).intValue (), (List) $3);
+ }
+ | DOT
+ {
+ $$ = new Selector (Selector.SELF, Collections.EMPTY_LIST);
+ }
+ | DOUBLE_DOT
+ {
+ $$ = new Selector (Selector.PARENT, Collections.EMPTY_LIST);
+ }
+ ;
+
+step_node_test:
+ node_test
+ {
+ List list = new ArrayList();
+ list.add($1);
+ $$ = list;
+ }
+ | step_node_test predicate
+ {
+ List list = (List)$1;
+ list.add($2);
+ $$ = list;
+ }
+ ;
+
+/*predicate_list:
+ predicate
+ {
+ List list = new ArrayList ();
+ list.add ($1);
+ $$ = list;
+ }
+ | predicate predicate_list
+ {
+ List list = (List) $3;
+ list.add (0, $1);
+ $$ = list;
+ }
+ ;*/
+
+axis_name:
+ ANCESTOR
+ {
+ $$ = new Integer(Selector.ANCESTOR);
+ }
+ | ANCESTOR_OR_SELF
+ {
+ $$ = new Integer(Selector.ANCESTOR_OR_SELF);
+ }
+ | ATTRIBUTE
+ {
+ $$ = new Integer(Selector.ATTRIBUTE);
+ }
+ | CHILD
+ {
+ $$ = new Integer(Selector.CHILD);
+ }
+ | DESCENDANT
+ {
+ $$ = new Integer(Selector.DESCENDANT);
+ }
+ | DESCENDANT_OR_SELF
+ {
+ $$ = new Integer(Selector.DESCENDANT_OR_SELF);
+ }
+ | FOLLOWING
+ {
+ $$ = new Integer(Selector.FOLLOWING);
+ }
+ | FOLLOWING_SIBLING
+ {
+ $$ = new Integer(Selector.FOLLOWING_SIBLING);
+ }
+ | NAMESPACE
+ {
+ $$ = new Integer(Selector.NAMESPACE);
+ }
+ | PARENT
+ {
+ $$ = new Integer(Selector.PARENT);
+ }
+ | PRECEDING
+ {
+ $$ = new Integer(Selector.PRECEDING);
+ }
+ | PRECEDING_SIBLING
+ {
+ $$ = new Integer(Selector.PRECEDING_SIBLING);
+ }
+ | SELF
+ {
+ $$ = new Integer(Selector.SELF);
+ }
+ ;
+
+node_test:
+ name_test
+ /*| PROCESSING_INSTRUCTION LP LITERAL RP*/
+ | PROCESSING_INSTRUCTION LITERAL RP
+ {
+ $$ = new NodeTypeTest(Node.PROCESSING_INSTRUCTION_NODE, (String) $2);
+ }
+ /*| node_type LP RP*/
+ | node_type RP
+ {
+ $$ = new NodeTypeTest(((Short) $1).shortValue());
+ }
+ ;
+
+predicate:
+ LB expr RB
+ {
+ $$ = new Predicate((Expr) $2);
+ }
+ ;
+
+primary_expr:
+ variable_reference
+ | LP expr RP
+ {
+ $$ = new ParenthesizedExpr((Expr) $2);
+ }
+ | LITERAL
+ {
+ $$ = new Constant($1);
+ }
+ | number
+ {
+ $$ = new Constant($1);
+ }
+ | function_call
+ ;
+
+function_call:
+ function_name LP RP
+ {
+ $$ = lookupFunction((String) $1, Collections.EMPTY_LIST);
+ }
+ | function_name LP argument_list RP
+ {
+ $$ = lookupFunction((String) $1, (List) $3);
+ }
+ ;
+
+argument_list:
+ expr
+ {
+ List list = new ArrayList();
+ list.add($1);
+ $$ = list;
+ }
+ | expr COMMA argument_list
+ {
+ List list = (List) $3;
+ list.add(0, $1);
+ $$ = list;
+ }
+ ;
+
+union_expr:
+ path_expr
+ | union_expr PIPE path_expr
+ {
+ $$ = new UnionExpr((Expr) $1, (Expr) $3);
+ }
+ ;
+
+path_expr:
+ location_path
+ | filter_expr
+ | filter_expr SLASH relative_location_path
+ {
+ Steps steps;
+ if ($3 instanceof Steps)
+ {
+ steps = (Steps) $3;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($3);
+ }
+ steps.path.addFirst($1);
+ $$ = steps;
+ //$$ = new Step ((Expr) $1, (Path) $3);
+ }
+ | filter_expr DOUBLE_SLASH relative_location_path
+ {
+ Test nt = new NodeTypeTest((short) 0);
+ Selector s = new Selector(Selector.DESCENDANT_OR_SELF,
+ Collections.singletonList(nt));
+ Steps steps;
+ if ($3 instanceof Steps)
+ {
+ steps = (Steps) $3;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($3);
+ }
+ steps.path.addFirst(s);
+ steps.path.addFirst($1);
+ $$ = steps;
+ //Step step = new Step (s, (Path) $3);
+ //$$ = new Step ((Expr) $1, step);
+ }
+ ;
+
+filter_expr:
+ primary_expr
+ | filter_expr predicate
+ {
+ Predicate filter = (Predicate) $2;
+ Selector s = new Selector(Selector.SELF,
+ Collections.singletonList(filter));
+ Steps steps;
+ if ($1 instanceof Steps)
+ {
+ steps = (Steps) $1;
+ }
+ else
+ {
+ steps = new Steps();
+ steps.path.addFirst($1);
+ }
+ steps.path.addLast(s);
+ $$ = steps;
+ //$$ = new Step ((Expr) $1, s);
+ }
+ ;
+
+or_expr:
+ and_expr
+ | or_expr OR and_expr
+ {
+ $$ = new OrExpr((Expr) $1, (Expr) $3);
+ }
+ ;
+
+and_expr:
+ equality_expr
+ | and_expr AND equality_expr
+ {
+ $$ = new AndExpr((Expr) $1, (Expr) $3);
+ }
+ ;
+
+equality_expr:
+ relational_expr
+ | equality_expr EQ relational_expr
+ {
+ $$ = new EqualityExpr((Expr) $1, (Expr) $3, false);
+ }
+ | equality_expr NE relational_expr
+ {
+ $$ = new EqualityExpr((Expr) $1, (Expr) $3, true);
+ }
+ ;
+
+relational_expr:
+ additive_expr
+ | relational_expr LT additive_expr
+ {
+ $$ = new RelationalExpr((Expr) $1, (Expr) $3, true, false);
+ }
+ | relational_expr GT additive_expr
+ {
+ $$ = new RelationalExpr((Expr) $1, (Expr) $3, false, false);
+ }
+ | relational_expr LTE additive_expr
+ {
+ $$ = new RelationalExpr((Expr) $1, (Expr) $3, true, true);
+ }
+ | relational_expr GTE additive_expr
+ {
+ $$ = new RelationalExpr((Expr) $1, (Expr) $3, false, true);
+ }
+ ;
+
+additive_expr:
+ multiplicative_expr
+ | additive_expr PLUS multiplicative_expr
+ {
+ $$ = new ArithmeticExpr((Expr) $1, (Expr) $3, ArithmeticExpr.ADD);
+ }
+ | additive_expr MINUS multiplicative_expr
+ {
+ $$ = new ArithmeticExpr((Expr) $1, (Expr) $3, ArithmeticExpr.SUBTRACT);
+ }
+ ;
+
+multiplicative_expr:
+ unary_expr
+ | multiplicative_expr STAR unary_expr
+ {
+ $$ = new ArithmeticExpr((Expr) $1, (Expr) $3, ArithmeticExpr.MULTIPLY);
+ }
+ | multiplicative_expr DIV unary_expr
+ {
+ $$ = new ArithmeticExpr((Expr) $1, (Expr) $3, ArithmeticExpr.DIVIDE);
+ }
+ | multiplicative_expr MOD unary_expr
+ {
+ $$ = new ArithmeticExpr((Expr) $1, (Expr) $3, ArithmeticExpr.MODULO);
+ }
+ ;
+
+unary_expr:
+ union_expr
+ | MINUS unary_expr %prec UNARY
+ {
+ $$ = new NegativeExpr((Expr) $2);
+ }
+ ;
+
+number:
+ DIGITS
+ {
+ $$ = new Double((String) $1 + ".0");
+ }
+ | DIGITS DOT
+ {
+ $$ = new Double((String) $1 + ".0");
+ }
+ | DIGITS DOT DIGITS
+ {
+ $$ = new Double((String) $1 + "." + (String) $3);
+ }
+ | DOT DIGITS
+ {
+ $$ = new Double("0." + (String) $2);
+ }
+ ;
+
+function_name:
+ qname
+/* | node_type
+ {
+ switch (((Short) $1).shortValue ())
+ {
+ case Node.COMMENT_NODE:
+ $$ = "comment";
+ break;
+ case Node.TEXT_NODE:
+ $$ = "text";
+ break;
+ case Node.PROCESSING_INSTRUCTION_NODE:
+ $$ = "processing-instruction";
+ break;
+ default:
+ $$ = "node";
+ break;
+ }
+ }*/
+ ;
+
+variable_reference:
+ DOLLAR qname
+ {
+ String name = (String) $2;
+ $$ = new VariableReference(variableResolver, getQName(name));
+ }
+ ;
+
+name_test:
+ STAR
+ {
+ $$ = new NameTest(null, true, true);
+ }
+ | NAME COLON STAR
+ {
+ QName qName = getQName((String) $1);
+ $$ = new NameTest(qName, true, false);
+ }
+ | qname
+ {
+ QName qName = getQName((String) $1);
+ $$ = new NameTest(qName, false, false);
+ }
+ ;
+
+qname:
+ NAME
+ | NAME COLON NAME
+ {
+ $$ = (String) $1 + ':' + (String) $3;
+ }
+ ;
+
+node_type:
+ COMMENT
+ {
+ $$ = new Short(Node.COMMENT_NODE);
+ }
+ | TEXT
+ {
+ $$ = new Short(Node.TEXT_NODE);
+ }
+ | PROCESSING_INSTRUCTION
+ {
+ $$ = new Short(Node.PROCESSING_INSTRUCTION_NODE);
+ }
+ | NODE
+ {
+ $$ = new Short((short) 0);
+ }
+ ;
+
+%%
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathTokenizer.java
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathTokenizer.java?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathTokenizer.java (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/gnu/xml/xpath/XPathTokenizer.java Thu Nov 8 16:56:19 2007
@@ -0,0 +1,592 @@
+/* XPathTokenizer.java --
+ Copyright (C) 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+package gnu.xml.xpath;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.Reader;
+import java.io.StringReader;
+import java.util.Map;
+import java.util.TreeMap;
+
+/*import antlr.Token;
+import antlr.TokenStream;
+import antlr.TokenStreamException;
+import antlr.TokenStreamIOException;*/
+
+/**
+ * XPath 1.0 expression tokenizer.
+ *
+ * @author <a href='mailto:dog at gnu.org'>Chris Burdess</a>
+ */
+public class XPathTokenizer
+implements XPathParser.yyInput
+//implements TokenStream
+{
+
+ static class XPathToken
+ //extends Token
+ {
+
+ int type;
+ String val;
+
+ XPathToken (int type)
+ {
+ this (type, null);
+ }
+
+ XPathToken (int type, String val)
+ {
+ //super (type);
+ this.type = type;
+ this.val = val;
+ }
+
+ public String getText ()
+ {
+ return val;
+ }
+
+ public String toString ()
+ {
+ return val;
+ }
+
+ }
+
+ static final Map keywords = new TreeMap ();
+ static
+ {
+ keywords.put ("ancestor", new Integer (XPathParser.ANCESTOR));
+ keywords.put ("ancestor-or-self", new Integer (XPathParser.ANCESTOR_OR_SELF));
+ keywords.put ("attribute", new Integer (XPathParser.ATTRIBUTE));
+ keywords.put ("child", new Integer (XPathParser.CHILD));
+ keywords.put ("descendant", new Integer (XPathParser.DESCENDANT));
+ keywords.put ("descendant-or-self", new Integer (XPathParser.DESCENDANT_OR_SELF));
+ keywords.put ("following", new Integer (XPathParser.FOLLOWING));
+ keywords.put ("following-sibling", new Integer (XPathParser.FOLLOWING_SIBLING));
+ keywords.put ("namespace", new Integer (XPathParser.NAMESPACE));
+ keywords.put ("parent", new Integer (XPathParser.PARENT));
+ keywords.put ("preceding", new Integer (XPathParser.PRECEDING));
+ keywords.put ("preceding-sibling", new Integer (XPathParser.PRECEDING_SIBLING));
+ keywords.put ("self", new Integer (XPathParser.SELF));
+ keywords.put ("div", new Integer (XPathParser.DIV));
+ keywords.put ("mod", new Integer (XPathParser.MOD));
+ keywords.put ("or", new Integer (XPathParser.OR));
+ keywords.put ("and", new Integer (XPathParser.AND));
+ keywords.put ("comment", new Integer (XPathParser.COMMENT));
+ keywords.put ("processing-instruction", new Integer (XPathParser.PROCESSING_INSTRUCTION));
+ keywords.put ("text", new Integer (XPathParser.TEXT));
+ keywords.put ("node", new Integer (XPathParser.NODE));
+ }
+
+ Reader in;
+ XPathToken token;
+ XPathToken lastToken;
+
+ public XPathTokenizer (String expr)
+ {
+ this (new StringReader (expr));
+ }
+
+ XPathTokenizer (Reader in)
+ {
+ this.in = in.markSupported () ? in : new BufferedReader (in);
+ }
+
+ /* Begin ANTLR specific *
+
+ public Token nextToken ()
+ throws TokenStreamException
+ {
+ try
+ {
+ if (!advance ())
+ {
+ throw new TokenStreamException ("eof");
+ }
+ token ();
+ return token;
+ }
+ catch (IOException e)
+ {
+ throw new TokenStreamIOException (e);
+ }
+ }
+
+ * End ANTLR specific */
+
+ public boolean advance ()
+ throws IOException
+ {
+ lastToken = token;
+ int c = in.read ();
+ switch (c)
+ {
+ case -1: // eof
+ return false;
+ case 0x20:
+ case 0x09:
+ case 0x0d:
+ case 0x0a: // skip whitespace
+ return advance ();
+ case 0x22: // "
+ case 0x27: // '
+ token = consume_literal (c);
+ break;
+ case 0x28: // (
+ token = new XPathToken (XPathParser.LP);
+ break;
+ case 0x29: // )
+ token = new XPathToken (XPathParser.RP);
+ break;
+ case 0x5b: // [
+ token = new XPathToken (XPathParser.LB);
+ break;
+ case 0x5d: // ]
+ token = new XPathToken (XPathParser.RB);
+ break;
+ case 0x2c: // ,
+ token = new XPathToken (XPathParser.COMMA);
+ break;
+ case 0x7c: // |
+ token = new XPathToken (XPathParser.PIPE);
+ break;
+ case 0x2f: // /
+ in.mark (1);
+ int d1 = in.read ();
+ if (d1 == 0x2f)
+ {
+ token = new XPathToken (XPathParser.DOUBLE_SLASH);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.SLASH);
+ }
+ break;
+ case 0x3d: // =
+ token = new XPathToken (XPathParser.EQ);
+ break;
+ case 0x21: // !
+ in.mark (1);
+ int d2 = in.read ();
+ if (d2 == 0x3d) // =
+ {
+ token = new XPathToken (XPathParser.NE);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.yyErrorCode);
+ }
+ break;
+ case 0x3e: // >
+ in.mark (1);
+ int d3 = in.read ();
+ if (d3 == 0x3d) // =
+ {
+ token = new XPathToken (XPathParser.GTE);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.GT);
+ }
+ break;
+ case 0x3c: // <
+ in.mark (1);
+ int d4 = in.read ();
+ if (d4 == 0x3d) // =
+ {
+ token = new XPathToken (XPathParser.LTE);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.LT);
+ }
+ break;
+ case 0x2b: // +
+ token = new XPathToken (XPathParser.PLUS);
+ break;
+ case 0x2d: // -
+ token = new XPathToken (XPathParser.MINUS);
+ break;
+ case 0x40: // @
+ token = new XPathToken (XPathParser.AT);
+ break;
+ case 0x2a: // *
+ token = new XPathToken (XPathParser.STAR);
+ break;
+ case 0x24: // $
+ token = new XPathToken (XPathParser.DOLLAR);
+ break;
+ case 0x3a: // :
+ in.mark (1);
+ int d5 = in.read ();
+ if (d5 == 0x3a)
+ {
+ token = new XPathToken (XPathParser.DOUBLE_COLON);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.COLON);
+ }
+ break;
+ case 0x2e: // .
+ in.mark (1);
+ int d6 = in.read ();
+ if (d6 == 0x2e)
+ {
+ token = new XPathToken (XPathParser.DOUBLE_DOT);
+ }
+ else
+ {
+ in.reset ();
+ token = new XPathToken (XPathParser.DOT);
+ }
+ break;
+ default:
+ if (c >= 0x30 && c <= 0x39)
+ {
+ token = consume_digits (c);
+ }
+ else if (c == 0x5f || Character.isLetter ((char) c))
+ {
+ token = consume_name (c);
+ }
+ else
+ {
+ token = new XPathToken (XPathParser.yyErrorCode);
+ }
+ }
+ return true;
+ }
+
+ public int token ()
+ {
+ return token.type;
+ }
+
+ public Object value ()
+ {
+ return token.val;
+ }
+
+ XPathToken consume_literal (int delimiter)
+ throws IOException
+ {
+ StringBuffer buf = new StringBuffer ();
+ while (true)
+ {
+ int c = in.read ();
+ if (c == -1)
+ {
+ return new XPathToken (XPathParser.yyErrorCode);
+ }
+ else if (c == delimiter)
+ {
+ return new XPathToken (XPathParser.LITERAL, buf.toString ());
+ }
+ else
+ {
+ buf.append ((char) c);
+ }
+ }
+ }
+
+ XPathToken consume_digits (int c)
+ throws IOException
+ {
+ StringBuffer buf = new StringBuffer ();
+ buf.append ((char) c);
+ while (true)
+ {
+ in.mark (1);
+ c = in.read ();
+ if (c >= 0x30 && c <= 0x39)
+ {
+ buf.append ((char) c);
+ }
+ else
+ {
+ in.reset ();
+ return new XPathToken (XPathParser.DIGITS, buf.toString ());
+ }
+ }
+ }
+
+ XPathToken consume_name (int c)
+ throws IOException
+ {
+ StringBuffer buf = new StringBuffer ();
+ buf.append ((char) c);
+ while (true)
+ {
+ in.mark (1);
+ c = in.read ();
+ if (isNameChar (c))
+ {
+ buf.append ((char) c);
+ }
+ else
+ {
+ in.reset ();
+ String name = buf.toString ();
+ Integer keyword = (Integer) keywords.get (name);
+ if (keyword == null)
+ {
+ return new XPathToken (XPathParser.NAME, name);
+ }
+ else
+ {
+ int val = keyword.intValue ();
+ switch (val)
+ {
+ case XPathParser.NODE:
+ case XPathParser.COMMENT:
+ case XPathParser.TEXT:
+ case XPathParser.PROCESSING_INSTRUCTION:
+ // Consume subsequent (
+ in.mark (1);
+ do
+ {
+ c = in.read ();
+ }
+ while (c == 0x20 || c == 0x09);
+ if (c != 0x28)
+ {
+ in.reset ();
+ return new XPathToken (XPathParser.NAME, name);
+ }
+ break;
+ case XPathParser.CHILD:
+ case XPathParser.PARENT:
+ case XPathParser.SELF:
+ case XPathParser.DESCENDANT:
+ case XPathParser.ANCESTOR:
+ case XPathParser.DESCENDANT_OR_SELF:
+ case XPathParser.ANCESTOR_OR_SELF:
+ case XPathParser.ATTRIBUTE:
+ case XPathParser.NAMESPACE:
+ case XPathParser.FOLLOWING:
+ case XPathParser.FOLLOWING_SIBLING:
+ case XPathParser.PRECEDING:
+ case XPathParser.PRECEDING_SIBLING:
+ // Check that this is an axis specifier
+ in.mark(1);
+ do
+ {
+ c = in.read();
+ }
+ while (c == 0x20 || c == 0x09);
+ if (c == 0x3a)
+ {
+ c = in.read();
+ if (c == 0x3a)
+ {
+ in.reset();
+ return new XPathToken(val);
+ }
+ }
+ in.reset();
+ return new XPathToken(XPathParser.NAME, name);
+ case XPathParser.DIV:
+ case XPathParser.MOD:
+ // May be a name
+ if (lastToken == null)
+ {
+ return new XPathToken(XPathParser.NAME, name);
+ }
+ switch (lastToken.type)
+ {
+ case XPathParser.LP:
+ case XPathParser.LB:
+ case XPathParser.COMMA:
+ case XPathParser.PIPE:
+ case XPathParser.EQ:
+ case XPathParser.NE:
+ case XPathParser.GT:
+ case XPathParser.LT:
+ case XPathParser.GTE:
+ case XPathParser.LTE:
+ case XPathParser.PLUS:
+ case XPathParser.MINUS:
+ case XPathParser.STAR:
+ case XPathParser.AT:
+ case XPathParser.DOLLAR:
+ case XPathParser.COLON:
+ case XPathParser.DOUBLE_COLON:
+ case XPathParser.DIV:
+ case XPathParser.MOD:
+ case XPathParser.OR:
+ case XPathParser.AND:
+ case XPathParser.SLASH:
+ return new XPathToken(XPathParser.NAME, name);
+ }
+ break;
+ }
+ return new XPathToken (val);
+ }
+ }
+ }
+ }
+
+ boolean isNameChar (int c)
+ {
+ /* Name */
+ return (c == 0x5f
+ || c == 0x2d
+ || c == 0x2e
+ || (c >= 0x30 && c <= 0x39)
+ /* CombiningChar */
+ || (c >= 0x0300 && c <= 0x0345)
+ || (c >= 0x0360 && c <= 0x0361)
+ || (c >= 0x0483 && c <= 0x0486)
+ || (c >= 0x0591 && c <= 0x05A1)
+ || (c >= 0x05A3 && c <= 0x05B9)
+ || (c >= 0x05BB && c <= 0x05BD)
+ || c == 0x05BF
+ || (c >= 0x05C1 && c <= 0x05C2)
+ || c == 0x05C4
+ || (c >= 0x064B && c <= 0x0652)
+ || c == 0x0670
+ || (c >= 0x06D6 && c <= 0x06DC)
+ || (c >= 0x06DD && c <= 0x06DF)
+ || (c >= 0x06E0 && c <= 0x06E4)
+ || (c >= 0x06E7 && c <= 0x06E8)
+ || (c >= 0x06EA && c <= 0x06ED)
+ || (c >= 0x0901 && c <= 0x0903)
+ || c == 0x093C
+ || (c >= 0x093E && c <= 0x094C)
+ || c == 0x094D
+ || (c >= 0x0951 && c <= 0x0954)
+ || (c >= 0x0962 && c <= 0x0963)
+ || (c >= 0x0981 && c <= 0x0983)
+ || c == 0x09BC
+ || c == 0x09BE
+ || c == 0x09BF
+ || (c >= 0x09C0 && c <= 0x09C4)
+ || (c >= 0x09C7 && c <= 0x09C8)
+ || (c >= 0x09CB && c <= 0x09CD)
+ || c == 0x09D7
+ || (c >= 0x09E2 && c <= 0x09E3)
+ || c == 0x0A02
+ || c == 0x0A3C
+ || c == 0x0A3E
+ || c == 0x0A3F
+ || (c >= 0x0A40 && c <= 0x0A42)
+ || (c >= 0x0A47 && c <= 0x0A48)
+ || (c >= 0x0A4B && c <= 0x0A4D)
+ || (c >= 0x0A70 && c <= 0x0A71)
+ || (c >= 0x0A81 && c <= 0x0A83)
+ || c == 0x0ABC
+ || (c >= 0x0ABE && c <= 0x0AC5)
+ || (c >= 0x0AC7 && c <= 0x0AC9)
+ || (c >= 0x0ACB && c <= 0x0ACD)
+ || (c >= 0x0B01 && c <= 0x0B03)
+ || c == 0x0B3C
+ || (c >= 0x0B3E && c <= 0x0B43)
+ || (c >= 0x0B47 && c <= 0x0B48)
+ || (c >= 0x0B4B && c <= 0x0B4D)
+ || (c >= 0x0B56 && c <= 0x0B57)
+ || (c >= 0x0B82 && c <= 0x0B83)
+ || (c >= 0x0BBE && c <= 0x0BC2)
+ || (c >= 0x0BC6 && c <= 0x0BC8)
+ || (c >= 0x0BCA && c <= 0x0BCD)
+ || c == 0x0BD7
+ || (c >= 0x0C01 && c <= 0x0C03)
+ || (c >= 0x0C3E && c <= 0x0C44)
+ || (c >= 0x0C46 && c <= 0x0C48)
+ || (c >= 0x0C4A && c <= 0x0C4D)
+ || (c >= 0x0C55 && c <= 0x0C56)
+ || (c >= 0x0C82 && c <= 0x0C83)
+ || (c >= 0x0CBE && c <= 0x0CC4)
+ || (c >= 0x0CC6 && c <= 0x0CC8)
+ || (c >= 0x0CCA && c <= 0x0CCD)
+ || (c >= 0x0CD5 && c <= 0x0CD6)
+ || (c >= 0x0D02 && c <= 0x0D03)
+ || (c >= 0x0D3E && c <= 0x0D43)
+ || (c >= 0x0D46 && c <= 0x0D48)
+ || (c >= 0x0D4A && c <= 0x0D4D)
+ || c == 0x0D57
+ || c == 0x0E31
+ || (c >= 0x0E34 && c <= 0x0E3A)
+ || (c >= 0x0E47 && c <= 0x0E4E)
+ || c == 0x0EB1
+ || (c >= 0x0EB4 && c <= 0x0EB9)
+ || (c >= 0x0EBB && c <= 0x0EBC)
+ || (c >= 0x0EC8 && c <= 0x0ECD)
+ || (c >= 0x0F18 && c <= 0x0F19)
+ || c == 0x0F35
+ || c == 0x0F37
+ || c == 0x0F39
+ || c == 0x0F3E
+ || c == 0x0F3F
+ || (c >= 0x0F71 && c <= 0x0F84)
+ || (c >= 0x0F86 && c <= 0x0F8B)
+ || (c >= 0x0F90 && c <= 0x0F95)
+ || c == 0x0F97
+ || (c >= 0x0F99 && c <= 0x0FAD)
+ || (c >= 0x0FB1 && c <= 0x0FB7)
+ || c == 0x0FB9
+ || (c >= 0x20D0 && c <= 0x20DC)
+ || c == 0x20E1
+ || (c >= 0x302A && c <= 0x302F)
+ || c == 0x3099
+ || c == 0x309A
+ /* Extender */
+ || c == 0x00B7
+ || c == 0x02D0
+ || c == 0x02D1
+ || c == 0x0387
+ || c == 0x0640
+ || c == 0x0E46
+ || c == 0x0EC6
+ || c == 0x3005
+ || (c >= 0x3031 && c <= 0x3035)
+ || (c >= 0x309D && c <= 0x309E)
+ || (c >= 0x30FC && c <= 0x30FE)
+ /* Name */
+ || Character.isLetter ((char) c));
+ }
+
+}
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/GtkDragSourceContextPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/GtkDragSourceContextPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/GtkDragSourceContextPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/GtkDragSourceContextPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __GtkDragSourceContextPeer__
+#define __GtkDragSourceContextPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_dnd_peer_gtk_GtkDragSourceContextPeer_nativeStartDrag (JNIEnv *env, jobject, jobject, jint, jint, jint, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_dnd_peer_gtk_GtkDragSourceContextPeer_connectSignals (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_dnd_peer_gtk_GtkDragSourceContextPeer_create (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_dnd_peer_gtk_GtkDragSourceContextPeer_nativeSetCursor (JNIEnv *env, jobject, jint) ;
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __GtkDragSourceContextPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.am
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.am?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.am (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.am Thu Nov 8 16:56:19 2007
@@ -0,0 +1,231 @@
+## GCJ LOCAL: headers are installed specially.
+##include_HEADERS = jni.h jni_md.h jawt.h jawt_md.h
+
+DISTCLEANFILES = jni_md.h config-int.h
+
+ARG_JNI_JAVAH = -jni
+ARG_CLASSPATH_JAVAH = -bootclasspath
+JAVAH = $(USER_JAVAH) $(ARG_JNI_JAVAH) $(ARG_CLASSPATH_JAVAH) ../lib:$(USER_CLASSLIB)
+CLASSDIR = lib
+
+SOUND_H_FILES = \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h
+
+XMLJ_H_FILES = \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocument.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNodeList.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNotation.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeElement.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeEntity.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNode.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeAttr.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_sax_GnomeLocator.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_transform_GnomeTransformer.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h
+
+GTKPEER_H_FILES = \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_CairoSurface.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_ComponentGraphics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkFontPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkClipboard.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkFramePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkListPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkSelection.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkToolkit.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h \
+$(top_srcdir)/include/GtkDragSourceContextPeer.h
+
+QTPEER_H_FILES = \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtToolkit.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtAudioClip.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScreenDevice.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtButtonPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtVolatileImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFontPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtChoicePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtGraphics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QPen.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtPanelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QPainterPath.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFontMetrics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QMatrix.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtLabelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFramePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtListPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtCanvasPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_MainQtThread.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtContainerPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h
+
+GCONF_PREFS_FILES = \
+$(top_srcdir)/include/gnu_java_util_prefs_gconf_GConfNativePeer.h
+
+H_FILES = \
+$(SOUND_H_FILES) \
+$(XMLJ_H_FILES) \
+$(GTKPEER_H_FILES) \
+$(QTPEER_H_FILES) \
+$(GCONF_PREFS_FILES) \
+$(top_srcdir)/include/gnu_java_net_VMPlainDatagramSocketImpl.h \
+$(top_srcdir)/include/gnu_java_net_VMPlainSocketImpl.h \
+$(top_srcdir)/include/gnu_java_net_local_LocalSocketImpl.h \
+$(top_srcdir)/include/gnu_java_nio_VMChannel.h \
+$(top_srcdir)/include/gnu_java_nio_VMPipe.h \
+$(top_srcdir)/include/gnu_java_nio_VMSelector.h \
+$(top_srcdir)/include/gnu_java_nio_channels_FileChannelImpl.h \
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvEncoder.h \
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvDecoder.h \
+$(top_srcdir)/include/java_io_VMFile.h \
+$(top_srcdir)/include/java_io_VMObjectInputStream.h \
+$(top_srcdir)/include/java_io_VMObjectStreamClass.h \
+$(top_srcdir)/include/java_lang_VMDouble.h \
+$(top_srcdir)/include/java_lang_VMFloat.h \
+$(top_srcdir)/include/java_lang_VMMath.h \
+$(top_srcdir)/include/java_lang_VMProcess.h \
+$(top_srcdir)/include/java_lang_VMSystem.h \
+$(top_srcdir)/include/java_lang_reflect_VMArray.h \
+$(top_srcdir)/include/java_net_VMInetAddress.h \
+$(top_srcdir)/include/java_net_VMNetworkInterface.h \
+$(top_srcdir)/include/java_net_VMURLConnection.h \
+$(top_srcdir)/include/java_nio_VMDirectByteBuffer.h \
+$(top_srcdir)/include/java_nio_MappedByteBufferImpl.h \
+$(top_srcdir)/include/java_util_VMTimeZone.h
+
+if CREATE_JNI_HEADERS
+
+all-local: $(H_FILES)
+
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/dom/%.class
+ $(JAVAH) -o $@ gnu.xml.libxmlj.dom.$*
+
+$(top_srcdir)/include/gnu_xml_libxmlj_sax_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/sax/%.class
+ $(JAVAH) -o $@ gnu.xml.libxmlj.sax.$*
+
+$(top_srcdir)/include/gnu_xml_libxmlj_transform_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/transform/%.class
+ $(JAVAH) -o $@ gnu.xml.libxmlj.transform.$*
+
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/awt/peer/gtk/%.class
+ $(JAVAH) -o $@ gnu.java.awt.peer.gtk.$*
+
+$(top_srcdir)/include/gnu_java_awt_peer_qt_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/awt/peer/qt/%.class
+ $(JAVAH) -o $@ gnu.java.awt.peer.qt.$*
+
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_%.h: $(top_builddir)/$(CLASSDIR)/gnu/javax/sound/midi/alsa/%.class
+ $(JAVAH) -o $@ gnu.javax.sound.midi.alsa.$*
+
+$(top_srcdir)/include/gnu_javax_sound_midi_dssi_%.h: $(top_builddir)/$(CLASSDIR)/gnu/javax/sound/midi/dssi/%.class
+ $(JAVAH) -o $@ gnu.javax.sound.midi.dssi.$*
+
+$(top_srcdir)/include/gnu_java_util_prefs_gconf_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/util/prefs/gconf/%.class
+ $(JAVAH) -o $@ gnu.java.util.prefs.gconf.$*
+
+$(top_srcdir)/include/gnu_java_net_VMPlainDatagramSocketImpl.h: $(top_srcdir)/vm/reference/gnu/java/net/VMPlainDatagramSocketImpl.java
+ $(JAVAH) -o $@ gnu.java.net.VMPlainDatagramSocketImpl
+$(top_srcdir)/include/gnu_java_net_VMPlainSocketImpl.h: $(top_srcdir)/vm/reference/gnu/java/net/VMPlainSocketImpl.java
+ $(JAVAH) -o $@ gnu.java.net.VMPlainSocketImpl
+$(top_srcdir)/include/gnu_java_net_local_LocalSocketImpl.h: $(top_srcdir)/gnu/java/net/local/LocalSocketImpl.java
+ $(JAVAH) -o $@ gnu.java.net.local.LocalSocketImpl
+$(top_srcdir)/include/gnu_java_nio_VMChannel.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMChannel.java
+ $(JAVAH) -o $@ gnu.java.nio.VMChannel
+$(top_srcdir)/include/gnu_java_nio_VMPipe.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMPipe.java
+ $(JAVAH) -o $@ gnu.java.nio.VMPipe
+$(top_srcdir)/include/gnu_java_nio_VMSelector.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMSelector.java
+ $(JAVAH) -o $@ gnu.java.nio.VMSelector
+$(top_srcdir)/include/java_io_VMFile.h: $(top_srcdir)/vm/reference/java/io/VMFile.java
+ $(JAVAH) -o $@ java.io.VMFile
+$(top_srcdir)/include/java_io_VMObjectInputStream.h: $(top_srcdir)/vm/reference/java/io/VMObjectInputStream.java
+ $(JAVAH) -o $@ java.io.VMObjectInputStream
+$(top_srcdir)/include/java_io_VMObjectStreamClass.h: $(top_srcdir)/vm/reference/java/io/VMObjectStreamClass.java
+ $(JAVAH) -o $@ java.io.VMObjectStreamClass
+$(top_srcdir)/include/java_lang_VMMath.h: $(top_srcdir)/vm/reference/java/lang/VMMath.java
+ $(JAVAH) -o $@ java.lang.VMMath
+$(top_srcdir)/include/java_lang_VMDouble.h: $(top_srcdir)/vm/reference/java/lang/VMDouble.java
+ $(JAVAH) -o $@ java.lang.VMDouble
+$(top_srcdir)/include/java_lang_VMFloat.h: $(top_srcdir)/vm/reference/java/lang/VMFloat.java
+ $(JAVAH) -o $@ java.lang.VMFloat
+$(top_srcdir)/include/java_lang_VMProcess.h: $(top_srcdir)/vm/reference/java/lang/VMProcess.java
+ $(JAVAH) -o $@ java.lang.VMProcess
+$(top_srcdir)/include/java_lang_VMSystem.h: $(top_srcdir)/vm/reference/java/lang/VMSystem.java
+ $(JAVAH) -o $@ java.lang.VMSystem
+$(top_srcdir)/include/java_lang_reflect_VMArray.h: $(top_srcdir)/vm/reference/java/lang/reflect/VMArray.java
+ $(JAVAH) -o $@ java.lang.reflect.VMArray
+$(top_srcdir)/include/java_net_VMInetAddress.h: $(top_srcdir)/vm/reference/java/net/VMInetAddress.java
+ $(JAVAH) -o $@ java.net.VMInetAddress
+$(top_srcdir)/include/java_net_VMNetworkInterface.h: $(top_srcdir)/vm/reference/java/net/VMNetworkInterface.java
+ $(JAVAH) -o $@ java.net.VMNetworkInterface
+$(top_srcdir)/include/java_net_VMURLConnection.h: $(top_srcdir)/vm/reference/java/net/VMURLConnection.java
+ $(JAVAH) -o $@ java.net.VMURLConnection
+$(top_srcdir)/include/java_nio_VMDirectByteBuffer.h: $(top_srcdir)/vm/reference/java/nio/VMDirectByteBuffer.java
+ $(JAVAH) -o $@ java.nio.VMDirectByteBuffer
+$(top_srcdir)/include/java_nio_MappedByteBufferImpl.h: $(top_srcdir)/java/nio/MappedByteBufferImpl.java
+ $(JAVAH) -o $@ java.nio.MappedByteBufferImpl
+$(top_srcdir)/include/gnu_java_nio_channels_FileChannelImpl.h: $(top_srcdir)/gnu/java/nio/channels/FileChannelImpl.java
+ $(JAVAH) -o $@ gnu.java.nio.channels.FileChannelImpl
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvDecoder.h: $(top_srcdir)/gnu/java/nio/charset/iconv/IconvDecoder.java
+ $(JAVAH) -o $@ gnu.java.nio.charset.iconv.IconvDecoder
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvEncoder.h: $(top_srcdir)/gnu/java/nio/charset/iconv/IconvEncoder.java
+ $(JAVAH) -o $@ gnu.java.nio.charset.iconv.IconvEncoder
+$(top_srcdir)/include/java_util_VMTimeZone.h: $(top_srcdir)/vm/reference/java/util/VMTimeZone.java
+ $(JAVAH) -o $@ java.util.VMTimeZone
+
+endif # CREATE_JNI_HEADERS
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.in
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.in?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.in (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/Makefile.in Thu Nov 8 16:56:19 2007
@@ -0,0 +1,692 @@
+# Makefile.in generated by automake 1.9.6 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005 Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+ at SET_MAKE@
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+top_builddir = ..
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+INSTALL = @INSTALL@
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = include
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(srcdir)/config.h.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/../../config/depstand.m4 \
+ $(top_srcdir)/../../config/lead-dot.m4 \
+ $(top_srcdir)/../../config/multi.m4 \
+ $(top_srcdir)/../../libtool.m4 $(top_srcdir)/m4/acattribute.m4 \
+ $(top_srcdir)/m4/accross.m4 $(top_srcdir)/m4/acinclude.m4 \
+ $(top_srcdir)/m4/ax_create_stdint_h.m4 \
+ $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \
+ $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \
+ $(top_srcdir)/m4/pkg.m4 $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
+CONFIG_HEADER = config.h
+CONFIG_CLEAN_FILES =
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMDEP_FALSE = @AMDEP_FALSE@
+AMDEP_TRUE = @AMDEP_TRUE@
+AMTAR = @AMTAR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BUILD_CLASS_FILES_FALSE = @BUILD_CLASS_FILES_FALSE@
+BUILD_CLASS_FILES_TRUE = @BUILD_CLASS_FILES_TRUE@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CLASSPATH_CONVENIENCE = @CLASSPATH_CONVENIENCE@
+CLASSPATH_INCLUDES = @CLASSPATH_INCLUDES@
+CLASSPATH_MODULE = @CLASSPATH_MODULE@
+COLLECTIONS_PREFIX = @COLLECTIONS_PREFIX@
+CP = @CP@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CREATE_ALSA_LIBRARIES_FALSE = @CREATE_ALSA_LIBRARIES_FALSE@
+CREATE_ALSA_LIBRARIES_TRUE = @CREATE_ALSA_LIBRARIES_TRUE@
+CREATE_API_DOCS_FALSE = @CREATE_API_DOCS_FALSE@
+CREATE_API_DOCS_TRUE = @CREATE_API_DOCS_TRUE@
+CREATE_COLLECTIONS_FALSE = @CREATE_COLLECTIONS_FALSE@
+CREATE_COLLECTIONS_TRUE = @CREATE_COLLECTIONS_TRUE@
+CREATE_CORE_JNI_LIBRARIES_FALSE = @CREATE_CORE_JNI_LIBRARIES_FALSE@
+CREATE_CORE_JNI_LIBRARIES_TRUE = @CREATE_CORE_JNI_LIBRARIES_TRUE@
+CREATE_DSSI_LIBRARIES_FALSE = @CREATE_DSSI_LIBRARIES_FALSE@
+CREATE_DSSI_LIBRARIES_TRUE = @CREATE_DSSI_LIBRARIES_TRUE@
+CREATE_GCONF_PEER_LIBRARIES_FALSE = @CREATE_GCONF_PEER_LIBRARIES_FALSE@
+CREATE_GCONF_PEER_LIBRARIES_TRUE = @CREATE_GCONF_PEER_LIBRARIES_TRUE@
+CREATE_GTK_PEER_LIBRARIES_FALSE = @CREATE_GTK_PEER_LIBRARIES_FALSE@
+CREATE_GTK_PEER_LIBRARIES_TRUE = @CREATE_GTK_PEER_LIBRARIES_TRUE@
+CREATE_JNI_HEADERS_FALSE = @CREATE_JNI_HEADERS_FALSE@
+CREATE_JNI_HEADERS_TRUE = @CREATE_JNI_HEADERS_TRUE@
+CREATE_JNI_LIBRARIES_FALSE = @CREATE_JNI_LIBRARIES_FALSE@
+CREATE_JNI_LIBRARIES_TRUE = @CREATE_JNI_LIBRARIES_TRUE@
+CREATE_PLUGIN_FALSE = @CREATE_PLUGIN_FALSE@
+CREATE_PLUGIN_TRUE = @CREATE_PLUGIN_TRUE@
+CREATE_QT_PEER_LIBRARIES_FALSE = @CREATE_QT_PEER_LIBRARIES_FALSE@
+CREATE_QT_PEER_LIBRARIES_TRUE = @CREATE_QT_PEER_LIBRARIES_TRUE@
+CREATE_WRAPPERS_FALSE = @CREATE_WRAPPERS_FALSE@
+CREATE_WRAPPERS_TRUE = @CREATE_WRAPPERS_TRUE@
+CREATE_XMLJ_LIBRARY_FALSE = @CREATE_XMLJ_LIBRARY_FALSE@
+CREATE_XMLJ_LIBRARY_TRUE = @CREATE_XMLJ_LIBRARY_TRUE@
+CXX = @CXX@
+CXXCPP = @CXXCPP@
+CXXDEPMODE = @CXXDEPMODE@
+CXXFLAGS = @CXXFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DATE = @DATE@
+DEFAULT_PREFS_PEER = @DEFAULT_PREFS_PEER@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+ECJ = @ECJ@
+EGREP = @EGREP@
+ENABLE_LOCAL_SOCKETS_FALSE = @ENABLE_LOCAL_SOCKETS_FALSE@
+ENABLE_LOCAL_SOCKETS_TRUE = @ENABLE_LOCAL_SOCKETS_TRUE@
+ERROR_CFLAGS = @ERROR_CFLAGS@
+EXAMPLESDIR = @EXAMPLESDIR@
+EXEEXT = @EXEEXT@
+FASTJAR = @FASTJAR@
+FIND = @FIND@
+FOUND_CACAO_FALSE = @FOUND_CACAO_FALSE@
+FOUND_CACAO_TRUE = @FOUND_CACAO_TRUE@
+FOUND_ECJ_FALSE = @FOUND_ECJ_FALSE@
+FOUND_ECJ_TRUE = @FOUND_ECJ_TRUE@
+FOUND_GCJX_FALSE = @FOUND_GCJX_FALSE@
+FOUND_GCJX_TRUE = @FOUND_GCJX_TRUE@
+FOUND_GCJ_FALSE = @FOUND_GCJ_FALSE@
+FOUND_GCJ_TRUE = @FOUND_GCJ_TRUE@
+FOUND_JIKES_FALSE = @FOUND_JIKES_FALSE@
+FOUND_JIKES_TRUE = @FOUND_JIKES_TRUE@
+FOUND_KJC_FALSE = @FOUND_KJC_FALSE@
+FOUND_KJC_TRUE = @FOUND_KJC_TRUE@
+FREETYPE2_CFLAGS = @FREETYPE2_CFLAGS@
+FREETYPE2_LIBS = @FREETYPE2_LIBS@
+GCJ = @GCJ@
+GCJX = @GCJX@
+GCONF_CFLAGS = @GCONF_CFLAGS@
+GCONF_LIBS = @GCONF_LIBS@
+GDK_CFLAGS = @GDK_CFLAGS@
+GDK_LIBS = @GDK_LIBS@
+GJDOC = @GJDOC@
+GLIB_CFLAGS = @GLIB_CFLAGS@
+GLIB_LIBS = @GLIB_LIBS@
+GTK_CFLAGS = @GTK_CFLAGS@
+GTK_LIBS = @GTK_LIBS@
+INIT_LOAD_LIBRARY = @INIT_LOAD_LIBRARY@
+INSTALL_CLASS_FILES_FALSE = @INSTALL_CLASS_FILES_FALSE@
+INSTALL_CLASS_FILES_TRUE = @INSTALL_CLASS_FILES_TRUE@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_GLIBJ_ZIP_FALSE = @INSTALL_GLIBJ_ZIP_FALSE@
+INSTALL_GLIBJ_ZIP_TRUE = @INSTALL_GLIBJ_ZIP_TRUE@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+JAVA_LANG_SYSTEM_EXPLICIT_INITIALIZATION = @JAVA_LANG_SYSTEM_EXPLICIT_INITIALIZATION@
+JAY = @JAY@
+JAY_SKELETON = @JAY_SKELETON@
+JIKES = @JIKES@
+JIKESENCODING = @JIKESENCODING@
+JIKESWARNINGS = @JIKESWARNINGS@
+KJC = @KJC@
+LDFLAGS = @LDFLAGS@
+LIBDEBUG = @LIBDEBUG@
+LIBICONV = @LIBICONV@
+LIBMAGIC = @LIBMAGIC@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIBVERSION = @LIBVERSION@
+LN_S = @LN_S@
+LTLIBICONV = @LTLIBICONV@
+LTLIBOBJS = @LTLIBOBJS@
+MAINT = @MAINT@
+MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
+MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
+MAKEINFO = @MAKEINFO@
+MKDIR = @MKDIR@
+MOC = @MOC@
+MOZILLA_CFLAGS = @MOZILLA_CFLAGS@
+MOZILLA_LIBS = @MOZILLA_LIBS@
+OBJEXT = @OBJEXT@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PANGOFT2_CFLAGS = @PANGOFT2_CFLAGS@
+PANGOFT2_LIBS = @PANGOFT2_LIBS@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PATH_TO_ESCHER = @PATH_TO_ESCHER@
+PATH_TO_GLIBJ_ZIP = @PATH_TO_GLIBJ_ZIP@
+PERL = @PERL@
+PKG_CONFIG = @PKG_CONFIG@
+PLUGIN_DIR = @PLUGIN_DIR@
+QT_CFLAGS = @QT_CFLAGS@
+QT_LIBS = @QT_LIBS@
+RANLIB = @RANLIB@
+REGEN_PARSERS_FALSE = @REGEN_PARSERS_FALSE@
+REGEN_PARSERS_TRUE = @REGEN_PARSERS_TRUE@
+REMOVE = @REMOVE@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRICT_WARNING_CFLAGS = @STRICT_WARNING_CFLAGS@
+STRIP = @STRIP@
+USER_CLASSLIB = @USER_CLASSLIB@
+USER_JAVAH = @USER_JAVAH@
+USER_SPECIFIED_CLASSLIB_FALSE = @USER_SPECIFIED_CLASSLIB_FALSE@
+USER_SPECIFIED_CLASSLIB_TRUE = @USER_SPECIFIED_CLASSLIB_TRUE@
+USER_SPECIFIED_JAVAH_FALSE = @USER_SPECIFIED_JAVAH_FALSE@
+USER_SPECIFIED_JAVAH_TRUE = @USER_SPECIFIED_JAVAH_TRUE@
+USE_ESCHER_FALSE = @USE_ESCHER_FALSE@
+USE_ESCHER_TRUE = @USE_ESCHER_TRUE@
+USE_PREBUILT_GLIBJ_ZIP_FALSE = @USE_PREBUILT_GLIBJ_ZIP_FALSE@
+USE_PREBUILT_GLIBJ_ZIP_TRUE = @USE_PREBUILT_GLIBJ_ZIP_TRUE@
+VERSION = @VERSION@
+VM_BINARY = @VM_BINARY@
+WARNING_CFLAGS = @WARNING_CFLAGS@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+XSLT_CFLAGS = @XSLT_CFLAGS@
+XSLT_LIBS = @XSLT_LIBS@
+XTEST_LIBS = @XTEST_LIBS@
+X_CFLAGS = @X_CFLAGS@
+X_EXTRA_LIBS = @X_EXTRA_LIBS@
+X_LIBS = @X_LIBS@
+X_PRE_LIBS = @X_PRE_LIBS@
+ZIP = @ZIP@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_CXX = @ac_ct_CXX@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_STRIP = @ac_ct_STRIP@
+am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
+am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
+am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@
+am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+datadir = @datadir@
+default_toolkit = @default_toolkit@
+exec_prefix = @exec_prefix@
+glibjdir = @glibjdir@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+multi_basedir = @multi_basedir@
+nativeexeclibdir = @nativeexeclibdir@
+oldincludedir = @oldincludedir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+toolexeclibdir = @toolexeclibdir@
+vm_classes = @vm_classes@
+DISTCLEANFILES = jni_md.h config-int.h
+ARG_JNI_JAVAH = -jni
+ARG_CLASSPATH_JAVAH = -bootclasspath
+JAVAH = $(USER_JAVAH) $(ARG_JNI_JAVAH) $(ARG_CLASSPATH_JAVAH) ../lib:$(USER_CLASSLIB)
+CLASSDIR = lib
+SOUND_H_FILES = \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h \
+$(top_srcdir)/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h
+
+XMLJ_H_FILES = \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocument.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNodeList.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNotation.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeElement.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeEntity.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNode.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_dom_GnomeAttr.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_sax_GnomeLocator.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_transform_GnomeTransformer.h \
+$(top_srcdir)/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h
+
+GTKPEER_H_FILES = \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_CairoSurface.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_ComponentGraphics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkFontPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkClipboard.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkFramePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkListPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkSelection.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkToolkit.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h \
+$(top_srcdir)/include/GtkDragSourceContextPeer.h
+
+QTPEER_H_FILES = \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtToolkit.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtAudioClip.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScreenDevice.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtButtonPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtWindowPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtVolatileImage.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFontPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtChoicePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtGraphics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QPen.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtPanelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QPainterPath.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFontMetrics.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QMatrix.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtLabelPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFramePeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtListPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtCanvasPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_MainQtThread.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtContainerPeer.h \
+$(top_srcdir)/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h
+
+GCONF_PREFS_FILES = \
+$(top_srcdir)/include/gnu_java_util_prefs_gconf_GConfNativePeer.h
+
+H_FILES = \
+$(SOUND_H_FILES) \
+$(XMLJ_H_FILES) \
+$(GTKPEER_H_FILES) \
+$(QTPEER_H_FILES) \
+$(GCONF_PREFS_FILES) \
+$(top_srcdir)/include/gnu_java_net_VMPlainDatagramSocketImpl.h \
+$(top_srcdir)/include/gnu_java_net_VMPlainSocketImpl.h \
+$(top_srcdir)/include/gnu_java_net_local_LocalSocketImpl.h \
+$(top_srcdir)/include/gnu_java_nio_VMChannel.h \
+$(top_srcdir)/include/gnu_java_nio_VMPipe.h \
+$(top_srcdir)/include/gnu_java_nio_VMSelector.h \
+$(top_srcdir)/include/gnu_java_nio_channels_FileChannelImpl.h \
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvEncoder.h \
+$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvDecoder.h \
+$(top_srcdir)/include/java_io_VMFile.h \
+$(top_srcdir)/include/java_io_VMObjectInputStream.h \
+$(top_srcdir)/include/java_io_VMObjectStreamClass.h \
+$(top_srcdir)/include/java_lang_VMDouble.h \
+$(top_srcdir)/include/java_lang_VMFloat.h \
+$(top_srcdir)/include/java_lang_VMMath.h \
+$(top_srcdir)/include/java_lang_VMProcess.h \
+$(top_srcdir)/include/java_lang_VMSystem.h \
+$(top_srcdir)/include/java_lang_reflect_VMArray.h \
+$(top_srcdir)/include/java_net_VMInetAddress.h \
+$(top_srcdir)/include/java_net_VMNetworkInterface.h \
+$(top_srcdir)/include/java_net_VMURLConnection.h \
+$(top_srcdir)/include/java_nio_VMDirectByteBuffer.h \
+$(top_srcdir)/include/java_nio_MappedByteBufferImpl.h \
+$(top_srcdir)/include/java_util_VMTimeZone.h
+
+all: config.h
+ $(MAKE) $(AM_MAKEFLAGS) all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu include/Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --gnu include/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+config.h: stamp-h1
+ @if test ! -f $@; then \
+ rm -f stamp-h1; \
+ $(MAKE) stamp-h1; \
+ else :; fi
+
+stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
+ @rm -f stamp-h1
+ cd $(top_builddir) && $(SHELL) ./config.status include/config.h
+$(srcdir)/config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_srcdir) && $(AUTOHEADER)
+ rm -f stamp-h1
+ touch $@
+
+distclean-hdr:
+ -rm -f config.h stamp-h1
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool
+uninstall-info-am:
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
+ list='$(DISTFILES)'; for file in $$list; do \
+ case $$file in \
+ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
+ esac; \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test "$$dir" != "$$file" && test "$$dir" != "."; then \
+ dir="/$$dir"; \
+ $(mkdir_p) "$(distdir)$$dir"; \
+ else \
+ dir=''; \
+ fi; \
+ if test -d $$d/$$file; then \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+ fi; \
+ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+ else \
+ test -f $(distdir)/$$file \
+ || cp -p $$d/$$file $(distdir)/$$file \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+ at CREATE_JNI_HEADERS_FALSE@all-local:
+all-am: Makefile config.h all-local
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic distclean-hdr \
+ distclean-libtool
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-exec-am:
+
+install-info: install-info-am
+
+install-man:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am: uninstall-info-am
+
+.PHONY: all all-am all-local check check-am clean clean-generic \
+ clean-libtool distclean distclean-generic distclean-hdr \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-exec \
+ install-exec-am install-info install-info-am install-man \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ uninstall uninstall-am uninstall-info-am
+
+
+ at CREATE_JNI_HEADERS_TRUE@all-local: $(H_FILES)
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_xml_libxmlj_dom_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/dom/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.xml.libxmlj.dom.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_xml_libxmlj_sax_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/sax/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.xml.libxmlj.sax.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_xml_libxmlj_transform_%.h: $(top_builddir)/$(CLASSDIR)/gnu/xml/libxmlj/transform/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.xml.libxmlj.transform.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_awt_peer_gtk_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/awt/peer/gtk/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.awt.peer.gtk.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_awt_peer_qt_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/awt/peer/qt/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.awt.peer.qt.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_javax_sound_midi_alsa_%.h: $(top_builddir)/$(CLASSDIR)/gnu/javax/sound/midi/alsa/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.javax.sound.midi.alsa.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_javax_sound_midi_dssi_%.h: $(top_builddir)/$(CLASSDIR)/gnu/javax/sound/midi/dssi/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.javax.sound.midi.dssi.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_util_prefs_gconf_%.h: $(top_builddir)/$(CLASSDIR)/gnu/java/util/prefs/gconf/%.class
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.util.prefs.gconf.$*
+
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_net_VMPlainDatagramSocketImpl.h: $(top_srcdir)/vm/reference/gnu/java/net/VMPlainDatagramSocketImpl.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.net.VMPlainDatagramSocketImpl
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_net_VMPlainSocketImpl.h: $(top_srcdir)/vm/reference/gnu/java/net/VMPlainSocketImpl.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.net.VMPlainSocketImpl
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_net_local_LocalSocketImpl.h: $(top_srcdir)/gnu/java/net/local/LocalSocketImpl.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.net.local.LocalSocketImpl
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_VMChannel.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMChannel.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.VMChannel
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_VMPipe.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMPipe.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.VMPipe
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_VMSelector.h: $(top_srcdir)/vm/reference/gnu/java/nio/VMSelector.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.VMSelector
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_io_VMFile.h: $(top_srcdir)/vm/reference/java/io/VMFile.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.io.VMFile
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_io_VMObjectInputStream.h: $(top_srcdir)/vm/reference/java/io/VMObjectInputStream.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.io.VMObjectInputStream
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_io_VMObjectStreamClass.h: $(top_srcdir)/vm/reference/java/io/VMObjectStreamClass.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.io.VMObjectStreamClass
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_VMMath.h: $(top_srcdir)/vm/reference/java/lang/VMMath.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.VMMath
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_VMDouble.h: $(top_srcdir)/vm/reference/java/lang/VMDouble.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.VMDouble
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_VMFloat.h: $(top_srcdir)/vm/reference/java/lang/VMFloat.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.VMFloat
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_VMProcess.h: $(top_srcdir)/vm/reference/java/lang/VMProcess.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.VMProcess
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_VMSystem.h: $(top_srcdir)/vm/reference/java/lang/VMSystem.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.VMSystem
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_lang_reflect_VMArray.h: $(top_srcdir)/vm/reference/java/lang/reflect/VMArray.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.lang.reflect.VMArray
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_net_VMInetAddress.h: $(top_srcdir)/vm/reference/java/net/VMInetAddress.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.net.VMInetAddress
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_net_VMNetworkInterface.h: $(top_srcdir)/vm/reference/java/net/VMNetworkInterface.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.net.VMNetworkInterface
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_net_VMURLConnection.h: $(top_srcdir)/vm/reference/java/net/VMURLConnection.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.net.VMURLConnection
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_nio_VMDirectByteBuffer.h: $(top_srcdir)/vm/reference/java/nio/VMDirectByteBuffer.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.nio.VMDirectByteBuffer
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_nio_MappedByteBufferImpl.h: $(top_srcdir)/java/nio/MappedByteBufferImpl.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.nio.MappedByteBufferImpl
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_channels_FileChannelImpl.h: $(top_srcdir)/gnu/java/nio/channels/FileChannelImpl.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.channels.FileChannelImpl
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvDecoder.h: $(top_srcdir)/gnu/java/nio/charset/iconv/IconvDecoder.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.charset.iconv.IconvDecoder
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/gnu_java_nio_charset_iconv_IconvEncoder.h: $(top_srcdir)/gnu/java/nio/charset/iconv/IconvEncoder.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ gnu.java.nio.charset.iconv.IconvEncoder
+ at CREATE_JNI_HEADERS_TRUE@$(top_srcdir)/include/java_util_VMTimeZone.h: $(top_srcdir)/vm/reference/java/util/VMTimeZone.java
+ at CREATE_JNI_HEADERS_TRUE@ $(JAVAH) -o $@ java.util.VMTimeZone
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/config.h.in
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/config.h.in?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/config.h.in (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/config.h.in Thu Nov 8 16:56:19 2007
@@ -0,0 +1,317 @@
+/* include/config.h.in. Generated from configure.ac by autoheader. */
+
+/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */
+#undef BYTEORDER
+
+/* Define to 1 if you want native library runtime debugging code enabled */
+#undef DEBUG
+
+/* Define to enable support for local sockets. */
+#undef ENABLE_LOCAL_SOCKETS
+
+/* Define to 1 if you have the `accept' function. */
+#undef HAVE_ACCEPT
+
+/* Define to 1 if you have the <alsa/asoundlib.h> header file. */
+#undef HAVE_ALSA_ASOUNDLIB_H
+
+/* Define to 1 if you have the <asm/ioctls.h> header file. */
+#undef HAVE_ASM_IOCTLS_H
+
+/* Define to 1 if you have the `bind' function. */
+#undef HAVE_BIND
+
+/* Define to 1 if you have BSD u_int32_t */
+#undef HAVE_BSD_INT32_DEFINED
+
+/* Define to 1 if you have the `close' function. */
+#undef HAVE_CLOSE
+
+/* Define to 1 if you have the `connect' function. */
+#undef HAVE_CONNECT
+
+/* Define to 1 if you have the <crt_externs.h> header file. */
+#undef HAVE_CRT_EXTERNS_H
+
+/* Define to 1 if you have the <dssi.h> header file. */
+#undef HAVE_DSSI_H
+
+/* Define to 1 if you have the `execve' function. */
+#undef HAVE_EXECVE
+
+/* Define to 1 if you have the `fcntl' function. */
+#undef HAVE_FCNTL
+
+/* Define to 1 if you have the <fcntl.h> header file. */
+#undef HAVE_FCNTL_H
+
+/* Define to 1 if you have the `fork' function. */
+#undef HAVE_FORK
+
+/* Define to 1 if you have the `fstat' function. */
+#undef HAVE_FSTAT
+
+/* Define to 1 if you have the `fsync' function. */
+#undef HAVE_FSYNC
+
+/* Define to 1 if you have the `ftruncate' function. */
+#undef HAVE_FTRUNCATE
+
+/* Define to 1 if you have the `gethostname' function. */
+#undef HAVE_GETHOSTNAME
+
+/* Define to 1 if you have the `getpagesize' function. */
+#undef HAVE_GETPAGESIZE
+
+/* Define to 1 if you have the `getpeername' function. */
+#undef HAVE_GETPEERNAME
+
+/* Define to 1 if you have the `getsockname' function. */
+#undef HAVE_GETSOCKNAME
+
+/* Define to 1 if you have the `getsockopt' function. */
+#undef HAVE_GETSOCKOPT
+
+/* Define to 1 if you have the `htonl' function. */
+#undef HAVE_HTONL
+
+/* Define to 1 if you have the `htons' function. */
+#undef HAVE_HTONS
+
+/* Define if you have the iconv() function. */
+#undef HAVE_ICONV
+
+/* Define to 1 if you have uint32_t */
+#undef HAVE_INT32_DEFINED
+
+/* Define to 1 if you have the <inttypes.h> header file. */
+#undef HAVE_INTTYPES_H
+
+/* Define to 1 if you have the `listen' function. */
+#undef HAVE_LISTEN
+
+/* Define to 1 if you have the `localtime_r' function. */
+#undef HAVE_LOCALTIME_R
+
+/* Define to 1 if you have the `lseek' function. */
+#undef HAVE_LSEEK
+
+/* Define to 1 if you have the `lstat' function. */
+#undef HAVE_LSTAT
+
+/* Define to 1 if you have the `madvise' function. */
+#undef HAVE_MADVISE
+
+/* Define to 1 if you have the <magic.h> header file. */
+#undef HAVE_MAGIC_H
+
+/* Define to 1 if you have the <memory.h> header file. */
+#undef HAVE_MEMORY_H
+
+/* Define to 1 if you have the `memset' function. */
+#undef HAVE_MEMSET
+
+/* Define to 1 if you have the `mincore' function. */
+#undef HAVE_MINCORE
+
+/* Define to 1 if you have the `mktime' function. */
+#undef HAVE_MKTIME
+
+/* Define to 1 if you have the `mmap' function. */
+#undef HAVE_MMAP
+
+/* Define to 1 if you have the `msync' function. */
+#undef HAVE_MSYNC
+
+/* Define to 1 if you have the `munmap' function. */
+#undef HAVE_MUNMAP
+
+/* Define to 1 if you have the `open' function. */
+#undef HAVE_OPEN
+
+/* Define to 1 if you have the `pipe' function. */
+#undef HAVE_PIPE
+
+/* Define to 1 if you have the `read' function. */
+#undef HAVE_READ
+
+/* Define to 1 if you have the `readlink' function. */
+#undef HAVE_READLINK
+
+/* Define to 1 if you have the `recvfrom' function. */
+#undef HAVE_RECVFROM
+
+/* Define to 1 if you have the `select' function. */
+#undef HAVE_SELECT
+
+/* Define to 1 if you have the `send' function. */
+#undef HAVE_SEND
+
+/* Define to 1 if you have the `sendto' function. */
+#undef HAVE_SENDTO
+
+/* Define to 1 if you have the `setsockopt' function. */
+#undef HAVE_SETSOCKOPT
+
+/* Define to 1 if you have the `shutdown' function. */
+#undef HAVE_SHUTDOWN
+
+/* Define to 1 if you have the `socket' function. */
+#undef HAVE_SOCKET
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#undef HAVE_STDINT_H
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#undef HAVE_STDLIB_H
+
+/* Define to 1 if you have the `strerror' function. */
+#undef HAVE_STRERROR
+
+/* Define to 1 if you have the `strerror_r' function. */
+#undef HAVE_STRERROR_R
+
+/* Define to 1 if you have the <strings.h> header file. */
+#undef HAVE_STRINGS_H
+
+/* Define to 1 if you have the <string.h> header file. */
+#undef HAVE_STRING_H
+
+/* Define to 1 if `tm_zone' is member of `struct tm'. */
+#undef HAVE_STRUCT_TM_TM_ZONE
+
+/* Define to 1 if you have the `sysconf' function. */
+#undef HAVE_SYSCONF
+
+/* Define to 1 if you have the <sys/config.h> header file. */
+#undef HAVE_SYS_CONFIG_H
+
+/* Define to 1 if you have the <sys/filio.h> header file. */
+#undef HAVE_SYS_FILIO_H
+
+/* Define to 1 if you have the <sys/ioctl.h> header file. */
+#undef HAVE_SYS_IOCTL_H
+
+/* Define to 1 if you have the <sys/mman.h> header file. */
+#undef HAVE_SYS_MMAN_H
+
+/* Define to 1 if you have the <sys/select.h> header file. */
+#undef HAVE_SYS_SELECT_H
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#undef HAVE_SYS_STAT_H
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#undef HAVE_SYS_TIME_H
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#undef HAVE_SYS_TYPES_H
+
+/* Define to 1 if you have the <sys/utime.h> header file. */
+#undef HAVE_SYS_UTIME_H
+
+/* Define to 1 if you have the `time' function. */
+#undef HAVE_TIME
+
+/* Define if global 'timezone' exists. */
+#undef HAVE_TIMEZONE
+
+/* Define to 1 if your `struct tm' has `tm_zone'. Deprecated, use
+ `HAVE_STRUCT_TM_TM_ZONE' instead. */
+#undef HAVE_TM_ZONE
+
+/* Define to 1 if you don't have `tm_zone' but do have the external array
+ `tzname'. */
+#undef HAVE_TZNAME
+
+/* Define if your platform has the global _timezone variable. */
+#undef HAVE_UNDERSCORE_TIMEZONE
+
+/* Define to 1 if you have the <unistd.h> header file. */
+#undef HAVE_UNISTD_H
+
+/* Define to 1 if you have the <utime.h> header file. */
+#undef HAVE_UTIME_H
+
+/* Define to 1 if you have the `write' function. */
+#undef HAVE_WRITE
+
+/* Define to 1 if you have libXrandr. */
+#undef HAVE_XRANDR
+
+/* Define to 1 if you have libXrender. */
+#undef HAVE_XRENDER
+
+/* Define if the host machine stores words of multi-word integers in
+ big-endian order. */
+#undef HOST_WORDS_BIG_ENDIAN
+
+/* Define as const if the declaration of iconv() needs const. */
+#undef ICONV_CONST
+
+/* Name of package */
+#undef PACKAGE
+
+/* Define to the address where bug reports for this package should be sent. */
+#undef PACKAGE_BUGREPORT
+
+/* Define to the full name of this package. */
+#undef PACKAGE_NAME
+
+/* Define to the full name and version of this package. */
+#undef PACKAGE_STRING
+
+/* Define to the one symbol short name of this package. */
+#undef PACKAGE_TARNAME
+
+/* Define to the version of this package. */
+#undef PACKAGE_VERSION
+
+/* Define if you want to synchronize VM threads portably by default; undef
+ otherwise */
+#undef PORTABLE_NATIVE_SYNC
+
+/* The size of a `char', as computed by sizeof. */
+#undef SIZEOF_CHAR
+
+/* The size of a `int', as computed by sizeof. */
+#undef SIZEOF_INT
+
+/* The size of a `long', as computed by sizeof. */
+#undef SIZEOF_LONG
+
+/* The size of a `short', as computed by sizeof. */
+#undef SIZEOF_SHORT
+
+/* The size of a `void*', as computed by sizeof. */
+#undef SIZEOF_VOIDP
+
+/* The number of bytes in type void * */
+#undef SIZEOF_VOID_P
+
+/* Define to 1 if you have the ANSI C header files. */
+#undef STDC_HEADERS
+
+/* Define if struct tm has tm_gmtoff field. */
+#undef STRUCT_TM_HAS_GMTOFF
+
+/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
+#undef TIME_WITH_SYS_TIME
+
+/* Define to 1 if your <sys/time.h> declares `struct tm'. */
+#undef TM_IN_SYS_TIME
+
+/* Version number of package */
+#undef VERSION
+
+/* whether byteorder is bigendian */
+#undef WORDS_BIGENDIAN
+
+/* Define to 1 if the X Window System is missing or not being used. */
+#undef X_DISPLAY_MISSING
+
+/* Define to `__attribute__' to nothing if it's not supported. */
+#undef __attribute__
+
+/* Define to empty if `const' does not conform to ANSI C. */
+#undef const
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoGraphics2D.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,52 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_CairoGraphics2D__
+#define __gnu_java_awt_peer_gtk_CairoGraphics2D__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_init (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_disposeNative (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_drawPixels (JNIEnv *env, jobject, jlong, jintArray, jint, jint, jint, jdoubleArray, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_setGradient (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble, jint, jint, jint, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_setTexturePixels (JNIEnv *env, jobject, jlong, jintArray, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetMatrix (JNIEnv *env, jobject, jlong, jdoubleArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoScale (JNIEnv *env, jobject, jlong, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetOperator (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetRGBAColor (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetFillRule (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetLine (JNIEnv *env, jobject, jlong, jdouble, jint, jint, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSetDash (JNIEnv *env, jobject, jlong, jdoubleArray, jint, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoDrawGlyphVector (JNIEnv *env, jobject, jlong, jobject, jfloat, jfloat, jint, jintArray, jfloatArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoRelCurveTo (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoRectangle (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoArc (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSave (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoRestore (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoNewPath (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoClosePath (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoMoveTo (JNIEnv *env, jobject, jlong, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoRelMoveTo (JNIEnv *env, jobject, jlong, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoLineTo (JNIEnv *env, jobject, jlong, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoRelLineTo (JNIEnv *env, jobject, jlong, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoCurveTo (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoStroke (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoFill (JNIEnv *env, jobject, jlong, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoClip (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoPreserveClip (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoResetClip (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoSurfaceSetFilter (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoDrawLine (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoDrawRect (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoGraphics2D_cairoFillRect (JNIEnv *env, jobject, jlong, jdouble, jdouble, jdouble, jdouble);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_CairoGraphics2D__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoSurface.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoSurface.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoSurface.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_CairoSurface.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,28 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_CairoSurface__
+#define __gnu_java_awt_peer_gtk_CairoSurface__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_create (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_destroy (JNIEnv *env, jobject, jlong, jlong);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeGetElem (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeSetElem (JNIEnv *env, jobject, jlong, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeDrawSurface (JNIEnv *env, jobject, jlong, jlong, jdoubleArray, jdouble);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeGetPixels (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeSetPixels (JNIEnv *env, jobject, jlong, jintArray);
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_getFlippedBuffer (JNIEnv *env, jobject, jlong, jint);
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_nativeNewCairoContext (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_CairoSurface_copyAreaNative2 (JNIEnv *env, jobject, jlong, jint, jint, jint, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_CairoSurface__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphics.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphics.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphics.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphics.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,27 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_ComponentGraphics__
+#define __gnu_java_awt_peer_gtk_ComponentGraphics__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_initState (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_disposeSurface (JNIEnv *env, jobject, jlong);
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_initFromVolatile (JNIEnv *env, jobject, jlong, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_start_1gdk_1drawing (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_end_1gdk_1drawing (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_hasXRender (JNIEnv *env, jclass);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_nativeGrab (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_copyAreaNative (JNIEnv *env, jobject, jobject, jint, jint, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphics_drawVolatile (JNIEnv *env, jobject, jobject, jlong, jint, jint, jint, jint, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_ComponentGraphics__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_ComponentGraphicsCopy.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_ComponentGraphicsCopy__
+#define __gnu_java_awt_peer_gtk_ComponentGraphicsCopy__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphicsCopy_getPixbuf (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_ComponentGraphicsCopy_copyPixbuf (JNIEnv *env, jobject, jobject, jobject, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_ComponentGraphicsCopy__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_FreetypeGlyphVector.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_FreetypeGlyphVector__
+#define __gnu_java_awt_peer_gtk_FreetypeGlyphVector__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_FreetypeGlyphVector_getGlyphs (JNIEnv *env, jobject, jintArray);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_FreetypeGlyphVector_getKerning (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT jdoubleArray JNICALL Java_gnu_java_awt_peer_gtk_FreetypeGlyphVector_getMetricsNative (JNIEnv *env, jobject, jint);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_FreetypeGlyphVector_getGlyphOutlineNative (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_FreetypeGlyphVector__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GThreadNativeMethodRunner.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GThreadNativeMethodRunner__
+#define __gnu_java_awt_peer_gtk_GThreadNativeMethodRunner__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GThreadNativeMethodRunner_nativeRun (JNIEnv *env, jobject, jlong, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GThreadNativeMethodRunner__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkFontPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkFontPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkFontPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkFontPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GdkFontPeer__
+#define __gnu_java_awt_peer_gtk_GdkFontPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_initStaticState (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_initState (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_dispose (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_setFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_getFontMetrics (JNIEnv *env, jobject, jdoubleArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_getTextMetrics (JNIEnv *env, jobject, jstring, jdoubleArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_releasePeerGraphicsResource (JNIEnv *env, jobject);
+JNIEXPORT jbyteArray JNICALL Java_gnu_java_awt_peer_gtk_GdkFontPeer_getTrueTypeTable (JNIEnv *env, jobject, jbyte, jbyte, jbyte, jbyte);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GdkFontPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkGraphicsEnvironment.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GdkGraphicsEnvironment__
+#define __gnu_java_awt_peer_gtk_GdkGraphicsEnvironment__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_initStaticState (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_nativeInitState (JNIEnv *env, jobject);
+JNIEXPORT jobjectArray JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_nativeGetScreenDevices (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_nativeGetDefaultScreenDevice (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_nativeGetNumFontFamilies (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_nativeGetFontFamilies (JNIEnv *env, jobject, jobjectArray);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GdkGraphicsEnvironment_getMouseCoordinates (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GdkGraphicsEnvironment__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkPixbufDecoder.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GdkPixbufDecoder__
+#define __gnu_java_awt_peer_gtk_GdkPixbufDecoder__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_initStaticState (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_initState (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_pumpBytes (JNIEnv *env, jobject, jbyteArray, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_pumpDone (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_finish (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkPixbufDecoder_streamImage (JNIEnv *env, jclass, jintArray, jstring, jint, jint, jboolean, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GdkPixbufDecoder__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkRobotPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GdkRobotPeer__
+#define __gnu_java_awt_peer_gtk_GdkRobotPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_initXTest (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_mouseMove (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_mousePress (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_mouseRelease (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_mouseWheel (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_keyPress (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_keyRelease (JNIEnv *env, jobject, jint);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GdkRobotPeer_nativeGetRGBPixels (JNIEnv *env, jobject, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GdkRobotPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice__
+#define __gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_initStaticState (JNIEnv *env, jclass);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetFixedDisplayMode (JNIEnv *env, jobject, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetIDString (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetDisplayModeIndex (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetDisplayModeRate (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobjectArray JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetDisplayModes (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeSetDisplayMode (JNIEnv *env, jobject, jobject, jint, jshort);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice_nativeGetBounds (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GdkScreenGraphicsDevice__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkButtonPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,28 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkButtonPeer__
+#define __gnu_java_awt_peer_gtk_GtkButtonPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_create (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkSetLabel (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkWidgetSetForeground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkWidgetSetBackground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkActivate (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkWidgetRequestFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_setNativeBounds (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkButtonPeer_gtkWidgetGetPreferredDimensions (JNIEnv *env, jobject, jintArray);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkButtonPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCanvasPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkCanvasPeer__
+#define __gnu_java_awt_peer_gtk_GtkCanvasPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCanvasPeer_create (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkCanvasPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer__
+#define __gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer_create (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer_setState (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkCheckboxMenuItemPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkCheckboxPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,27 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkCheckboxPeer__
+#define __gnu_java_awt_peer_gtk_GtkCheckboxPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_createCheckButton (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_createRadioButton (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_addToGroup (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_removeFromGroup (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_switchToGroup (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_gtkButtonSetLabel (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkCheckboxPeer_gtkToggleButtonSetActive (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkCheckboxPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkChoicePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkChoicePeer__
+#define __gnu_java_awt_peer_gtk_GtkChoicePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_create (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_nativeGetSelected (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_add (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_nativeRemove (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_nativeRemoveAll (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_selectNative (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkChoicePeer_selectNativeUnlocked (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkChoicePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkClipboard.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkClipboard.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkClipboard.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkClipboard.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkClipboard__
+#define __gnu_java_awt_peer_gtk_GtkClipboard__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkClipboard_advertiseContent (JNIEnv *env, jobject, jobjectArray, jboolean, jboolean, jboolean);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkClipboard_initNativeState (JNIEnv *env, jclass, jobject, jobject, jstring, jstring, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkClipboard__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkComponentPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,42 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkComponentPeer__
+#define __gnu_java_awt_peer_gtk_GtkComponentPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_isEnabled (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_modalHasGrab (JNIEnv *env, jclass);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetGetForeground (JNIEnv *env, jobject);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetGetBackground (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetGetDimensions (JNIEnv *env, jobject, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetGetPreferredDimensions (JNIEnv *env, jobject, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWindowGetLocationOnScreen (JNIEnv *env, jobject, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetGetLocationOnScreen (JNIEnv *env, jobject, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetCursor (JNIEnv *env, jobject, jint, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetCursorUnlocked (JNIEnv *env, jobject, jint, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetBackground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetForeground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetSensitive (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetSetParent (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetRequestFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetDispatchKeyEvent (JNIEnv *env, jobject, jint, jlong, jint, jint, jint);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetHasFocus (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_gtkWidgetCanFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_realize (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_setNativeEventMask (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_setNativeBounds (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_setVisibleNative (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkComponentPeer_setVisibleNativeUnlocked (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkComponentPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer__
+#define __gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer_create (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer_construct (JNIEnv *env, jobject, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkEmbeddedWindowPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFileDialogPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkFileDialogPeer__
+#define __gnu_java_awt_peer_gtk_GtkFileDialogPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_create (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_nativeSetFile (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_nativeGetDirectory (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_nativeSetDirectory (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFileDialogPeer_nativeSetFilenameFilter (JNIEnv *env, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkFileDialogPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFramePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFramePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFramePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkFramePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkFramePeer__
+#define __gnu_java_awt_peer_gtk_GtkFramePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_getMenuBarHeight (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_setMenuBarWidthUnlocked (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_setMenuBarWidth (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_setMenuBarPeer (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_removeMenuBarPeer (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_gtkFixedSetVisible (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkFramePeer_nativeSetIconImage (JNIEnv *env, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkFramePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkGenericPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkGenericPeer__
+#define __gnu_java_awt_peer_gtk_GtkGenericPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkGenericPeer_dispose (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkGenericPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkGenericPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkImage.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkImage.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkImage.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkImage.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,27 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkImage__
+#define __gnu_java_awt_peer_gtk_GtkImage__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_initFromBuffer (JNIEnv *env, jobject, jlong);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_getPixels (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_setPixels (JNIEnv *env, jobject, jintArray);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_loadPixbuf (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_loadImageFromData (JNIEnv *env, jobject, jbyteArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_createPixbuf (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_freePixbuf (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_createScaledPixbuf (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkImage_createFromPixbuf (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkImage__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkLabelPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkLabelPeer__
+#define __gnu_java_awt_peer_gtk_GtkLabelPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_create (JNIEnv *env, jobject, jstring, jfloat);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_nativeSetAlignment (JNIEnv *env, jobject, jfloat);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_setNativeText (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_setNativeBounds (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkLabelPeer_gtkWidgetGetPreferredDimensions (JNIEnv *env, jobject, jintArray);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkLabelPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkListPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkListPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkListPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkListPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,31 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkListPeer__
+#define __gnu_java_awt_peer_gtk_GtkListPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_create (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_gtkWidgetRequestFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_getSize (JNIEnv *env, jobject, jint, jint, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_append (JNIEnv *env, jobject, jobjectArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_add (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_delItems (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_deselect (JNIEnv *env, jobject, jint);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_getSelectedIndexes (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_makeVisible (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_select (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkListPeer_setMultipleMode (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkListPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuBarPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkMenuBarPeer__
+#define __gnu_java_awt_peer_gtk_GtkMenuBarPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuBarPeer_create (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuBarPeer_addMenu (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuBarPeer_delMenu (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkMenuBarPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuComponentPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkMenuComponentPeer__
+#define __gnu_java_awt_peer_gtk_GtkMenuComponentPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuComponentPeer_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkMenuComponentPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuItemPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkMenuItemPeer__
+#define __gnu_java_awt_peer_gtk_GtkMenuItemPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuItemPeer_create (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuItemPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuItemPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuItemPeer_setEnabled (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuItemPeer_setLabel (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkMenuItemPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkMenuPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkMenuPeer__
+#define __gnu_java_awt_peer_gtk_GtkMenuPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuPeer_create (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuPeer_addItem (JNIEnv *env, jobject, jobject, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuPeer_setupAccelGroup (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuPeer_addTearOff (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkMenuPeer_delItem (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkMenuPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPanelPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkPanelPeer__
+#define __gnu_java_awt_peer_gtk_GtkPanelPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkPanelPeer_create (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkPanelPeer_connectSignals (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkPanelPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkPopupMenuPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkPopupMenuPeer__
+#define __gnu_java_awt_peer_gtk_GtkPopupMenuPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkPopupMenuPeer_setupAccelGroup (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkPopupMenuPeer_show (JNIEnv *env, jobject, jint, jint, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkPopupMenuPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollPanePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkScrollPanePeer__
+#define __gnu_java_awt_peer_gtk_GtkScrollPanePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_create (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_gtkScrolledWindowSetHScrollIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_gtkScrolledWindowSetVScrollIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_setPolicy (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_getHScrollbarHeight (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_getVScrollbarWidth (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollPanePeer_setScrollPosition (JNIEnv *env, jobject, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkScrollPanePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkScrollbarPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkScrollbarPeer__
+#define __gnu_java_awt_peer_gtk_GtkScrollbarPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollbarPeer_create (JNIEnv *env, jobject, jint, jint, jint, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollbarPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollbarPeer_setLineIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollbarPeer_setPageIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkScrollbarPeer_setBarValues (JNIEnv *env, jobject, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkScrollbarPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkSelection.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkSelection.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkSelection.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkSelection.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkSelection__
+#define __gnu_java_awt_peer_gtk_GtkSelection__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkSelection_requestText (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkSelection_requestImage (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkSelection_requestURIs (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkSelection_requestBytes (JNIEnv *env, jobject, jboolean, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkSelection_requestMimeTypes (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkSelection__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextAreaPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,34 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkTextAreaPeer__
+#define __gnu_java_awt_peer_gtk_GtkTextAreaPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_create (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_gtkWidgetModifyFont (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_gtkWidgetRequestFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getCaretPosition (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_setCaretPosition (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getSelectionStart (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getSelectionEnd (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getText (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_select (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_setEditable (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_setText (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_insert (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_replaceRange (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getHScrollbarHeight (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextAreaPeer_getVScrollbarWidth (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkTextAreaPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkTextFieldPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,32 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkTextFieldPeer__
+#define __gnu_java_awt_peer_gtk_GtkTextFieldPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_create (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_gtkWidgetSetBackground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_gtkWidgetSetForeground (JNIEnv *env, jobject, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_getCaretPosition (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_setCaretPosition (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_getSelectionStart (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_getSelectionEnd (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_getText (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_select (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_setEditable (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_setText (JNIEnv *env, jobject, jstring);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_gtkEntryGetBorderWidth (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkTextFieldPeer_setEchoChar (JNIEnv *env, jobject, jchar);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkTextFieldPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkToolkit.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkToolkit.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkToolkit.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkToolkit.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkToolkit__
+#define __gnu_java_awt_peer_gtk_GtkToolkit__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_gtkInit (JNIEnv *env, jclass, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_beep (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_getScreenSizeDimensions (JNIEnv *env, jobject, jintArray);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_getScreenResolution (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_sync (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_loadSystemColors (JNIEnv *env, jobject, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_gtkMain (JNIEnv *env, jclass);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_gtk_GtkToolkit_getMouseNumberOfButtons (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkToolkit__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkVolatileImage.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkVolatileImage__
+#define __gnu_java_awt_peer_gtk_GtkVolatileImage__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_gtk_GtkVolatileImage_init (JNIEnv *env, jobject, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkVolatileImage_destroy (JNIEnv *env, jobject, jlong);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_gtk_GtkVolatileImage_nativeGetPixels (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkVolatileImage_nativeCopyArea (JNIEnv *env, jobject, jlong, jint, jint, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkVolatileImage_nativeDrawVolatile (JNIEnv *env, jobject, jlong, jlong, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkVolatileImage__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_gtk_GtkWindowPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,51 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_gtk_GtkWindowPeer__
+#define __gnu_java_awt_peer_gtk_GtkWindowPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_gtkWindowSetTitle (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_gtkWindowSetResizable (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_gtkWindowSetModal (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_gtkWindowSetAlwaysOnTop (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_gtkWindowHasFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_realize (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_create (JNIEnv *env, jobject, jint, jboolean, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_setVisibleNative (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_setVisibleNativeUnlocked (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_connectSignals (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_toBack (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_toFront (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_nativeSetBounds (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_nativeSetBoundsUnlocked (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_nativeSetLocation (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_nativeSetLocationUnlocked (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_gtk_GtkWindowPeer_setSize (JNIEnv *env, jobject, jint, jint);
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_NORMAL
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_NORMAL 0L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DIALOG
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DIALOG 1L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_MENU
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_MENU 2L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_TOOLBAR
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_TOOLBAR 3L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_SPLASHSCREEN
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_SPLASHSCREEN 4L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_UTILITY
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_UTILITY 5L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DOCK
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DOCK 6L
+#undef gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DESKTOP
+#define gnu_java_awt_peer_gtk_GtkWindowPeer_GDK_WINDOW_TYPE_HINT_DESKTOP 7L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_gtk_GtkWindowPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_MainQtThread.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_MainQtThread.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_MainQtThread.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_MainQtThread.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_MainQtThread__
+#define __gnu_java_awt_peer_qt_MainQtThread__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_java_awt_peer_qt_MainQtThread_init (JNIEnv *env, jobject, jstring, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_MainQtThread_exec (JNIEnv *env, jobject, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_MainQtThread__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QMatrix.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QMatrix.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QMatrix.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QMatrix.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QMatrix__
+#define __gnu_java_awt_peer_qt_QMatrix__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QMatrix_init (JNIEnv *env, jobject, jdouble, jdouble, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT jdoubleArray JNICALL Java_gnu_java_awt_peer_qt_QMatrix_getMatrix (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QMatrix_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QMatrix__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPainterPath.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPainterPath.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPainterPath.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPainterPath.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QPainterPath__
+#define __gnu_java_awt_peer_qt_QPainterPath__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_getPath (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_init (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_moveTo (JNIEnv *env, jobject, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_close (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_lineTo (JNIEnv *env, jobject, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_quadTo (JNIEnv *env, jobject, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_cubicTo (JNIEnv *env, jobject, jdouble, jdouble, jdouble, jdouble, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPainterPath_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QPainterPath__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPen.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPen.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPen.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QPen.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QPen__
+#define __gnu_java_awt_peer_qt_QPen__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPen_init (JNIEnv *env, jobject, jdouble, jint, jint, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QPen_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QPen__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtAudioClip.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtAudioClip.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtAudioClip.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtAudioClip.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtAudioClip__
+#define __gnu_java_awt_peer_qt_QtAudioClip__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtAudioClip_loadClip (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtAudioClip_play (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtAudioClip_isAvailable (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtAudioClip_stop (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtAudioClip_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtAudioClip__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtButtonPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtButtonPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtButtonPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtButtonPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtButtonPeer__
+#define __gnu_java_awt_peer_qt_QtButtonPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtButtonPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtButtonPeer_setLabel (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtButtonPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCanvasPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCanvasPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCanvasPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCanvasPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtCanvasPeer__
+#define __gnu_java_awt_peer_qt_QtCanvasPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtCanvasPeer_init (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtCanvasPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtCheckboxPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtCheckboxPeer__
+#define __gnu_java_awt_peer_qt_QtCheckboxPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtCheckboxPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtCheckboxPeer_setLabel (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtCheckboxPeer_setState (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtCheckboxPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtChoicePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtChoicePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtChoicePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtChoicePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtChoicePeer__
+#define __gnu_java_awt_peer_qt_QtChoicePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtChoicePeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtChoicePeer_add (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtChoicePeer_remove (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtChoicePeer_select (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtChoicePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtComponentPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtComponentPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtComponentPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtComponentPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,40 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtComponentPeer__
+#define __gnu_java_awt_peer_qt_QtComponentPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_callInit (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_QtUpdate (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_QtUpdateArea (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_disposeNative (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setGround (JNIEnv *env, jobject, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setBoundsNative (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setCursor (JNIEnv *env, jobject, jint);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_getNativeBackground (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setFontNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_whichScreen (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_reparentNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_getLocationOnScreenNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_getSizeNative (JNIEnv *env, jobject, jobject, jboolean);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_handlesWheelScrolling (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_isFocusable (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_isObscured (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_requestFocus (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setEnabled (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_setVisible (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtComponentPeer_getBounds (JNIEnv *env, jobject);
+#undef gnu_java_awt_peer_qt_QtComponentPeer_POPUP_TRIGGER
+#define gnu_java_awt_peer_qt_QtComponentPeer_POPUP_TRIGGER 3L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtComponentPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtContainerPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtContainerPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtContainerPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtContainerPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,18 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtContainerPeer__
+#define __gnu_java_awt_peer_qt_QtContainerPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtContainerPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtDialogPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtDialogPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtDialogPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtDialogPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtDialogPeer__
+#define __gnu_java_awt_peer_qt_QtDialogPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtDialogPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtDialogPeer_setModal (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtDialogPeer_setBoundsNative (JNIEnv *env, jobject, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtDialogPeer_setResizable (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtDialogPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtEmbeddedWindowPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtEmbeddedWindowPeer__
+#define __gnu_java_awt_peer_qt_QtEmbeddedWindowPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtEmbeddedWindowPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtEmbeddedWindowPeer_embed (JNIEnv *env, jobject, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtEmbeddedWindowPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFileDialogPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtFileDialogPeer__
+#define __gnu_java_awt_peer_qt_QtFileDialogPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFileDialogPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFileDialogPeer_setMode (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtFileDialogPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontMetrics.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontMetrics.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontMetrics.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontMetrics.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,30 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtFontMetrics__
+#define __gnu_java_awt_peer_qt_QtFontMetrics__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_init (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_initGraphics (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_dispose (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getStringBounds (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_canDisplay (JNIEnv *env, jobject, jchar);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getAscent (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getDescent (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getHeight (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getLeading (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_getMaxAdvance (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_charWidth (JNIEnv *env, jobject, jchar);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFontMetrics_stringWidth (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtFontMetrics__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFontPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtFontPeer__
+#define __gnu_java_awt_peer_qt_QtFontPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFontPeer_create (JNIEnv *env, jobject, jstring, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFontPeer_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtFontPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFramePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFramePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFramePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtFramePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtFramePeer__
+#define __gnu_java_awt_peer_qt_QtFramePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFramePeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFramePeer_setIcon (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFramePeer_setMaximizedBounds (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtFramePeer_setMenu (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtFramePeer_menuBarHeight (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtFramePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphics.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphics.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphics.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphics.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,40 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtGraphics__
+#define __gnu_java_awt_peer_qt_QtGraphics__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_delete (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_initImage (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_initVolatileImage (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_cloneNativeContext (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setColor (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_drawNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_fillNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setClipNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setClipRectNative (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_intersectClipNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_intersectClipRectNative (JNIEnv *env, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setQtTransform (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setNativeStroke (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setNativeComposite (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_drawStringNative (JNIEnv *env, jobject, jstring, jdouble, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setLinearGradient (JNIEnv *env, jobject, jint, jint, jint, jint, jint, jint, jdouble, jdouble, jdouble, jdouble, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setAlphaNative (JNIEnv *env, jobject, jdouble);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_setFontNative (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_getClipNative (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_getClipBounds (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_fill3DRect (JNIEnv *env, jobject, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtGraphics_draw3DRect (JNIEnv *env, jobject, jint, jint, jint, jint, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtGraphics__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtGraphicsEnvironment.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,18 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtGraphicsEnvironment__
+#define __gnu_java_awt_peer_qt_QtGraphicsEnvironment__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtGraphicsEnvironment__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtImage.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtImage.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtImage.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtImage.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,31 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtImage__
+#define __gnu_java_awt_peer_qt_QtImage__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_clear (JNIEnv *env, jobject);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_qt_QtImage_getPixels (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_setPixels (JNIEnv *env, jobject, jintArray);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtImage_loadImage (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_java_awt_peer_qt_QtImage_loadImageFromData (JNIEnv *env, jobject, jbyteArray);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_createImage (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_freeImage (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_createScaledImage (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_drawPixels (JNIEnv *env, jobject, jobject, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_drawPixelsScaled (JNIEnv *env, jobject, jobject, jint, jint, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_drawPixelsTransformed (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_drawPixelsScaledFlipped (JNIEnv *env, jobject, jobject, jint, jint, jint, jboolean, jboolean, jint, jint, jint, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtImage_copyArea (JNIEnv *env, jobject, jint, jint, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtImage__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtLabelPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtLabelPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtLabelPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtLabelPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtLabelPeer__
+#define __gnu_java_awt_peer_qt_QtLabelPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtLabelPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtLabelPeer_setAlignment (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtLabelPeer_setText (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtLabelPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtListPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtListPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtListPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtListPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtListPeer__
+#define __gnu_java_awt_peer_qt_QtListPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_select (JNIEnv *env, jobject, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_add (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_delItems (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_getSelectedIndexes (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_makeVisible (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtListPeer_setMultipleMode (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtListPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuBarPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtMenuBarPeer__
+#define __gnu_java_awt_peer_qt_QtMenuBarPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuBarPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuBarPeer_addMenu (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuBarPeer_addHelpMenu (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuBarPeer_delMenu (JNIEnv *env, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtMenuBarPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuComponentPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtMenuComponentPeer__
+#define __gnu_java_awt_peer_qt_QtMenuComponentPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuComponentPeer_callInit (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuComponentPeer_dispose (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtMenuComponentPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuItemPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtMenuItemPeer__
+#define __gnu_java_awt_peer_qt_QtMenuItemPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuItemPeer_create (JNIEnv *env, jobject, jstring, jboolean, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuItemPeer_dispose (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuItemPeer_setEnabled (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuItemPeer_setLabel (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuItemPeer_setState (JNIEnv *env, jobject, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtMenuItemPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtMenuPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtMenuPeer__
+#define __gnu_java_awt_peer_qt_QtMenuPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_allowTearOff (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_insertSeperator (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_insertItem (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_insertMenu (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_delItem (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_setEnabled (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtMenuPeer_setLabel (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtMenuPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPanelPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPanelPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPanelPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPanelPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtPanelPeer__
+#define __gnu_java_awt_peer_qt_QtPanelPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtPanelPeer_init (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtPanelPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtPopupMenuPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtPopupMenuPeer__
+#define __gnu_java_awt_peer_qt_QtPopupMenuPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtPopupMenuPeer_showNative (JNIEnv *env, jobject, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtPopupMenuPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScreenDevice.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScreenDevice.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScreenDevice.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScreenDevice.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtScreenDevice__
+#define __gnu_java_awt_peer_qt_QtScreenDevice__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_init (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_dispose (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_getBounds (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_getDpiX (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_getDpiY (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtScreenDevice_depth (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtScreenDevice__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollPanePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtScrollPanePeer__
+#define __gnu_java_awt_peer_qt_QtScrollPanePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_setPolicy (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_childResized (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_getHScrollbarHeight (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_getVScrollbarWidth (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollPanePeer_setScrollPosition (JNIEnv *env, jobject, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtScrollPanePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtScrollbarPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,23 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtScrollbarPeer__
+#define __gnu_java_awt_peer_qt_QtScrollbarPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollbarPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollbarPeer_setOrientation (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollbarPeer_setLineIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollbarPeer_setPageIncrement (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtScrollbarPeer_setValues (JNIEnv *env, jobject, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtScrollbarPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextAreaPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,27 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtTextAreaPeer__
+#define __gnu_java_awt_peer_qt_QtTextAreaPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_init (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_getSelection (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_getCaretPosition (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_getIndexAtPoint (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_getText (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_setText (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_select (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_setEditable (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextAreaPeer_setCaretPosition (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtTextAreaPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtTextFieldPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,29 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtTextFieldPeer__
+#define __gnu_java_awt_peer_qt_QtTextFieldPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_init (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_getSelection (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_getMinimumSizeNative (JNIEnv *env, jobject, jint);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_getPreferredSizeNative (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_getCaretPosition (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_getText (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_select (JNIEnv *env, jobject, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_setCaretPosition (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_setEchoChar (JNIEnv *env, jobject, jchar);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_setEditable (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtTextFieldPeer_setText (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtTextFieldPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtToolkit.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtToolkit.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtToolkit.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtToolkit.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtToolkit__
+#define __gnu_java_awt_peer_qt_QtToolkit__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobjectArray JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_nativeFontFamilies (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_numScreens (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_defaultScreen (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_beep (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_getScreenSize (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_getScreenResolution (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtToolkit_sync (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtToolkit__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtVolatileImage.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtVolatileImage.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtVolatileImage.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtVolatileImage.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,30 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtVolatileImage__
+#define __gnu_java_awt_peer_qt_QtVolatileImage__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_clear (JNIEnv *env, jobject);
+JNIEXPORT jintArray JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_getPixels (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_createImage (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_freeImage (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_blit__Lgnu_java_awt_peer_qt_QtImage_2 (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_blit__Lgnu_java_awt_peer_qt_QtImage_2IIII (JNIEnv *env, jobject, jobject, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_createScaledImage (JNIEnv *env, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_drawPixels (JNIEnv *env, jobject, jobject, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_drawPixelsScaled (JNIEnv *env, jobject, jobject, jint, jint, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_drawPixelsTransformed (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_drawPixelsScaledFlipped (JNIEnv *env, jobject, jobject, jint, jint, jint, jboolean, jboolean, jint, jint, jint, jint, jint, jint, jint, jint, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtVolatileImage_copyArea (JNIEnv *env, jobject, jint, jint, jint, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtVolatileImage__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtWindowPeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtWindowPeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtWindowPeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_awt_peer_qt_QtWindowPeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_awt_peer_qt_QtWindowPeer__
+#define __gnu_java_awt_peer_qt_QtWindowPeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtWindowPeer_init (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtWindowPeer_toBack (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtWindowPeer_toFront (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_awt_peer_qt_QtWindowPeer_setTitle (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_awt_peer_qt_QtWindowPeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainDatagramSocketImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainDatagramSocketImpl.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainDatagramSocketImpl.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainDatagramSocketImpl.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,30 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_net_VMPlainDatagramSocketImpl__
+#define __gnu_java_net_VMPlainDatagramSocketImpl__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_bind (JNIEnv *env, jclass, jobject, jint, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_create (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_connect (JNIEnv *env, jclass, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_nativeSendTo (JNIEnv *env, jclass, jobject, jobject, jint, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_nativeReceive (JNIEnv *env, jclass, jobject, jbyteArray, jint, jint, jbyteArray, jintArray, jintArray);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_setOption (JNIEnv *env, jclass, jobject, jint, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_getOption (JNIEnv *env, jclass, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_close (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_join (JNIEnv *env, jclass, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainDatagramSocketImpl_leave (JNIEnv *env, jclass, jobject, jobject);
+#undef gnu_java_net_VMPlainDatagramSocketImpl_IP_TTL
+#define gnu_java_net_VMPlainDatagramSocketImpl_IP_TTL 7777L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_net_VMPlainDatagramSocketImpl__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainSocketImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainSocketImpl.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainSocketImpl.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_VMPlainSocketImpl.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,31 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_net_VMPlainSocketImpl__
+#define __gnu_java_net_VMPlainSocketImpl__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_setOption (JNIEnv *env, jclass, jobject, jint, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_java_net_VMPlainSocketImpl_getOption (JNIEnv *env, jclass, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_create (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_connect (JNIEnv *env, jclass, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_bind (JNIEnv *env, jclass, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_listen (JNIEnv *env, jclass, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_accept (JNIEnv *env, jclass, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_net_VMPlainSocketImpl_available (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_close (JNIEnv *env, jclass, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_net_VMPlainSocketImpl_read (JNIEnv *env, jclass, jobject, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_write (JNIEnv *env, jclass, jobject, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_shutdownInput (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_VMPlainSocketImpl_shutdownOutput (JNIEnv *env, jclass, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_net_VMPlainSocketImpl__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_local_LocalSocketImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_local_LocalSocketImpl.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_local_LocalSocketImpl.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_net_local_LocalSocketImpl.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,31 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_net_local_LocalSocketImpl__
+#define __gnu_java_net_local_LocalSocketImpl__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_create (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_listen (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_accept (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_net_local_LocalSocketImpl_available (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_close (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_sendUrgentData (JNIEnv *env, jobject, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_shutdownInput (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_shutdownOutput (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_unlink (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_localBind (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_localConnect (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_net_local_LocalSocketImpl_read (JNIEnv *env, jobject, jint, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_net_local_LocalSocketImpl_write (JNIEnv *env, jobject, jint, jbyteArray, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_net_local_LocalSocketImpl__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMChannel.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMChannel.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMChannel.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMChannel.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_VMChannel__
+#define __gnu_java_nio_VMChannel__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_nio_VMChannel_setBlocking (JNIEnv *env, jobject, jint, jboolean);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_VMChannel_read (JNIEnv *env, jobject, jint, jobject);
+JNIEXPORT jlong JNICALL Java_gnu_java_nio_VMChannel_readScattering (JNIEnv *env, jobject, jint, jobjectArray, jint, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_VMChannel_write (JNIEnv *env, jobject, jint, jobject);
+JNIEXPORT jlong JNICALL Java_gnu_java_nio_VMChannel_writeGathering (JNIEnv *env, jobject, jint, jobjectArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_VMChannel_initIDs (JNIEnv *env, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_VMChannel__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMPipe.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMPipe.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMPipe.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMPipe.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_VMPipe__
+#define __gnu_java_nio_VMPipe__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_nio_VMPipe_init (JNIEnv *env, jclass, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_VMPipe__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMSelector.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMSelector.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMSelector.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_VMSelector.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_VMSelector__
+#define __gnu_java_nio_VMSelector__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jint JNICALL Java_gnu_java_nio_VMSelector_select (JNIEnv *env, jclass, jintArray, jintArray, jintArray, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_VMSelector__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_channels_FileChannelImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_channels_FileChannelImpl.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_channels_FileChannelImpl.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_channels_FileChannelImpl.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,46 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_channels_FileChannelImpl__
+#define __gnu_java_nio_channels_FileChannelImpl__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_init (JNIEnv *env, jclass);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_channels_FileChannelImpl_open (JNIEnv *env, jobject, jstring, jint);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_channels_FileChannelImpl_available (JNIEnv *env, jobject);
+JNIEXPORT jlong JNICALL Java_gnu_java_nio_channels_FileChannelImpl_implPosition (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_seek (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_implTruncate (JNIEnv *env, jobject, jlong);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_unlock (JNIEnv *env, jobject, jlong, jlong);
+JNIEXPORT jlong JNICALL Java_gnu_java_nio_channels_FileChannelImpl_size (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_implCloseChannel (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_channels_FileChannelImpl_read__ (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_channels_FileChannelImpl_read___3BII (JNIEnv *env, jobject, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_write___3BII (JNIEnv *env, jobject, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_write__I (JNIEnv *env, jobject, jint);
+JNIEXPORT jobject JNICALL Java_gnu_java_nio_channels_FileChannelImpl_mapImpl (JNIEnv *env, jobject, jchar, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_channels_FileChannelImpl_force (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_java_nio_channels_FileChannelImpl_lock (JNIEnv *env, jobject, jlong, jlong, jboolean, jboolean);
+#undef gnu_java_nio_channels_FileChannelImpl_READ
+#define gnu_java_nio_channels_FileChannelImpl_READ 1L
+#undef gnu_java_nio_channels_FileChannelImpl_WRITE
+#define gnu_java_nio_channels_FileChannelImpl_WRITE 2L
+#undef gnu_java_nio_channels_FileChannelImpl_APPEND
+#define gnu_java_nio_channels_FileChannelImpl_APPEND 4L
+#undef gnu_java_nio_channels_FileChannelImpl_EXCL
+#define gnu_java_nio_channels_FileChannelImpl_EXCL 8L
+#undef gnu_java_nio_channels_FileChannelImpl_SYNC
+#define gnu_java_nio_channels_FileChannelImpl_SYNC 16L
+#undef gnu_java_nio_channels_FileChannelImpl_DSYNC
+#define gnu_java_nio_channels_FileChannelImpl_DSYNC 32L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_channels_FileChannelImpl__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvDecoder.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvDecoder.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvDecoder.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvDecoder.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_charset_iconv_IconvDecoder__
+#define __gnu_java_nio_charset_iconv_IconvDecoder__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_nio_charset_iconv_IconvDecoder_openIconv (JNIEnv *env, jobject, jstring);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_charset_iconv_IconvDecoder_decode (JNIEnv *env, jobject, jbyteArray, jcharArray, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_charset_iconv_IconvDecoder_closeIconv (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_charset_iconv_IconvDecoder__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvEncoder.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvEncoder.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvEncoder.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_nio_charset_iconv_IconvEncoder.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_nio_charset_iconv_IconvEncoder__
+#define __gnu_java_nio_charset_iconv_IconvEncoder__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_nio_charset_iconv_IconvEncoder_openIconv (JNIEnv *env, jobject, jstring);
+JNIEXPORT jint JNICALL Java_gnu_java_nio_charset_iconv_IconvEncoder_encode (JNIEnv *env, jobject, jcharArray, jbyteArray, jint, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_java_nio_charset_iconv_IconvEncoder_closeIconv (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_nio_charset_iconv_IconvEncoder__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_util_prefs_gconf_GConfNativePeer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_util_prefs_gconf_GConfNativePeer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_util_prefs_gconf_GConfNativePeer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_java_util_prefs_gconf_GConfNativePeer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,30 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_java_util_prefs_gconf_GConfNativePeer__
+#define __gnu_java_util_prefs_gconf_GConfNativePeer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_init_1id_1cache (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_init_1class (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_finalize_1class (JNIEnv *env, jclass);
+JNIEXPORT jboolean JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1dir_1exists (JNIEnv *env, jclass, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1add_1dir (JNIEnv *env, jclass, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1remove_1dir (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1set_1string (JNIEnv *env, jclass, jstring, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1get_1string (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1unset (JNIEnv *env, jclass, jstring);
+JNIEXPORT void JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1suggest_1sync (JNIEnv *env, jclass);
+JNIEXPORT jobject JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1gconf_1client_1all_1nodes (JNIEnv *env, jclass, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_java_util_prefs_gconf_GConfNativePeer_gconf_1client_1gconf_1client_1all_1keys (JNIEnv *env, jclass, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_java_util_prefs_gconf_GConfNativePeer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider__
+#define __gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobjectArray JNICALL Java_gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider_getInputDeviceInfo_1 (JNIEnv *env, jclass);
+JNIEXPORT jobjectArray JNICALL Java_gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider_getOutputDeviceInfo_1 (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider_init_1 (JNIEnv *env, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_javax_sound_midi_alsa_AlsaMidiDeviceProvider__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice__
+#define __gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice_open_1 (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice_close_1 (JNIEnv *env, jobject, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_javax_sound_midi_alsa_AlsaMidiSequencerDevice__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_alsa_AlsaPortDevice.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_javax_sound_midi_alsa_AlsaPortDevice__
+#define __gnu_javax_sound_midi_alsa_AlsaPortDevice__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1 (JNIEnv *env, jobject, jlong, jlong, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_javax_sound_midi_alsa_AlsaPortDevice__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,25 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider__
+#define __gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_dlopen_1 (JNIEnv *env, jclass, jstring);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_dlclose_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT jlong JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_getDSSIHandle_1 (JNIEnv *env, jclass, jlong, jlong);
+JNIEXPORT jstring JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_getDSSIName_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT jstring JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_getDSSICopyright_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT jstring JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_getDSSIVendor_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT jstring JNICALL Java_gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider_getDSSILabel_1 (JNIEnv *env, jclass, jlong);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_javax_sound_midi_dssi_DSSIMidiDeviceProvider__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_javax_sound_midi_dssi_DSSISynthesizer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,29 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_javax_sound_midi_dssi_DSSISynthesizer__
+#define __gnu_javax_sound_midi_dssi_DSSISynthesizer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_noteOn_1 (JNIEnv *env, jclass, jlong, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_noteOff_1 (JNIEnv *env, jclass, jlong, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_setPolyPressure_1 (JNIEnv *env, jclass, jlong, jint, jint, jint);
+JNIEXPORT jint JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_getPolyPressure_1 (JNIEnv *env, jclass, jlong, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_controlChange_1 (JNIEnv *env, jclass, jlong, jint, jint, jint);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_open_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_close_1 (JNIEnv *env, jclass, jlong);
+JNIEXPORT jstring JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_getProgramName_1 (JNIEnv *env, jclass, jlong, jint);
+JNIEXPORT jint JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_getProgramBank_1 (JNIEnv *env, jclass, jlong, jint);
+JNIEXPORT jint JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_getProgramProgram_1 (JNIEnv *env, jclass, jlong, jint);
+JNIEXPORT void JNICALL Java_gnu_javax_sound_midi_dssi_DSSISynthesizer_selectProgram_1 (JNIEnv *env, jclass, jlong, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_javax_sound_midi_dssi_DSSISynthesizer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeAttr.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeAttr.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeAttr.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeAttr.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeAttr__
+#define __gnu_xml_libxmlj_dom_GnomeAttr__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeAttr_getSpecified (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeAttr_getValue (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeAttr_setValue (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeAttr_xmljIsId (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeAttr__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocument.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocument.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocument.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocument.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,45 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeDocument__
+#define __gnu_xml_libxmlj_dom_GnomeDocument__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_free (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getDoctype (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getDocumentElement (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createDocumentType (JNIEnv *env, jobject, jstring, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createDocumentFragment (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createTextNode (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createComment (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createCDATASection (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createProcessingInstruction (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createEntityReference (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getElementsByTagName (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_xmljImportNode (JNIEnv *env, jobject, jobject, jboolean);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createElementNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_createAttributeNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getElementsByTagNameNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_xmljGetElementById (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getInputEncoding (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getXmlEncoding (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getXmlStandalone (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_setXmlStandalone (JNIEnv *env, jobject, jboolean);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getXmlVersion (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_setXmlVersion (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_getDocumentURI (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_setDocumentURI (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_xmljAdoptNode (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_renameNode (JNIEnv *env, jobject, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocument_evaluate (JNIEnv *env, jobject, jstring, jobject, jobject, jshort, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeDocument__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentBuilder.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeDocumentBuilder__
+#define __gnu_xml_libxmlj_dom_GnomeDocumentBuilder__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocumentBuilder_parseStream (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean, jboolean, jboolean, jboolean);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocumentBuilder_createDocument (JNIEnv *env, jobject, jstring, jstring, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeDocumentBuilder__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeDocumentType.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeDocumentType__
+#define __gnu_xml_libxmlj_dom_GnomeDocumentType__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocumentType_getPublicId (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocumentType_getSystemId (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeDocumentType_getInternalSubset (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeDocumentType__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeElement.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeElement.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeElement.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeElement.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,31 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeElement__
+#define __gnu_xml_libxmlj_dom_GnomeElement__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getAttribute (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_setAttribute (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getAttributeNode (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_setAttributeNode (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_removeAttributeNode (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getElementsByTagName (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getAttributeNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_setAttributeNS (JNIEnv *env, jobject, jstring, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getAttributeNodeNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_setAttributeNodeNS (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_getElementsByTagNameNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_hasAttribute (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeElement_hasAttributeNS (JNIEnv *env, jobject, jstring, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeElement__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeEntity.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeEntity.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeEntity.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeEntity.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeEntity__
+#define __gnu_xml_libxmlj_dom_GnomeEntity__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeEntity_getPublicId (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeEntity_getSystemId (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeEntity_getNotationName (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeEntity__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNamedNodeMap.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeNamedNodeMap__
+#define __gnu_xml_libxmlj_dom_GnomeNamedNodeMap__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_getNamedItem (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_setNamedItem (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_removeNamedItem (JNIEnv *env, jobject, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_item (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_getLength (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_getNamedItemNS (JNIEnv *env, jobject, jstring, jstring);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_setNamedItemNS (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNamedNodeMap_removeNamedItemNS (JNIEnv *env, jobject, jstring, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeNamedNodeMap__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNode.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNode.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNode.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNode.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,46 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeNode__
+#define __gnu_xml_libxmlj_dom_GnomeNode__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getNodeName (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getNodeValue (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_setNodeValue (JNIEnv *env, jobject, jstring);
+JNIEXPORT jshort JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getNodeType (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getParentNode (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getFirstChild (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getLastChild (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getPreviousSibling (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getNextSibling (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getOwnerDocument (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljInsertBefore (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljReplaceChild (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljRemoveChild (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljAppendChild (JNIEnv *env, jobject, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_hasChildNodes (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljCloneNode (JNIEnv *env, jobject, jboolean);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_normalize (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getNamespaceURI (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getPrefix (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_setPrefix (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getLocalName (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_hasAttributes (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_getBaseURI (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_xmljCompareTo (JNIEnv *env, jobject, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_lookupPrefix (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_isDefaultNamespace (JNIEnv *env, jobject, jstring);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_lookupNamespaceURI (JNIEnv *env, jobject, jstring);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeNode_isEqualNode (JNIEnv *env, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeNode__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNodeList.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNodeList.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNodeList.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNodeList.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeNodeList__
+#define __gnu_xml_libxmlj_dom_GnomeNodeList__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeNodeList_item (JNIEnv *env, jobject, jint);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_dom_GnomeNodeList_getLength (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeNodeList__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNotation.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNotation.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNotation.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeNotation.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeNotation__
+#define __gnu_xml_libxmlj_dom_GnomeNotation__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNotation_getPublicId (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeNotation_getSystemId (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeNotation__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeProcessingInstruction.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,20 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeProcessingInstruction__
+#define __gnu_xml_libxmlj_dom_GnomeProcessingInstruction__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeProcessingInstruction_getData (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeProcessingInstruction_setData (JNIEnv *env, jobject, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeProcessingInstruction__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeTypeInfo.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeTypeInfo__
+#define __gnu_xml_libxmlj_dom_GnomeTypeInfo__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeTypeInfo_getTypeName (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeTypeInfo_getTypeNamespace (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeTypeInfo_isDerivedFrom (JNIEnv *env, jobject, jstring, jstring, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeTypeInfo__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathExpression.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeXPathExpression__
+#define __gnu_xml_libxmlj_dom_GnomeXPathExpression__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathExpression_init (JNIEnv *env, jobject, jstring);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathExpression_free (JNIEnv *env, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathExpression_doEvaluate (JNIEnv *env, jobject, jobject, jobject, jshort, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeXPathExpression__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNSResolver.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,18 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeXPathNSResolver__
+#define __gnu_xml_libxmlj_dom_GnomeXPathNSResolver__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeXPathNSResolver__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathNodeList.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeXPathNodeList__
+#define __gnu_xml_libxmlj_dom_GnomeXPathNodeList__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathNodeList_free (JNIEnv *env, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathNodeList_getLength (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathNodeList_item (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeXPathNodeList__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_dom_GnomeXPathResult.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,28 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_dom_GnomeXPathResult__
+#define __gnu_xml_libxmlj_dom_GnomeXPathResult__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_free (JNIEnv *env, jobject, jobject);
+JNIEXPORT jshort JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getResultType (JNIEnv *env, jobject);
+JNIEXPORT jdouble JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getNumberValue (JNIEnv *env, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getStringValue (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getBooleanValue (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getSingleNodeValue (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getInvalidIteratorState (JNIEnv *env, jobject);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_getSnapshotLength (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_iterateNext (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_dom_GnomeXPathResult_snapshotItem (JNIEnv *env, jobject, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_dom_GnomeXPathResult__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeLocator.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeLocator.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeLocator.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeLocator.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_sax_GnomeLocator__
+#define __gnu_xml_libxmlj_sax_GnomeLocator__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_sax_GnomeLocator_publicId (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jstring JNICALL Java_gnu_xml_libxmlj_sax_GnomeLocator_systemId (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_sax_GnomeLocator_lineNumber (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jint JNICALL Java_gnu_xml_libxmlj_sax_GnomeLocator_columnNumber (JNIEnv *env, jobject, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_sax_GnomeLocator__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_sax_GnomeXMLReader.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_sax_GnomeXMLReader__
+#define __gnu_xml_libxmlj_sax_GnomeXMLReader__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_sax_GnomeXMLReader_parseStream (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean, jboolean, jboolean, jboolean, jboolean, jboolean);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_sax_GnomeXMLReader__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,28 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_transform_GnomeTransformer__
+#define __gnu_xml_libxmlj_transform_GnomeTransformer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_newStylesheet (JNIEnv *env, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_newStylesheetFromStream (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_newStylesheetFromDoc (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformStreamToStream (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformStreamToDoc (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformStreamToSAX (JNIEnv *env, jobject, jobject, jbyteArray, jstring, jstring, jstring, jboolean, jboolean, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformDocToStream (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT jobject JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformDocToDoc (JNIEnv *env, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_transformDocToSAX (JNIEnv *env, jobject, jobject, jobject);
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformer_free (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_transform_GnomeTransformer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/gnu_xml_libxmlj_transform_GnomeTransformerFactory.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __gnu_xml_libxmlj_transform_GnomeTransformerFactory__
+#define __gnu_xml_libxmlj_transform_GnomeTransformerFactory__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_gnu_xml_libxmlj_transform_GnomeTransformerFactory_freeLibxsltGlobal (JNIEnv *env, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __gnu_xml_libxmlj_transform_GnomeTransformerFactory__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMFile.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMFile.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMFile.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMFile.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,37 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_io_VMFile__
+#define __java_io_VMFile__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_java_io_VMFile_lastModified (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_setReadOnly (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_create (JNIEnv *env, jclass, jstring);
+JNIEXPORT jobjectArray JNICALL Java_java_io_VMFile_list (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_renameTo (JNIEnv *env, jclass, jstring, jstring);
+JNIEXPORT jlong JNICALL Java_java_io_VMFile_length (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_exists (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_delete (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_setLastModified (JNIEnv *env, jclass, jstring, jlong);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_mkdir (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_isFile (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_canWrite (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_canRead (JNIEnv *env, jclass, jstring);
+JNIEXPORT jboolean JNICALL Java_java_io_VMFile_isDirectory (JNIEnv *env, jclass, jstring);
+JNIEXPORT jstring JNICALL Java_java_io_VMFile_toCanonicalForm (JNIEnv *env, jclass, jstring);
+#undef java_io_VMFile_IS_CASE_SENSITIVE
+#define java_io_VMFile_IS_CASE_SENSITIVE 1L
+#undef java_io_VMFile_IS_DOS_8_3
+#define java_io_VMFile_IS_DOS_8_3 0L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_io_VMFile__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectInputStream.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectInputStream.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectInputStream.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectInputStream.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_io_VMObjectInputStream__
+#define __java_io_VMObjectInputStream__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_java_io_VMObjectInputStream_allocateObject (JNIEnv *env, jclass, jclass, jclass, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_io_VMObjectInputStream__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectStreamClass.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectStreamClass.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectStreamClass.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_io_VMObjectStreamClass.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,28 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_io_VMObjectStreamClass__
+#define __java_io_VMObjectStreamClass__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jboolean JNICALL Java_java_io_VMObjectStreamClass_hasClassInitializer (JNIEnv *env, jclass, jclass);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setDoubleNative (JNIEnv *env, jclass, jobject, jobject, jdouble);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setFloatNative (JNIEnv *env, jclass, jobject, jobject, jfloat);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setLongNative (JNIEnv *env, jclass, jobject, jobject, jlong);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setIntNative (JNIEnv *env, jclass, jobject, jobject, jint);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setShortNative (JNIEnv *env, jclass, jobject, jobject, jshort);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setCharNative (JNIEnv *env, jclass, jobject, jobject, jchar);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setByteNative (JNIEnv *env, jclass, jobject, jobject, jbyte);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setBooleanNative (JNIEnv *env, jclass, jobject, jobject, jboolean);
+JNIEXPORT void JNICALL Java_java_io_VMObjectStreamClass_setObjectNative (JNIEnv *env, jclass, jobject, jobject, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_io_VMObjectStreamClass__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMDouble.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMDouble.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMDouble.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMDouble.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,24 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_VMDouble__
+#define __java_lang_VMDouble__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jlong JNICALL Java_java_lang_VMDouble_doubleToLongBits (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jlong JNICALL Java_java_lang_VMDouble_doubleToRawLongBits (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMDouble_longBitsToDouble (JNIEnv *env, jclass, jlong);
+JNIEXPORT jstring JNICALL Java_java_lang_VMDouble_toString (JNIEnv *env, jclass, jdouble, jboolean);
+JNIEXPORT void JNICALL Java_java_lang_VMDouble_initIDs (JNIEnv *env, jclass);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMDouble_parseDouble (JNIEnv *env, jclass, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_VMDouble__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMFloat.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMFloat.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMFloat.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMFloat.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_VMFloat__
+#define __java_lang_VMFloat__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jint JNICALL Java_java_lang_VMFloat_floatToIntBits (JNIEnv *env, jclass, jfloat);
+JNIEXPORT jint JNICALL Java_java_lang_VMFloat_floatToRawIntBits (JNIEnv *env, jclass, jfloat);
+JNIEXPORT jfloat JNICALL Java_java_lang_VMFloat_intBitsToFloat (JNIEnv *env, jclass, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_VMFloat__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMMath.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMMath.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMMath.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMMath.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,41 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_VMMath__
+#define __java_lang_VMMath__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_sin (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_cos (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_tan (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_asin (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_acos (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_atan (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_atan2 (JNIEnv *env, jclass, jdouble, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_exp (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_log (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_sqrt (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_pow (JNIEnv *env, jclass, jdouble, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_IEEEremainder (JNIEnv *env, jclass, jdouble, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_ceil (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_floor (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_rint (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_cbrt (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_cosh (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_expm1 (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_hypot (JNIEnv *env, jclass, jdouble, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_log10 (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_log1p (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_sinh (JNIEnv *env, jclass, jdouble);
+JNIEXPORT jdouble JNICALL Java_java_lang_VMMath_tanh (JNIEnv *env, jclass, jdouble);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_VMMath__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMProcess.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMProcess.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMProcess.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMProcess.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,27 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_VMProcess__
+#define __java_lang_VMProcess__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_java_lang_VMProcess_nativeSpawn (JNIEnv *env, jobject, jobjectArray, jobjectArray, jobject, jboolean);
+JNIEXPORT jboolean JNICALL Java_java_lang_VMProcess_nativeReap (JNIEnv *env, jclass);
+JNIEXPORT void JNICALL Java_java_lang_VMProcess_nativeKill (JNIEnv *env, jclass, jlong);
+#undef java_lang_VMProcess_INITIAL
+#define java_lang_VMProcess_INITIAL 0L
+#undef java_lang_VMProcess_RUNNING
+#define java_lang_VMProcess_RUNNING 1L
+#undef java_lang_VMProcess_TERMINATED
+#define java_lang_VMProcess_TERMINATED 2L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_VMProcess__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMSystem.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMSystem.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMSystem.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_VMSystem.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_VMSystem__
+#define __java_lang_VMSystem__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_java_lang_VMSystem_arraycopy (JNIEnv *env, jclass, jobject, jint, jobject, jint, jint);
+JNIEXPORT jint JNICALL Java_java_lang_VMSystem_identityHashCode (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_java_lang_VMSystem_setIn (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_java_lang_VMSystem_setOut (JNIEnv *env, jclass, jobject);
+JNIEXPORT void JNICALL Java_java_lang_VMSystem_setErr (JNIEnv *env, jclass, jobject);
+JNIEXPORT jlong JNICALL Java_java_lang_VMSystem_nanoTime (JNIEnv *env, jclass);
+JNIEXPORT jobject JNICALL Java_java_lang_VMSystem_environ (JNIEnv *env, jclass);
+JNIEXPORT jstring JNICALL Java_java_lang_VMSystem_getenv (JNIEnv *env, jclass, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_VMSystem__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_reflect_VMArray.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_reflect_VMArray.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_reflect_VMArray.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_lang_reflect_VMArray.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_lang_reflect_VMArray__
+#define __java_lang_reflect_VMArray__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_java_lang_reflect_VMArray_createObjectArray (JNIEnv *env, jclass, jclass, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_lang_reflect_VMArray__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMInetAddress.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMInetAddress.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMInetAddress.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMInetAddress.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_net_VMInetAddress__
+#define __java_net_VMInetAddress__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_java_net_VMInetAddress_getLocalHostname (JNIEnv *env, jclass);
+JNIEXPORT jbyteArray JNICALL Java_java_net_VMInetAddress_lookupInaddrAny (JNIEnv *env, jclass);
+JNIEXPORT jstring JNICALL Java_java_net_VMInetAddress_getHostByAddr (JNIEnv *env, jclass, jbyteArray);
+JNIEXPORT jobjectArray JNICALL Java_java_net_VMInetAddress_getHostByName (JNIEnv *env, jclass, jstring);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_net_VMInetAddress__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMNetworkInterface.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMNetworkInterface.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMNetworkInterface.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMNetworkInterface.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_net_VMNetworkInterface__
+#define __java_net_VMNetworkInterface__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_java_net_VMNetworkInterface_getInterfaces (JNIEnv *env, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_net_VMNetworkInterface__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMURLConnection.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMURLConnection.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMURLConnection.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_net_VMURLConnection.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_net_VMURLConnection__
+#define __java_net_VMURLConnection__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_java_net_VMURLConnection_init (JNIEnv *env, jclass);
+JNIEXPORT jstring JNICALL Java_java_net_VMURLConnection_guessContentTypeFromBuffer (JNIEnv *env, jclass, jbyteArray, jint);
+#undef java_net_VMURLConnection_LENGTH
+#define java_net_VMURLConnection_LENGTH 1024L
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_net_VMURLConnection__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_MappedByteBufferImpl.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_MappedByteBufferImpl.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_MappedByteBufferImpl.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_MappedByteBufferImpl.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,22 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_nio_MappedByteBufferImpl__
+#define __java_nio_MappedByteBufferImpl__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT void JNICALL Java_java_nio_MappedByteBufferImpl_unmapImpl (JNIEnv *env, jobject);
+JNIEXPORT jboolean JNICALL Java_java_nio_MappedByteBufferImpl_isLoadedImpl (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_java_nio_MappedByteBufferImpl_loadImpl (JNIEnv *env, jobject);
+JNIEXPORT void JNICALL Java_java_nio_MappedByteBufferImpl_forceImpl (JNIEnv *env, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_nio_MappedByteBufferImpl__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_VMDirectByteBuffer.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_VMDirectByteBuffer.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_VMDirectByteBuffer.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_nio_VMDirectByteBuffer.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,26 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_nio_VMDirectByteBuffer__
+#define __java_nio_VMDirectByteBuffer__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jobject JNICALL Java_java_nio_VMDirectByteBuffer_allocate (JNIEnv *env, jclass, jint);
+JNIEXPORT void JNICALL Java_java_nio_VMDirectByteBuffer_free (JNIEnv *env, jclass, jobject);
+JNIEXPORT jbyte JNICALL Java_java_nio_VMDirectByteBuffer_get__Lgnu_classpath_Pointer_2I (JNIEnv *env, jclass, jobject, jint);
+JNIEXPORT void JNICALL Java_java_nio_VMDirectByteBuffer_get__Lgnu_classpath_Pointer_2I_3BII (JNIEnv *env, jclass, jobject, jint, jbyteArray, jint, jint);
+JNIEXPORT void JNICALL Java_java_nio_VMDirectByteBuffer_put__Lgnu_classpath_Pointer_2IB (JNIEnv *env, jclass, jobject, jint, jbyte);
+JNIEXPORT void JNICALL Java_java_nio_VMDirectByteBuffer_put__Lgnu_classpath_Pointer_2I_3BII (JNIEnv *env, jclass, jobject, jint, jbyteArray, jint, jint);
+JNIEXPORT jobject JNICALL Java_java_nio_VMDirectByteBuffer_adjustAddress (JNIEnv *env, jclass, jobject, jint);
+JNIEXPORT void JNICALL Java_java_nio_VMDirectByteBuffer_shiftDown (JNIEnv *env, jclass, jobject, jint, jint, jint);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_nio_VMDirectByteBuffer__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/java_util_VMTimeZone.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/java_util_VMTimeZone.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/java_util_VMTimeZone.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/java_util_VMTimeZone.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,19 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+
+#ifndef __java_util_VMTimeZone__
+#define __java_util_VMTimeZone__
+
+#include <jni.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+JNIEXPORT jstring JNICALL Java_java_util_VMTimeZone_getSystemTimeZoneId (JNIEnv *env, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __java_util_VMTimeZone__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/jawt.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/jawt.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/jawt.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/jawt.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,108 @@
+/* jawt.h -- the machine-independent parts of the AWT Native Interface
+ Copyright (C) 2005 Free Software Foundation, Inc.
+
+ This file is part of GNU Classpath.
+
+ GNU Classpath is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GNU Classpath is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GNU Classpath; see the file COPYING. If not, write to the
+ Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ 02110-1301 USA.
+
+ Linking this library statically or dynamically with other modules is
+ making a combined work based on this library. Thus, the terms and
+ conditions of the GNU General Public License cover the whole
+ combination.
+
+ As a special exception, the copyright holders of this library give you
+ permission to link this library with independent modules to produce an
+ executable, regardless of the license terms of these independent
+ modules, and to copy and distribute the resulting executable under
+ terms of your choice, provided that you also meet, for each linked
+ independent module, the terms and conditions of the license of that
+ module. An independent module is a module which is not derived from
+ or based on this library. If you modify this library, you may extend
+ this exception to your version of the library, but you are not
+ obligated to do so. If you do not wish to do so, delete this
+ exception statement from your version. */
+
+
+/*
+ * The AWT Native Interface allows direct access to native screen
+ * resources from within a Canvas's paint method.
+ */
+
+#ifndef __jawt_h__
+#define __jawt_h__
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+#define JAWT_VERSION_1_3 0x10003
+#define JAWT_VERSION_1_4 0x10004
+
+#define JAWT_LOCK_ERROR 0x1
+#define JAWT_LOCK_CLIP_CHANGED 0x2
+#define JAWT_LOCK_BOUNDS_CHANGED 0x4
+#define JAWT_LOCK_SURFACE_CHANGED 0x8
+
+struct _JAWT_Rectangle
+{
+ jint x;
+ jint y;
+ jint width;
+ jint height;
+};
+
+struct _JAWT_DrawingSurfaceInfo
+{
+ void* platformInfo;
+ struct _JAWT_DrawingSurface *ds;
+ struct _JAWT_Rectangle bounds;
+ jint clipSize;
+ struct _JAWT_Rectangle *clip;
+};
+
+struct _JAWT_DrawingSurface
+{
+ JNIEnv* env;
+ jobject target;
+ jint (JNICALL* Lock) (struct _JAWT_DrawingSurface*);
+ struct _JAWT_DrawingSurfaceInfo* (JNICALL* GetDrawingSurfaceInfo) (struct _JAWT_DrawingSurface*);
+ void (JNICALL* FreeDrawingSurfaceInfo) (struct _JAWT_DrawingSurfaceInfo*);
+ void (JNICALL* Unlock) (struct _JAWT_DrawingSurface*);
+};
+
+struct _JAWT
+{
+ jint version;
+ struct _JAWT_DrawingSurface* (JNICALL* GetDrawingSurface) (JNIEnv*, jobject);
+ void (JNICALL* FreeDrawingSurface) (struct _JAWT_DrawingSurface*);
+ void (JNICALL *Lock) (JNIEnv*);
+ void (JNICALL *Unlock) (JNIEnv*);
+ jobject (JNICALL *GetComponent)(JNIEnv*, void*);
+};
+
+typedef struct _JAWT_Rectangle JAWT_Rectangle;
+typedef struct _JAWT_DrawingSurfaceInfo JAWT_DrawingSurfaceInfo;
+typedef struct _JAWT_DrawingSurface JAWT_DrawingSurface;
+typedef struct _JAWT JAWT;
+
+JNIEXPORT jboolean JNICALL JAWT_GetAWT (JNIEnv* env, struct _JAWT* awt);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __jawt_h__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/jawt_md.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/jawt_md.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/jawt_md.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/jawt_md.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,67 @@
+/* jawt_md.h -- the X11-dependent parts of the AWT Native Interface
+ Copyright (C) 2005 Free Software Foundation, Inc.
+
+ This file is part of GNU Classpath.
+
+ GNU Classpath is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GNU Classpath is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GNU Classpath; see the file COPYING. If not, write to the
+ Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ 02110-1301 USA.
+
+ Linking this library statically or dynamically with other modules is
+ making a combined work based on this library. Thus, the terms and
+ conditions of the GNU General Public License cover the whole
+ combination.
+
+ As a special exception, the copyright holders of this library give you
+ permission to link this library with independent modules to produce an
+ executable, regardless of the license terms of these independent
+ modules, and to copy and distribute the resulting executable under
+ terms of your choice, provided that you also meet, for each linked
+ independent module, the terms and conditions of the license of that
+ module. An independent module is a module which is not derived from
+ or based on this library. If you modify this library, you may extend
+ this exception to your version of the library, but you are not
+ obligated to do so. If you do not wish to do so, delete this
+ exception statement from your version. */
+
+
+#ifndef __jawt_md_h__
+#define __jawt_md_h__
+
+#include <jni.h>
+#include <jawt.h>
+#include <X11/Xlib.h>
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+
+struct _JAWT_X11DrawingSurfaceInfo
+{
+ Drawable drawable;
+ Display* display;
+ VisualID visualID;
+ Colormap colormapID;
+ int depth;
+ int (JNICALL *GetAWTColor)(struct _JAWT_DrawingSurface*, int, int, int);
+};
+
+typedef struct _JAWT_X11DrawingSurfaceInfo JAWT_X11DrawingSurfaceInfo;
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* __jawt_md_h__ */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/jni.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/jni.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/jni.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/jni.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,1638 @@
+/* jni.h
+ Copyright (C) 1998, 1999, 2000, 2001, 2002, 2004, 2005, 2006 Free Software Foundation
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library. Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module. An independent module is a module which is not derived from
+or based on this library. If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so. If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+/* Note: this file must be compilable by the C compiler (for now,
+ assuming GNU C is ok). This means you must never use `//'
+ comments, and all C++-specific code must be conditional on
+ __cplusplus. */
+
+#ifndef _CLASSPATH_JNI_H
+#define _CLASSPATH_JNI_H
+
+/* We include <stdio.h> for compatibility with Sun's <jni.h>. */
+#include <stdio.h>
+
+#include <stdarg.h>
+
+#include "jni_md.h"
+
+/* The VM might define jobject and friends. */
+#ifndef _CLASSPATH_VM_JNI_TYPES_DEFINED
+
+# ifdef __cplusplus
+
+/* Define dummy classes and then define the JNI types as pointers. */
+struct __jobject {};
+struct __jclass : __jobject {};
+struct __jstring : __jobject {};
+struct __jthrowable : __jobject {};
+struct __jweak : __jobject {};
+struct __jarray : __jobject {};
+struct __jobjectArray : __jarray {};
+struct __jbyteArray : __jarray {};
+struct __jshortArray : __jarray {};
+struct __jintArray : __jarray {};
+struct __jlongArray : __jarray {};
+struct __jbooleanArray : __jarray {};
+struct __jcharArray : __jarray {};
+struct __jfloatArray : __jarray {};
+struct __jdoubleArray : __jarray {};
+
+typedef __jobject *jobject;
+typedef __jclass *jclass;
+typedef __jstring *jstring;
+typedef __jthrowable *jthrowable;
+typedef __jweak *jweak;
+typedef __jarray *jarray;
+typedef __jobjectArray *jobjectArray;
+typedef __jbyteArray *jbyteArray;
+typedef __jshortArray *jshortArray;
+typedef __jintArray *jintArray;
+typedef __jlongArray *jlongArray;
+typedef __jbooleanArray *jbooleanArray;
+typedef __jcharArray *jcharArray;
+typedef __jfloatArray *jfloatArray;
+typedef __jdoubleArray *jdoubleArray;
+
+#define JNI_TRUE true
+#define JNI_FALSE false
+
+typedef struct _Jv_JNIEnv JNIEnv;
+typedef struct _Jv_JavaVM JavaVM;
+
+# else /* __cplusplus */
+
+/* For C, simply define the class types as generic pointers. */
+typedef void *jobject;
+typedef jobject jclass;
+typedef jobject jstring;
+typedef jobject jthrowable;
+typedef jobject jweak;
+typedef jobject jarray;
+typedef jobject jobjectArray;
+typedef jobject jbyteArray;
+typedef jobject jshortArray;
+typedef jobject jintArray;
+typedef jobject jlongArray;
+typedef jobject jbooleanArray;
+typedef jobject jcharArray;
+typedef jobject jfloatArray;
+typedef jobject jdoubleArray;
+
+#define JNI_TRUE 1
+#define JNI_FALSE 0
+
+typedef const struct JNINativeInterface *JNIEnv;
+typedef const struct JNIInvokeInterface *JavaVM;
+
+# endif /* __cplusplus */
+
+#endif /* _CLASSPATH_VM_JNI_TYPES_DEFINED */
+
+/*
+ * Before jni.h is #included within a typical JVM, the source code should
+ * #define _JNI_VM_INTERNAL_TYPES_DEFINED and provide the real declarations
+ * for 'jobject', 'jfieldID', 'jmethodID' and other implementation types.
+ * If _JNI_VM_INTERNAL_TYPES_DEFINED is not defined, the following
+ * declares the old versions of the types.
+ */
+#ifndef _CLASSPATH_VM_INTERNAL_TYPES_DEFINED
+struct _jfieldID;
+struct _jmethodID;
+typedef struct _jfieldID *jfieldID;
+typedef struct _jmethodID *jmethodID;
+#endif
+
+/* Version numbers. */
+#define JNI_VERSION_1_1 0x00010001
+#define JNI_VERSION_1_2 0x00010002
+#define JNI_VERSION_1_4 0x00010004
+
+/* Used when releasing array elements. */
+#define JNI_COMMIT 1
+#define JNI_ABORT 2
+
+/* Error codes */
+#define JNI_OK 0
+#define JNI_ERR (-1)
+#define JNI_EDETACHED (-2)
+#define JNI_EVERSION (-3)
+
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif /* __cplusplus */
+
+/* These functions might be defined in libraries which we load; the
+ JNI implementation calls them at the appropriate times. */
+extern JNIEXPORT jint JNICALL JNI_OnLoad (JavaVM *, void *);
+extern JNIEXPORT void JNICALL JNI_OnUnload (JavaVM *, void *);
+
+/* This can be defined as JNIIMPORT or JNIEXPORT by the md file,
+ depending on whether this is the implementation or a user. */
+#ifndef _CLASSPATH_JNIIMPEXP
+#define _CLASSPATH_JNIIMPEXP JNIIMPORT
+#endif
+
+/* These functions are called by user code to start using the
+ invocation API. */
+extern _CLASSPATH_JNIIMPEXP jint JNICALL
+JNI_GetDefaultJavaVMInitArgs (void *);
+
+extern _CLASSPATH_JNIIMPEXP jint JNICALL
+JNI_CreateJavaVM (JavaVM **, void **, void *);
+
+extern _CLASSPATH_JNIIMPEXP jint JNICALL
+JNI_GetCreatedJavaVMs (JavaVM **, jsize, jsize *);
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+typedef union jvalue
+{
+ jboolean z;
+ jbyte b;
+ jchar c;
+ jshort s;
+ jint i;
+ jlong j;
+ jfloat f;
+ jdouble d;
+ jobject l;
+} jvalue;
+
+/* This structure is used when registering native methods. */
+typedef struct
+{
+ char *name;
+ char *signature;
+ void *fnPtr; /* Sigh. */
+} JNINativeMethod;
+
+struct JNINativeInterface
+{
+ void *reserved0;
+ void *reserved1;
+ void *reserved2;
+ void *reserved3;
+
+ jint (JNICALL *GetVersion) (JNIEnv *);
+ jclass (JNICALL *DefineClass) (JNIEnv *, const char *,
+ jobject, const jbyte *,
+ jsize);
+ jclass (JNICALL *FindClass) (JNIEnv *, const char *);
+
+ jmethodID (JNICALL *FromReflectedMethod) (JNIEnv *, jobject);
+ jfieldID (JNICALL *FromReflectedField) (JNIEnv *, jobject);
+ jobject (JNICALL *ToReflectedMethod) (JNIEnv *, jclass,
+ jmethodID, jboolean);
+
+ jclass (JNICALL *GetSuperclass) (JNIEnv *, jclass);
+ jboolean (JNICALL *IsAssignableFrom) (JNIEnv *, jclass, jclass);
+
+ jobject (JNICALL *ToReflectedField) (JNIEnv *, jclass, jfieldID,
+ jboolean);
+
+ jint (JNICALL *Throw) (JNIEnv *, jthrowable);
+ jint (JNICALL *ThrowNew) (JNIEnv *, jclass,
+ const char *);
+ jthrowable (JNICALL *ExceptionOccurred) (JNIEnv *);
+ void (JNICALL *ExceptionDescribe) (JNIEnv *);
+ void (JNICALL *ExceptionClear) (JNIEnv *);
+ void (JNICALL *FatalError) (JNIEnv *, const char *);
+
+ jint (JNICALL *PushLocalFrame) (JNIEnv *, jint);
+ jobject (JNICALL *PopLocalFrame) (JNIEnv *, jobject);
+
+ jobject (JNICALL *NewGlobalRef) (JNIEnv *, jobject);
+ void (JNICALL *DeleteGlobalRef) (JNIEnv *, jobject);
+ void (JNICALL *DeleteLocalRef) (JNIEnv *, jobject);
+ jboolean (JNICALL *IsSameObject) (JNIEnv *, jobject,
+ jobject);
+
+ jobject (JNICALL *NewLocalRef) (JNIEnv *, jobject);
+ jint (JNICALL *EnsureLocalCapacity) (JNIEnv *, jint);
+
+ jobject (JNICALL *AllocObject) (JNIEnv *, jclass);
+ jobject (JNICALL *NewObject) (JNIEnv *, jclass,
+ jmethodID, ...);
+ jobject (JNICALL *NewObjectV) (JNIEnv *, jclass,
+ jmethodID, va_list);
+ jobject (JNICALL *NewObjectA) (JNIEnv *, jclass,
+ jmethodID, jvalue *);
+
+ jclass (JNICALL *GetObjectClass) (JNIEnv *, jobject);
+ jboolean (JNICALL *IsInstanceOf) (JNIEnv *, jobject, jclass);
+ jmethodID (JNICALL *GetMethodID) (JNIEnv *, jclass,
+ const char *, const char *);
+
+ jobject (JNICALL *CallObjectMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jobject (JNICALL *CallObjectMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jobject (JNICALL *CallObjectMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jboolean (JNICALL *CallBooleanMethod) (JNIEnv *, jobject, jmethodID,
+ ...);
+ jboolean (JNICALL *CallBooleanMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jboolean (JNICALL *CallBooleanMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jbyte (JNICALL *CallByteMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jbyte (JNICALL *CallByteMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jbyte (JNICALL *CallByteMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jchar (JNICALL *CallCharMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jchar (JNICALL *CallCharMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jchar (JNICALL *CallCharMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jshort (JNICALL *CallShortMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jshort (JNICALL *CallShortMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jshort (JNICALL *CallShortMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jint (JNICALL *CallIntMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jint (JNICALL *CallIntMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jint (JNICALL *CallIntMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jlong (JNICALL *CallLongMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jlong (JNICALL *CallLongMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jlong (JNICALL *CallLongMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jfloat (JNICALL *CallFloatMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jfloat (JNICALL *CallFloatMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jfloat (JNICALL *CallFloatMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ jdouble (JNICALL *CallDoubleMethod) (JNIEnv *, jobject, jmethodID, ...);
+ jdouble (JNICALL *CallDoubleMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ jdouble (JNICALL *CallDoubleMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+ void (JNICALL *CallVoidMethod) (JNIEnv *, jobject, jmethodID, ...);
+ void (JNICALL *CallVoidMethodV) (JNIEnv *, jobject, jmethodID,
+ va_list);
+ void (JNICALL *CallVoidMethodA) (JNIEnv *, jobject, jmethodID,
+ jvalue *);
+
+ jobject (JNICALL *CallNonvirtualObjectMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jobject (JNICALL *CallNonvirtualObjectMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jobject (JNICALL *CallNonvirtualObjectMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jboolean (JNICALL *CallNonvirtualBooleanMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jboolean (JNICALL *CallNonvirtualBooleanMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jboolean (JNICALL *CallNonvirtualBooleanMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jbyte (JNICALL *CallNonvirtualByteMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jbyte (JNICALL *CallNonvirtualByteMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jbyte (JNICALL *CallNonvirtualByteMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jchar (JNICALL *CallNonvirtualCharMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jchar (JNICALL *CallNonvirtualCharMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jchar (JNICALL *CallNonvirtualCharMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jshort (JNICALL *CallNonvirtualShortMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jshort (JNICALL *CallNonvirtualShortMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jshort (JNICALL *CallNonvirtualShortMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jint (JNICALL *CallNonvirtualIntMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jint (JNICALL *CallNonvirtualIntMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jint (JNICALL *CallNonvirtualIntMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jlong (JNICALL *CallNonvirtualLongMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jlong (JNICALL *CallNonvirtualLongMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jlong (JNICALL *CallNonvirtualLongMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jfloat (JNICALL *CallNonvirtualFloatMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jfloat (JNICALL *CallNonvirtualFloatMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jfloat (JNICALL *CallNonvirtualFloatMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ jdouble (JNICALL *CallNonvirtualDoubleMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ jdouble (JNICALL *CallNonvirtualDoubleMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ jdouble (JNICALL *CallNonvirtualDoubleMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+ void (JNICALL *CallNonvirtualVoidMethod) (JNIEnv *, jobject, jclass,
+ jmethodID, ...);
+ void (JNICALL *CallNonvirtualVoidMethodV) (JNIEnv *, jobject, jclass,
+ jmethodID, va_list);
+ void (JNICALL *CallNonvirtualVoidMethodA) (JNIEnv *, jobject, jclass,
+ jmethodID, jvalue *);
+
+ jfieldID (JNICALL *GetFieldID) (JNIEnv *, jclass, const char *,
+ const char *);
+
+ jobject (JNICALL *GetObjectField) (JNIEnv *, jobject, jfieldID);
+ jboolean (JNICALL *GetBooleanField) (JNIEnv *, jobject, jfieldID);
+ jbyte (JNICALL *GetByteField) (JNIEnv *, jobject, jfieldID);
+ jchar (JNICALL *GetCharField) (JNIEnv *, jobject, jfieldID);
+ jshort (JNICALL *GetShortField) (JNIEnv *, jobject, jfieldID);
+ jint (JNICALL *GetIntField) (JNIEnv *, jobject, jfieldID);
+ jlong (JNICALL *GetLongField) (JNIEnv *, jobject, jfieldID);
+ jfloat (JNICALL *GetFloatField) (JNIEnv *, jobject, jfieldID);
+ jdouble (JNICALL *GetDoubleField) (JNIEnv *, jobject, jfieldID);
+
+ void (JNICALL *SetObjectField) (JNIEnv *, jobject,
+ jfieldID, jobject);
+ void (JNICALL *SetBooleanField) (JNIEnv *, jobject,
+ jfieldID, jboolean);
+ void (JNICALL *SetByteField) (JNIEnv *, jobject,
+ jfieldID, jbyte);
+ void (JNICALL *SetCharField) (JNIEnv *, jobject,
+ jfieldID, jchar);
+ void (JNICALL *SetShortField) (JNIEnv *, jobject,
+ jfieldID, jshort);
+ void (JNICALL *SetIntField) (JNIEnv *, jobject,
+ jfieldID, jint);
+ void (JNICALL *SetLongField) (JNIEnv *, jobject,
+ jfieldID, jlong);
+ void (JNICALL *SetFloatField) (JNIEnv *, jobject,
+ jfieldID, jfloat);
+ void (JNICALL *SetDoubleField) (JNIEnv *, jobject,
+ jfieldID, jdouble);
+
+ jmethodID (JNICALL *GetStaticMethodID) (JNIEnv *, jclass, const char *,
+ const char *);
+
+ jobject (JNICALL *CallStaticObjectMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jobject (JNICALL *CallStaticObjectMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jobject (JNICALL *CallStaticObjectMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jboolean (JNICALL *CallStaticBooleanMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jboolean (JNICALL *CallStaticBooleanMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jboolean (JNICALL *CallStaticBooleanMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jbyte (JNICALL *CallStaticByteMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jbyte (JNICALL *CallStaticByteMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jbyte (JNICALL *CallStaticByteMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jchar (JNICALL *CallStaticCharMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jchar (JNICALL *CallStaticCharMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jchar (JNICALL *CallStaticCharMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jshort (JNICALL *CallStaticShortMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jshort (JNICALL *CallStaticShortMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jshort (JNICALL *CallStaticShortMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jint (JNICALL *CallStaticIntMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jint (JNICALL *CallStaticIntMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jint (JNICALL *CallStaticIntMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jlong (JNICALL *CallStaticLongMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jlong (JNICALL *CallStaticLongMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jlong (JNICALL *CallStaticLongMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jfloat (JNICALL *CallStaticFloatMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jfloat (JNICALL *CallStaticFloatMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jfloat (JNICALL *CallStaticFloatMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ jdouble (JNICALL *CallStaticDoubleMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ jdouble (JNICALL *CallStaticDoubleMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ jdouble (JNICALL *CallStaticDoubleMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+ void (JNICALL *CallStaticVoidMethod) (JNIEnv *, jclass, jmethodID,
+ ...);
+ void (JNICALL *CallStaticVoidMethodV) (JNIEnv *, jclass, jmethodID,
+ va_list);
+ void (JNICALL *CallStaticVoidMethodA) (JNIEnv *, jclass, jmethodID,
+ jvalue *);
+
+ jfieldID (JNICALL *GetStaticFieldID) (JNIEnv *, jclass, const char *,
+ const char *);
+
+ jobject (JNICALL *GetStaticObjectField) (JNIEnv *, jclass, jfieldID);
+ jboolean (JNICALL *GetStaticBooleanField) (JNIEnv *, jclass, jfieldID);
+ jbyte (JNICALL *GetStaticByteField) (JNIEnv *, jclass, jfieldID);
+ jchar (JNICALL *GetStaticCharField) (JNIEnv *, jclass, jfieldID);
+ jshort (JNICALL *GetStaticShortField) (JNIEnv *, jclass, jfieldID);
+ jint (JNICALL *GetStaticIntField) (JNIEnv *, jclass, jfieldID);
+ jlong (JNICALL *GetStaticLongField) (JNIEnv *, jclass, jfieldID);
+ jfloat (JNICALL *GetStaticFloatField) (JNIEnv *, jclass, jfieldID);
+ jdouble (JNICALL *GetStaticDoubleField) (JNIEnv *, jclass, jfieldID);
+
+ void (JNICALL *SetStaticObjectField) (JNIEnv *, jclass,
+ jfieldID, jobject);
+ void (JNICALL *SetStaticBooleanField) (JNIEnv *, jclass,
+ jfieldID, jboolean);
+ void (JNICALL *SetStaticByteField) (JNIEnv *, jclass,
+ jfieldID, jbyte);
+ void (JNICALL *SetStaticCharField) (JNIEnv *, jclass,
+ jfieldID, jchar);
+ void (JNICALL *SetStaticShortField) (JNIEnv *, jclass,
+ jfieldID, jshort);
+ void (JNICALL *SetStaticIntField) (JNIEnv *, jclass,
+ jfieldID, jint);
+ void (JNICALL *SetStaticLongField) (JNIEnv *, jclass,
+ jfieldID, jlong);
+ void (JNICALL *SetStaticFloatField) (JNIEnv *, jclass,
+ jfieldID, jfloat);
+ void (JNICALL *SetStaticDoubleField) (JNIEnv *, jclass,
+ jfieldID, jdouble);
+
+ jstring (JNICALL *NewString) (JNIEnv *, const jchar *, jsize);
+ jsize (JNICALL *GetStringLength) (JNIEnv *, jstring);
+ const jchar * (JNICALL *GetStringChars) (JNIEnv *, jstring, jboolean *);
+ void (JNICALL *ReleaseStringChars) (JNIEnv *, jstring, const jchar *);
+ jstring (JNICALL *NewStringUTF) (JNIEnv *, const char *);
+ jsize (JNICALL *GetStringUTFLength) (JNIEnv *, jstring);
+ const char * (JNICALL *GetStringUTFChars) (JNIEnv *, jstring, jboolean *);
+ void (JNICALL *ReleaseStringUTFChars) (JNIEnv *, jstring, const char *);
+ jsize (JNICALL *GetArrayLength) (JNIEnv *, jarray);
+ jobjectArray (JNICALL *NewObjectArray) (JNIEnv *, jsize, jclass, jobject);
+ jobject (JNICALL *GetObjectArrayElement) (JNIEnv *, jobjectArray, jsize);
+ void (JNICALL *SetObjectArrayElement) (JNIEnv *, jobjectArray, jsize,
+ jobject);
+
+ jbooleanArray (JNICALL *NewBooleanArray) (JNIEnv *, jsize);
+ jbyteArray (JNICALL *NewByteArray) (JNIEnv *, jsize);
+ jcharArray (JNICALL *NewCharArray) (JNIEnv *, jsize);
+ jshortArray (JNICALL *NewShortArray) (JNIEnv *, jsize);
+ jintArray (JNICALL *NewIntArray) (JNIEnv *, jsize);
+ jlongArray (JNICALL *NewLongArray) (JNIEnv *, jsize);
+ jfloatArray (JNICALL *NewFloatArray) (JNIEnv *, jsize);
+ jdoubleArray (JNICALL *NewDoubleArray) (JNIEnv *, jsize);
+
+ jboolean * (JNICALL *GetBooleanArrayElements) (JNIEnv *, jbooleanArray,
+ jboolean *);
+ jbyte * (JNICALL *GetByteArrayElements) (JNIEnv *, jbyteArray,
+ jboolean *);
+ jchar * (JNICALL *GetCharArrayElements) (JNIEnv *, jcharArray,
+ jboolean *);
+ jshort * (JNICALL *GetShortArrayElements) (JNIEnv *, jshortArray,
+ jboolean *);
+ jint * (JNICALL *GetIntArrayElements) (JNIEnv *, jintArray,
+ jboolean *);
+ jlong * (JNICALL *GetLongArrayElements) (JNIEnv *, jlongArray,
+ jboolean *);
+ jfloat * (JNICALL *GetFloatArrayElements) (JNIEnv *, jfloatArray,
+ jboolean *);
+ jdouble * (JNICALL *GetDoubleArrayElements) (JNIEnv *, jdoubleArray,
+ jboolean *);
+
+ void (JNICALL *ReleaseBooleanArrayElements) (JNIEnv *, jbooleanArray,
+ jboolean *, jint);
+ void (JNICALL *ReleaseByteArrayElements) (JNIEnv *, jbyteArray,
+ jbyte *, jint);
+ void (JNICALL *ReleaseCharArrayElements) (JNIEnv *, jcharArray,
+ jchar *, jint);
+ void (JNICALL *ReleaseShortArrayElements) (JNIEnv *, jshortArray,
+ jshort *, jint);
+ void (JNICALL *ReleaseIntArrayElements) (JNIEnv *, jintArray,
+ jint *, jint);
+ void (JNICALL *ReleaseLongArrayElements) (JNIEnv *, jlongArray,
+ jlong *, jint);
+ void (JNICALL *ReleaseFloatArrayElements) (JNIEnv *, jfloatArray,
+ jfloat *, jint);
+ void (JNICALL *ReleaseDoubleArrayElements) (JNIEnv *, jdoubleArray,
+ jdouble *, jint);
+
+ void (JNICALL *GetBooleanArrayRegion) (JNIEnv *, jbooleanArray,
+ jsize, jsize, jboolean *);
+ void (JNICALL *GetByteArrayRegion) (JNIEnv *, jbyteArray,
+ jsize, jsize, jbyte *);
+ void (JNICALL *GetCharArrayRegion) (JNIEnv *, jcharArray,
+ jsize, jsize, jchar *);
+ void (JNICALL *GetShortArrayRegion) (JNIEnv *, jshortArray,
+ jsize, jsize, jshort *);
+ void (JNICALL *GetIntArrayRegion) (JNIEnv *, jintArray,
+ jsize, jsize, jint *);
+ void (JNICALL *GetLongArrayRegion) (JNIEnv *, jlongArray,
+ jsize, jsize, jlong *);
+ void (JNICALL *GetFloatArrayRegion) (JNIEnv *, jfloatArray,
+ jsize, jsize, jfloat *);
+ void (JNICALL *GetDoubleArrayRegion) (JNIEnv *, jdoubleArray,
+ jsize, jsize, jdouble *);
+
+ void (JNICALL *SetBooleanArrayRegion) (JNIEnv *, jbooleanArray,
+ jsize, jsize, jboolean *);
+ void (JNICALL *SetByteArrayRegion) (JNIEnv *, jbyteArray,
+ jsize, jsize, jbyte *);
+ void (JNICALL *SetCharArrayRegion) (JNIEnv *, jcharArray,
+ jsize, jsize, jchar *);
+ void (JNICALL *SetShortArrayRegion) (JNIEnv *, jshortArray,
+ jsize, jsize, jshort *);
+ void (JNICALL *SetIntArrayRegion) (JNIEnv *, jintArray,
+ jsize, jsize, jint *);
+ void (JNICALL *SetLongArrayRegion) (JNIEnv *, jlongArray,
+ jsize, jsize, jlong *);
+ void (JNICALL *SetFloatArrayRegion) (JNIEnv *, jfloatArray,
+ jsize, jsize, jfloat *);
+ void (JNICALL *SetDoubleArrayRegion) (JNIEnv *, jdoubleArray,
+ jsize, jsize, jdouble *);
+
+ jint (JNICALL *RegisterNatives) (JNIEnv *, jclass,
+ const JNINativeMethod *,
+ jint);
+ jint (JNICALL *UnregisterNatives) (JNIEnv *, jclass);
+ jint (JNICALL *MonitorEnter) (JNIEnv *, jobject);
+ jint (JNICALL *MonitorExit) (JNIEnv *, jobject);
+ jint (JNICALL *GetJavaVM) (JNIEnv *, JavaVM **);
+
+ /* ---- JNI 1.2 functions ---- */
+ void (JNICALL *GetStringRegion) (JNIEnv *, jstring, jsize,
+ jsize, jchar *);
+ void (JNICALL *GetStringUTFRegion) (JNIEnv *, jstring, jsize,
+ jsize, char *);
+
+ void * (JNICALL *GetPrimitiveArrayCritical) (JNIEnv *, jarray,
+ jboolean *);
+ void (JNICALL *ReleasePrimitiveArrayCritical) (JNIEnv *, jarray, void *,
+ jint);
+
+ const jchar * (JNICALL *GetStringCritical) (JNIEnv *, jstring,
+ jboolean *);
+ void (JNICALL *ReleaseStringCritical) (JNIEnv *, jstring,
+ const jchar *);
+
+ jweak (JNICALL *NewWeakGlobalRef) (JNIEnv *, jobject);
+ void (JNICALL *DeleteWeakGlobalRef) (JNIEnv *, jweak);
+
+ jboolean (JNICALL *ExceptionCheck) (JNIEnv *);
+
+ /* ---- JNI 1.4 functions ---- */
+ jobject (JNICALL *NewDirectByteBuffer) (JNIEnv *, void *, jlong);
+ void * (JNICALL *GetDirectBufferAddress) (JNIEnv *, jobject);
+ jlong (JNICALL *GetDirectBufferCapacity) (JNIEnv *, jobject);
+};
+
+#ifdef __cplusplus
+
+class _Jv_JNIEnv
+{
+public:
+ /* The method table. */
+ struct JNINativeInterface *p;
+
+#ifdef _CLASSPATH_JNIENV_CONTENTS
+ _CLASSPATH_JNIENV_CONTENTS
+#endif
+
+ jint GetVersion ()
+ { return p->GetVersion (this); }
+
+ jclass DefineClass (const char *name, jobject obj0, const jbyte * val1,
+ jsize val2)
+ { return p->DefineClass (this, name, obj0, val1, val2); }
+
+ jclass FindClass (const char * val0)
+ { return p->FindClass (this, val0); }
+
+ jmethodID FromReflectedMethod (jobject obj0)
+ { return p->FromReflectedMethod (this, obj0); }
+
+ jfieldID FromReflectedField (jobject obj0)
+ { return p->FromReflectedField (this, obj0); }
+
+ jobject ToReflectedMethod (jclass cl0, jmethodID meth1, jboolean val2)
+ { return p->ToReflectedMethod (this, cl0, meth1, val2); }
+
+ jclass GetSuperclass (jclass cl0)
+ { return p->GetSuperclass (this, cl0); }
+
+ jboolean IsAssignableFrom (jclass cl0, jclass cl1)
+ { return p->IsAssignableFrom (this, cl0, cl1); }
+
+ jobject ToReflectedField (jclass cl0, jfieldID fld1, jboolean val2)
+ { return p->ToReflectedField (this, cl0, fld1, val2); }
+
+ jint Throw (jthrowable val0)
+ { return p->Throw (this, val0); }
+
+ jint ThrowNew (jclass cl0, const char * val1)
+ { return p->ThrowNew (this, cl0, val1); }
+
+ jthrowable ExceptionOccurred ()
+ { return p->ExceptionOccurred (this); }
+
+ void ExceptionDescribe ()
+ { p->ExceptionDescribe (this); }
+
+ void ExceptionClear ()
+ { p->ExceptionClear (this); }
+
+ void FatalError (const char * val0)
+ { p->FatalError (this, val0); }
+
+ jint PushLocalFrame (jint val0)
+ { return p->PushLocalFrame (this, val0); }
+
+ jobject PopLocalFrame (jobject obj0)
+ { return p->PopLocalFrame (this, obj0); }
+
+ jobject NewGlobalRef (jobject obj0)
+ { return p->NewGlobalRef (this, obj0); }
+
+ void DeleteGlobalRef (jobject obj0)
+ { p->DeleteGlobalRef (this, obj0); }
+
+ void DeleteLocalRef (jobject obj0)
+ { p->DeleteLocalRef (this, obj0); }
+
+ jboolean IsSameObject (jobject obj0, jobject obj1)
+ { return p->IsSameObject (this, obj0, obj1); }
+
+ jobject NewLocalRef (jobject obj0)
+ { return p->NewLocalRef (this, obj0); }
+
+ jint EnsureLocalCapacity (jint val0)
+ { return p->EnsureLocalCapacity (this, val0); }
+
+ jobject AllocObject (jclass cl0)
+ { return p->AllocObject (this, cl0); }
+
+ jobject NewObject (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jobject result = p->NewObjectV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jobject NewObjectV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->NewObjectV (this, cl0, meth1, val2); }
+
+ jobject NewObjectA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->NewObjectA (this, cl0, meth1, val2); }
+
+ jclass GetObjectClass (jobject obj0)
+ { return p->GetObjectClass (this, obj0); }
+
+ jboolean IsInstanceOf (jobject obj0, jclass cl1)
+ { return p->IsInstanceOf (this, obj0, cl1); }
+
+ jmethodID GetMethodID (jclass cl0, const char * val1, const char * val2)
+ { return p->GetMethodID (this, cl0, val1, val2); }
+
+ jobject CallObjectMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jobject result = p->CallObjectMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jobject CallObjectMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallObjectMethodV (this, obj0, meth1, val2); }
+
+ jobject CallObjectMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallObjectMethodA (this, obj0, meth1, val2); }
+
+ jboolean CallBooleanMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jboolean result = p->CallBooleanMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jboolean CallBooleanMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallBooleanMethodV (this, obj0, meth1, val2); }
+
+ jboolean CallBooleanMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallBooleanMethodA (this, obj0, meth1, val2); }
+
+ jbyte CallByteMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jbyte result = p->CallByteMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jbyte CallByteMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallByteMethodV (this, obj0, meth1, val2); }
+
+ jbyte CallByteMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallByteMethodA (this, obj0, meth1, val2); }
+
+ jchar CallCharMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jchar result = p->CallCharMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jchar CallCharMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallCharMethodV (this, obj0, meth1, val2); }
+
+ jchar CallCharMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallCharMethodA (this, obj0, meth1, val2); }
+
+ jshort CallShortMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jshort result = p->CallShortMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jshort CallShortMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallShortMethodV (this, obj0, meth1, val2); }
+
+ jshort CallShortMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallShortMethodA (this, obj0, meth1, val2); }
+
+ jint CallIntMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jint result = p->CallIntMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jint CallIntMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallIntMethodV (this, obj0, meth1, val2); }
+
+ jint CallIntMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallIntMethodA (this, obj0, meth1, val2); }
+
+ jlong CallLongMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jlong result = p->CallLongMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jlong CallLongMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallLongMethodV (this, obj0, meth1, val2); }
+
+ jlong CallLongMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallLongMethodA (this, obj0, meth1, val2); }
+
+ jfloat CallFloatMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jfloat result = p->CallFloatMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jfloat CallFloatMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallFloatMethodV (this, obj0, meth1, val2); }
+
+ jfloat CallFloatMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallFloatMethodA (this, obj0, meth1, val2); }
+
+ jdouble CallDoubleMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jdouble result = p->CallDoubleMethodV (this, obj0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jdouble CallDoubleMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { return p->CallDoubleMethodV (this, obj0, meth1, val2); }
+
+ jdouble CallDoubleMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { return p->CallDoubleMethodA (this, obj0, meth1, val2); }
+
+ void CallVoidMethod (jobject obj0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ p->CallVoidMethodV (this, obj0, meth1, args);
+ va_end (args);
+ }
+
+ void CallVoidMethodV (jobject obj0, jmethodID meth1, va_list val2)
+ { p->CallVoidMethodV (this, obj0, meth1, val2); }
+
+ void CallVoidMethodA (jobject obj0, jmethodID meth1, jvalue * val2)
+ { p->CallVoidMethodA (this, obj0, meth1, val2); }
+
+ jobject CallNonvirtualObjectMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jobject result = p->CallNonvirtualObjectMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jobject CallNonvirtualObjectMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualObjectMethodV (this, obj0, cl1, meth2, val3); }
+
+ jobject CallNonvirtualObjectMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualObjectMethodA (this, obj0, cl1, meth2, val3); }
+
+ jboolean CallNonvirtualBooleanMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jboolean result = p->CallNonvirtualBooleanMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jboolean CallNonvirtualBooleanMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualBooleanMethodV (this, obj0, cl1, meth2, val3); }
+
+ jboolean CallNonvirtualBooleanMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualBooleanMethodA (this, obj0, cl1, meth2, val3); }
+
+ jbyte CallNonvirtualByteMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jbyte result = p->CallNonvirtualByteMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jbyte CallNonvirtualByteMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualByteMethodV (this, obj0, cl1, meth2, val3); }
+
+ jbyte CallNonvirtualByteMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualByteMethodA (this, obj0, cl1, meth2, val3); }
+
+ jchar CallNonvirtualCharMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jchar result = p->CallNonvirtualCharMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jchar CallNonvirtualCharMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualCharMethodV (this, obj0, cl1, meth2, val3); }
+
+ jchar CallNonvirtualCharMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualCharMethodA (this, obj0, cl1, meth2, val3); }
+
+ jshort CallNonvirtualShortMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jshort result = p->CallNonvirtualShortMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jshort CallNonvirtualShortMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualShortMethodV (this, obj0, cl1, meth2, val3); }
+
+ jshort CallNonvirtualShortMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualShortMethodA (this, obj0, cl1, meth2, val3); }
+
+ jint CallNonvirtualIntMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jint result = p->CallNonvirtualIntMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jint CallNonvirtualIntMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualIntMethodV (this, obj0, cl1, meth2, val3); }
+
+ jint CallNonvirtualIntMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualIntMethodA (this, obj0, cl1, meth2, val3); }
+
+ jlong CallNonvirtualLongMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jlong result = p->CallNonvirtualLongMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jlong CallNonvirtualLongMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualLongMethodV (this, obj0, cl1, meth2, val3); }
+
+ jlong CallNonvirtualLongMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualLongMethodA (this, obj0, cl1, meth2, val3); }
+
+ jfloat CallNonvirtualFloatMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jfloat result = p->CallNonvirtualFloatMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jfloat CallNonvirtualFloatMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualFloatMethodV (this, obj0, cl1, meth2, val3); }
+
+ jfloat CallNonvirtualFloatMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualFloatMethodA (this, obj0, cl1, meth2, val3); }
+
+ jdouble CallNonvirtualDoubleMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ jdouble result = p->CallNonvirtualDoubleMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ return result;
+ }
+
+ jdouble CallNonvirtualDoubleMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { return p->CallNonvirtualDoubleMethodV (this, obj0, cl1, meth2, val3); }
+
+ jdouble CallNonvirtualDoubleMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { return p->CallNonvirtualDoubleMethodA (this, obj0, cl1, meth2, val3); }
+
+ void CallNonvirtualVoidMethod (jobject obj0, jclass cl1, jmethodID meth2, ...)
+ {
+ va_list args;
+ va_start (args, meth2);
+ p->CallNonvirtualVoidMethodV (this, obj0, cl1, meth2, args);
+ va_end (args);
+ }
+
+ void CallNonvirtualVoidMethodV (jobject obj0, jclass cl1, jmethodID meth2, va_list val3)
+ { p->CallNonvirtualVoidMethodV (this, obj0, cl1, meth2, val3); }
+
+ void CallNonvirtualVoidMethodA (jobject obj0, jclass cl1, jmethodID meth2, jvalue * val3)
+ { p->CallNonvirtualVoidMethodA (this, obj0, cl1, meth2, val3); }
+
+ jfieldID GetFieldID (jclass cl0, const char * val1, const char * val2)
+ { return p->GetFieldID (this, cl0, val1, val2); }
+
+ jobject GetObjectField (jobject obj0, jfieldID fld1)
+ { return p->GetObjectField (this, obj0, fld1); }
+
+ jboolean GetBooleanField (jobject obj0, jfieldID fld1)
+ { return p->GetBooleanField (this, obj0, fld1); }
+
+ jbyte GetByteField (jobject obj0, jfieldID fld1)
+ { return p->GetByteField (this, obj0, fld1); }
+
+ jchar GetCharField (jobject obj0, jfieldID fld1)
+ { return p->GetCharField (this, obj0, fld1); }
+
+ jshort GetShortField (jobject obj0, jfieldID fld1)
+ { return p->GetShortField (this, obj0, fld1); }
+
+ jint GetIntField (jobject obj0, jfieldID fld1)
+ { return p->GetIntField (this, obj0, fld1); }
+
+ jlong GetLongField (jobject obj0, jfieldID fld1)
+ { return p->GetLongField (this, obj0, fld1); }
+
+ jfloat GetFloatField (jobject obj0, jfieldID fld1)
+ { return p->GetFloatField (this, obj0, fld1); }
+
+ jdouble GetDoubleField (jobject obj0, jfieldID fld1)
+ { return p->GetDoubleField (this, obj0, fld1); }
+
+ void SetObjectField (jobject obj0, jfieldID fld1, jobject obj2)
+ { p->SetObjectField (this, obj0, fld1, obj2); }
+
+ void SetBooleanField (jobject obj0, jfieldID fld1, jboolean val2)
+ { p->SetBooleanField (this, obj0, fld1, val2); }
+
+ void SetByteField (jobject obj0, jfieldID fld1, jbyte val2)
+ { p->SetByteField (this, obj0, fld1, val2); }
+
+ void SetCharField (jobject obj0, jfieldID fld1, jchar val2)
+ { p->SetCharField (this, obj0, fld1, val2); }
+
+ void SetShortField (jobject obj0, jfieldID fld1, jshort val2)
+ { p->SetShortField (this, obj0, fld1, val2); }
+
+ void SetIntField (jobject obj0, jfieldID fld1, jint val2)
+ { p->SetIntField (this, obj0, fld1, val2); }
+
+ void SetLongField (jobject obj0, jfieldID fld1, jlong val2)
+ { p->SetLongField (this, obj0, fld1, val2); }
+
+ void SetFloatField (jobject obj0, jfieldID fld1, jfloat val2)
+ { p->SetFloatField (this, obj0, fld1, val2); }
+
+ void SetDoubleField (jobject obj0, jfieldID fld1, jdouble val2)
+ { p->SetDoubleField (this, obj0, fld1, val2); }
+
+ jmethodID GetStaticMethodID (jclass cl0, const char * val1, const char * val2)
+ { return p->GetStaticMethodID (this, cl0, val1, val2); }
+
+ jobject CallStaticObjectMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jobject result = p->CallStaticObjectMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jobject CallStaticObjectMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticObjectMethodV (this, cl0, meth1, val2); }
+
+ jobject CallStaticObjectMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticObjectMethodA (this, cl0, meth1, val2); }
+
+ jboolean CallStaticBooleanMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jboolean result = p->CallStaticBooleanMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jboolean CallStaticBooleanMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticBooleanMethodV (this, cl0, meth1, val2); }
+
+ jboolean CallStaticBooleanMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticBooleanMethodA (this, cl0, meth1, val2); }
+
+ jbyte CallStaticByteMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jbyte result = p->CallStaticByteMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jbyte CallStaticByteMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticByteMethodV (this, cl0, meth1, val2); }
+
+ jbyte CallStaticByteMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticByteMethodA (this, cl0, meth1, val2); }
+
+ jchar CallStaticCharMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jchar result = p->CallStaticCharMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jchar CallStaticCharMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticCharMethodV (this, cl0, meth1, val2); }
+
+ jchar CallStaticCharMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticCharMethodA (this, cl0, meth1, val2); }
+
+ jshort CallStaticShortMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jshort result = p->CallStaticShortMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jshort CallStaticShortMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticShortMethodV (this, cl0, meth1, val2); }
+
+ jshort CallStaticShortMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticShortMethodA (this, cl0, meth1, val2); }
+
+ jint CallStaticIntMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jint result = p->CallStaticIntMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jint CallStaticIntMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticIntMethodV (this, cl0, meth1, val2); }
+
+ jint CallStaticIntMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticIntMethodA (this, cl0, meth1, val2); }
+
+ jlong CallStaticLongMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jlong result = p->CallStaticLongMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jlong CallStaticLongMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticLongMethodV (this, cl0, meth1, val2); }
+
+ jlong CallStaticLongMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticLongMethodA (this, cl0, meth1, val2); }
+
+ jfloat CallStaticFloatMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jfloat result = p->CallStaticFloatMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jfloat CallStaticFloatMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticFloatMethodV (this, cl0, meth1, val2); }
+
+ jfloat CallStaticFloatMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticFloatMethodA (this, cl0, meth1, val2); }
+
+ jdouble CallStaticDoubleMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ jdouble result = p->CallStaticDoubleMethodV (this, cl0, meth1, args);
+ va_end (args);
+ return result;
+ }
+
+ jdouble CallStaticDoubleMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { return p->CallStaticDoubleMethodV (this, cl0, meth1, val2); }
+
+ jdouble CallStaticDoubleMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { return p->CallStaticDoubleMethodA (this, cl0, meth1, val2); }
+
+ void CallStaticVoidMethod (jclass cl0, jmethodID meth1, ...)
+ {
+ va_list args;
+ va_start (args, meth1);
+ p->CallStaticVoidMethodV (this, cl0, meth1, args);
+ va_end (args);
+ }
+
+ void CallStaticVoidMethodV (jclass cl0, jmethodID meth1, va_list val2)
+ { p->CallStaticVoidMethodV (this, cl0, meth1, val2); }
+
+ void CallStaticVoidMethodA (jclass cl0, jmethodID meth1, jvalue * val2)
+ { p->CallStaticVoidMethodA (this, cl0, meth1, val2); }
+
+ jfieldID GetStaticFieldID (jclass cl0, const char * val1, const char * val2)
+ { return p->GetStaticFieldID (this, cl0, val1, val2); }
+
+ jobject GetStaticObjectField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticObjectField (this, cl0, fld1); }
+
+ jboolean GetStaticBooleanField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticBooleanField (this, cl0, fld1); }
+
+ jbyte GetStaticByteField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticByteField (this, cl0, fld1); }
+
+ jchar GetStaticCharField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticCharField (this, cl0, fld1); }
+
+ jshort GetStaticShortField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticShortField (this, cl0, fld1); }
+
+ jint GetStaticIntField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticIntField (this, cl0, fld1); }
+
+ jlong GetStaticLongField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticLongField (this, cl0, fld1); }
+
+ jfloat GetStaticFloatField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticFloatField (this, cl0, fld1); }
+
+ jdouble GetStaticDoubleField (jclass cl0, jfieldID fld1)
+ { return p->GetStaticDoubleField (this, cl0, fld1); }
+
+ void SetStaticObjectField (jclass cl0, jfieldID fld1, jobject obj2)
+ { p->SetStaticObjectField (this, cl0, fld1, obj2); }
+
+ void SetStaticBooleanField (jclass cl0, jfieldID fld1, jboolean val2)
+ { p->SetStaticBooleanField (this, cl0, fld1, val2); }
+
+ void SetStaticByteField (jclass cl0, jfieldID fld1, jbyte val2)
+ { p->SetStaticByteField (this, cl0, fld1, val2); }
+
+ void SetStaticCharField (jclass cl0, jfieldID fld1, jchar val2)
+ { p->SetStaticCharField (this, cl0, fld1, val2); }
+
+ void SetStaticShortField (jclass cl0, jfieldID fld1, jshort val2)
+ { p->SetStaticShortField (this, cl0, fld1, val2); }
+
+ void SetStaticIntField (jclass cl0, jfieldID fld1, jint val2)
+ { p->SetStaticIntField (this, cl0, fld1, val2); }
+
+ void SetStaticLongField (jclass cl0, jfieldID fld1, jlong val2)
+ { p->SetStaticLongField (this, cl0, fld1, val2); }
+
+ void SetStaticFloatField (jclass cl0, jfieldID fld1, jfloat val2)
+ { p->SetStaticFloatField (this, cl0, fld1, val2); }
+
+ void SetStaticDoubleField (jclass cl0, jfieldID fld1, jdouble val2)
+ { p->SetStaticDoubleField (this, cl0, fld1, val2); }
+
+ jstring NewString (const jchar * val0, jsize val1)
+ { return p->NewString (this, val0, val1); }
+
+ jint GetStringLength (jstring val0)
+ { return p->GetStringLength (this, val0); }
+
+ const jchar * GetStringChars (jstring val0, jboolean * val1)
+ { return p->GetStringChars (this, val0, val1); }
+
+ void ReleaseStringChars (jstring val0, const jchar * val1)
+ { p->ReleaseStringChars (this, val0, val1); }
+
+ jstring NewStringUTF (const char * val0)
+ { return p->NewStringUTF (this, val0); }
+
+ jsize GetStringUTFLength (jstring val0)
+ { return p->GetStringUTFLength (this, val0); }
+
+ const char * GetStringUTFChars (jstring val0, jboolean * val1)
+ { return p->GetStringUTFChars (this, val0, val1); }
+
+ void ReleaseStringUTFChars (jstring val0, const char * val1)
+ { p->ReleaseStringUTFChars (this, val0, val1); }
+
+ jsize GetArrayLength (jarray val0)
+ { return p->GetArrayLength (this, val0); }
+
+ jobjectArray NewObjectArray (jsize val0, jclass cl1, jobject obj2)
+ { return p->NewObjectArray (this, val0, cl1, obj2); }
+
+ jobject GetObjectArrayElement (jobjectArray val0, jsize val1)
+ { return p->GetObjectArrayElement (this, val0, val1); }
+
+ void SetObjectArrayElement (jobjectArray val0, jsize val1, jobject obj2)
+ { p->SetObjectArrayElement (this, val0, val1, obj2); }
+
+ jbooleanArray NewBooleanArray (jsize val0)
+ { return p->NewBooleanArray (this, val0); }
+
+ jbyteArray NewByteArray (jsize val0)
+ { return p->NewByteArray (this, val0); }
+
+ jcharArray NewCharArray (jsize val0)
+ { return p->NewCharArray (this, val0); }
+
+ jshortArray NewShortArray (jsize val0)
+ { return p->NewShortArray (this, val0); }
+
+ jintArray NewIntArray (jsize val0)
+ { return p->NewIntArray (this, val0); }
+
+ jlongArray NewLongArray (jsize val0)
+ { return p->NewLongArray (this, val0); }
+
+ jfloatArray NewFloatArray (jsize val0)
+ { return p->NewFloatArray (this, val0); }
+
+ jdoubleArray NewDoubleArray (jsize val0)
+ { return p->NewDoubleArray (this, val0); }
+
+ jboolean * GetBooleanArrayElements (jbooleanArray val0, jboolean * val1)
+ { return p->GetBooleanArrayElements (this, val0, val1); }
+
+ jbyte * GetByteArrayElements (jbyteArray val0, jboolean * val1)
+ { return p->GetByteArrayElements (this, val0, val1); }
+
+ jchar * GetCharArrayElements (jcharArray val0, jboolean * val1)
+ { return p->GetCharArrayElements (this, val0, val1); }
+
+ jshort * GetShortArrayElements (jshortArray val0, jboolean * val1)
+ { return p->GetShortArrayElements (this, val0, val1); }
+
+ jint * GetIntArrayElements (jintArray val0, jboolean * val1)
+ { return p->GetIntArrayElements (this, val0, val1); }
+
+ jlong * GetLongArrayElements (jlongArray val0, jboolean * val1)
+ { return p->GetLongArrayElements (this, val0, val1); }
+
+ jfloat * GetFloatArrayElements (jfloatArray val0, jboolean * val1)
+ { return p->GetFloatArrayElements (this, val0, val1); }
+
+ jdouble * GetDoubleArrayElements (jdoubleArray val0, jboolean * val1)
+ { return p->GetDoubleArrayElements (this, val0, val1); }
+
+ void ReleaseBooleanArrayElements (jbooleanArray val0, jboolean * val1, jint val2)
+ { p->ReleaseBooleanArrayElements (this, val0, val1, val2); }
+
+ void ReleaseByteArrayElements (jbyteArray val0, jbyte * val1, jint val2)
+ { p->ReleaseByteArrayElements (this, val0, val1, val2); }
+
+ void ReleaseCharArrayElements (jcharArray val0, jchar * val1, jint val2)
+ { p->ReleaseCharArrayElements (this, val0, val1, val2); }
+
+ void ReleaseShortArrayElements (jshortArray val0, jshort * val1, jint val2)
+ { p->ReleaseShortArrayElements (this, val0, val1, val2); }
+
+ void ReleaseIntArrayElements (jintArray val0, jint * val1, jint val2)
+ { p->ReleaseIntArrayElements (this, val0, val1, val2); }
+
+ void ReleaseLongArrayElements (jlongArray val0, jlong * val1, jint val2)
+ { p->ReleaseLongArrayElements (this, val0, val1, val2); }
+
+ void ReleaseFloatArrayElements (jfloatArray val0, jfloat * val1, jint val2)
+ { p->ReleaseFloatArrayElements (this, val0, val1, val2); }
+
+ void ReleaseDoubleArrayElements (jdoubleArray val0, jdouble * val1, jint val2)
+ { p->ReleaseDoubleArrayElements (this, val0, val1, val2); }
+
+ void GetBooleanArrayRegion (jbooleanArray val0, jsize val1, jsize val2, jboolean * val3)
+ { p->GetBooleanArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetByteArrayRegion (jbyteArray val0, jsize val1, jsize val2, jbyte * val3)
+ { p->GetByteArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetCharArrayRegion (jcharArray val0, jsize val1, jsize val2, jchar * val3)
+ { p->GetCharArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetShortArrayRegion (jshortArray val0, jsize val1, jsize val2, jshort * val3)
+ { p->GetShortArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetIntArrayRegion (jintArray val0, jsize val1, jsize val2, jint * val3)
+ { p->GetIntArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetLongArrayRegion (jlongArray val0, jsize val1, jsize val2, jlong * val3)
+ { p->GetLongArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetFloatArrayRegion (jfloatArray val0, jsize val1, jsize val2, jfloat * val3)
+ { p->GetFloatArrayRegion (this, val0, val1, val2, val3); }
+
+ void GetDoubleArrayRegion (jdoubleArray val0, jsize val1, jsize val2, jdouble * val3)
+ { p->GetDoubleArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetBooleanArrayRegion (jbooleanArray val0, jsize val1, jsize val2, jboolean * val3)
+ { p->SetBooleanArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetByteArrayRegion (jbyteArray val0, jsize val1, jsize val2, jbyte * val3)
+ { p->SetByteArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetCharArrayRegion (jcharArray val0, jsize val1, jsize val2, jchar * val3)
+ { p->SetCharArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetShortArrayRegion (jshortArray val0, jsize val1, jsize val2, jshort * val3)
+ { p->SetShortArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetIntArrayRegion (jintArray val0, jsize val1, jsize val2, jint * val3)
+ { p->SetIntArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetLongArrayRegion (jlongArray val0, jsize val1, jsize val2, jlong * val3)
+ { p->SetLongArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetFloatArrayRegion (jfloatArray val0, jsize val1, jsize val2, jfloat * val3)
+ { p->SetFloatArrayRegion (this, val0, val1, val2, val3); }
+
+ void SetDoubleArrayRegion (jdoubleArray val0, jsize val1, jsize val2, jdouble * val3)
+ { p->SetDoubleArrayRegion (this, val0, val1, val2, val3); }
+
+ jint RegisterNatives (jclass cl0, const JNINativeMethod * val1, jint val2)
+ { return p->RegisterNatives (this, cl0, val1, val2); }
+
+ jint UnregisterNatives (jclass cl0)
+ { return p->UnregisterNatives (this, cl0); }
+
+ jint MonitorEnter (jobject obj0)
+ { return p->MonitorEnter (this, obj0); }
+
+ jint MonitorExit (jobject obj0)
+ { return p->MonitorExit (this, obj0); }
+
+ jint GetJavaVM (JavaVM ** val0)
+ { return p->GetJavaVM (this, val0); }
+
+ void GetStringRegion (jstring val0, jsize val1, jsize val2, jchar * val3)
+ { p->GetStringRegion (this, val0, val1, val2, val3); }
+
+ void GetStringUTFRegion (jstring val0, jsize val1, jsize val2, char * val3)
+ { p->GetStringUTFRegion (this, val0, val1, val2, val3); }
+
+ void * GetPrimitiveArrayCritical (jarray val0, jboolean * val1)
+ { return p->GetPrimitiveArrayCritical (this, val0, val1); }
+
+ void ReleasePrimitiveArrayCritical (jarray val0, void * val1, jint val2)
+ { p->ReleasePrimitiveArrayCritical (this, val0, val1, val2); }
+
+ const jchar * GetStringCritical (jstring val0, jboolean * val1)
+ { return p->GetStringCritical (this, val0, val1); }
+
+ void ReleaseStringCritical (jstring val0, const jchar * val1)
+ { p->ReleaseStringCritical (this, val0, val1); }
+
+ jweak NewWeakGlobalRef (jobject obj0)
+ { return p->NewWeakGlobalRef (this, obj0); }
+
+ void DeleteWeakGlobalRef (jweak val0)
+ { p->DeleteWeakGlobalRef (this, val0); }
+
+ jboolean ExceptionCheck ()
+ { return p->ExceptionCheck (this); }
+
+ jobject NewDirectByteBuffer (void *addr, jlong capacity)
+ { return p->NewDirectByteBuffer (this, addr, capacity); }
+
+ void *GetDirectBufferAddress (jobject buf)
+ { return p->GetDirectBufferAddress (this, buf); }
+
+ jlong GetDirectBufferCapacity (jobject buf)
+ { return p->GetDirectBufferCapacity (this, buf); }
+};
+
+#endif /* __cplusplus */
+
+/*
+ * Invocation API.
+ */
+
+struct JNIInvokeInterface
+{
+ void *reserved0;
+ void *reserved1;
+ void *reserved2;
+
+ jint (JNICALL *DestroyJavaVM) (JavaVM *);
+ jint (JNICALL *AttachCurrentThread) (JavaVM *, void **, void *);
+ jint (JNICALL *DetachCurrentThread) (JavaVM *);
+ jint (JNICALL *GetEnv) (JavaVM *, void **, jint);
+ jint (JNICALL *AttachCurrentThreadAsDaemon) (JavaVM *, void **, void *);
+};
+
+#ifdef __cplusplus
+
+class _Jv_JavaVM
+{
+public:
+ const struct JNIInvokeInterface *functions;
+
+ jint DestroyJavaVM ()
+ { return functions->DestroyJavaVM (this); }
+
+ jint AttachCurrentThread (void **penv, void *args)
+ { return functions->AttachCurrentThread (this, penv, args); }
+
+ jint DetachCurrentThread ()
+ { return functions->DetachCurrentThread (this); }
+
+ jint GetEnv (void **penv, jint version)
+ { return functions->GetEnv (this, penv, version); }
+
+ jint AttachCurrentThreadAsDaemon (void **penv, void *args)
+ { return functions->AttachCurrentThreadAsDaemon (this, penv, args); }
+};
+
+#endif /* __cplusplus */
+
+typedef struct JavaVMAttachArgs
+{
+ jint version; /* Must be JNI_VERSION_1_2. */
+ char *name; /* The name of the thread (or NULL). */
+ jobject group; /* Global ref of a ThreadGroup object
+ (or NULL). */
+} JavaVMAttachArgs;
+
+typedef struct JavaVMOption
+{
+ char *optionString;
+ void *extraInfo;
+} JavaVMOption;
+
+typedef struct JavaVMInitArgs
+{
+ /* Must be JNI_VERSION_1_2. */
+ jint version;
+
+ /* Number of options. */
+ jint nOptions;
+
+ /* Options to the VM. */
+ JavaVMOption *options;
+
+ /* Whether we should ignore unrecognized options. */
+ jboolean ignoreUnrecognized;
+} JavaVMInitArgs;
+
+typedef struct JDK1_1InitArgs
+{
+ /* VM version. Should be JNI_VERSION_1_1. Note that before JDK
+ 1.1.2, this field was named 'reserved0'. (I don't know what the
+ current 'reserved0' field was named then.) */
+ jint version;
+
+ /* A null-terminated array of environment strings, each of the form
+ "KEY=VALUE". This is used to set system properties. Note that
+ before JDK 1.1.2, this field was named 'reserved1'. */
+ char **properties;
+
+ jint checkSource;
+ jint nativeStackSize;
+ jint javaStackSize;
+ jint minHeapSize;
+ jint maxHeapSize;
+ jint verifyMode;
+ const char *classpath;
+
+ jint (JNICALL *vfprintf) (FILE *file, const char *fmt, va_list args);
+ void (JNICALL *exit) (jint value);
+ void (JNICALL *abort) (void);
+
+ jint enableClassGC;
+ jint enableVerboseGC;
+ jint disableAsyncGC;
+
+ jint reserved0;
+ jint reserved1;
+ jint reserved2;
+} JDK1_1InitArgs;
+
+typedef struct JDK1_1AttachArgs
+{
+ /* Dummy field since C cannot have empty structs. The name and type
+ are chosen to comply with the spec. */
+ void *__padding;
+} JDK1_1AttachArgs;
+
+
+/* Keep c-font-lock-extra-types in alphabetical order. */
+/* Local Variables: */
+/* c-font-lock-extra-types: ("\\sw+_t"
+ "JNIEnv" "JNINativeMethod" "JavaVM" "JavaVMOption" "jarray"
+ "jboolean" "jbooleanArray" "jbyte" "jbyteArray" "jchar" "jcharArray"
+ "jclass" "jdouble" "jdoubleArray" "jfieldID" "jfloat" "jfloatArray"
+ "jint" "jintArray" "jlong" "jlongArray" "jmethodID" "jobject" "jstring" "jthrowable"
+ "jvalue" "jweak") */
+/* End: */
+
+#endif /* _CLASSPATH_JNI_H */
Added: llvm-gcc-4.2/trunk/libjava/classpath/include/jni_md-x86-linux-gnu.h
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/libjava/classpath/include/jni_md-x86-linux-gnu.h?rev=43913&view=auto
==============================================================================
--- llvm-gcc-4.2/trunk/libjava/classpath/include/jni_md-x86-linux-gnu.h (added)
+++ llvm-gcc-4.2/trunk/libjava/classpath/include/jni_md-x86-linux-gnu.h Thu Nov 8 16:56:19 2007
@@ -0,0 +1,45 @@
+/* jni_md.h
+ Copyright (C) 2001, 2005 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+As a special exception, if you link this library with other files to
+produce an executable, this library does not by itself cause the
+resulting executable to be covered by the GNU General Public License.
+This exception does not however invalidate any other reasons why the
+executable file might be covered by the GNU General Public License. */
+
+#ifndef __CLASSPATH_JNI_MD_H__
+#define __CLASSPATH_JNI_MD_H__
+
+/* Define some defaults */
+#define JNICALL
+#define JNIEXPORT
+#define JNIIMPORT
+
+typedef unsigned char jboolean;
+typedef signed char jbyte;
+typedef unsigned short jchar;
+typedef short jshort;
+typedef int jint;
+typedef long long jlong;
+typedef float jfloat;
+typedef double jdouble;
+typedef jint jsize;
+
+#endif /* __CLASSPATH_JNI_MD_H__ */
More information about the llvm-commits
mailing list