Imported GNU Classpath 0.92

2006-08-14  Mark Wielaard  <mark@klomp.org>

       Imported GNU Classpath 0.92
       * HACKING: Add more importing hints. Update automake version
       requirement.

       * configure.ac (gconf-peer): New enable AC argument.
       Add --disable-gconf-peer and --enable-default-preferences-peer
       to classpath configure when gconf is disabled.
       * scripts/makemake.tcl: Set gnu/java/util/prefs/gconf and
       gnu/java/awt/dnd/peer/gtk to bc. Classify
       gnu/java/security/Configuration.java as generated source file.

       * gnu/java/lang/management/VMGarbageCollectorMXBeanImpl.java,
       gnu/java/lang/management/VMMemoryPoolMXBeanImpl.java,
       gnu/java/lang/management/VMClassLoadingMXBeanImpl.java,
       gnu/java/lang/management/VMRuntimeMXBeanImpl.java,
       gnu/java/lang/management/VMMemoryManagerMXBeanImpl.java,
       gnu/java/lang/management/VMThreadMXBeanImpl.java,
       gnu/java/lang/management/VMMemoryMXBeanImpl.java,
       gnu/java/lang/management/VMCompilationMXBeanImpl.java: New VM stub
       classes.
       * java/lang/management/VMManagementFactory.java: Likewise.
       * java/net/VMURLConnection.java: Likewise.
       * gnu/java/nio/VMChannel.java: Likewise.

       * java/lang/Thread.java (getState): Add stub implementation.
       * java/lang/Class.java (isEnum): Likewise.
       * java/lang/Class.h (isEnum): Likewise.

       * gnu/awt/xlib/XToolkit.java (getClasspathTextLayoutPeer): Removed.

       * javax/naming/spi/NamingManager.java: New override for StackWalker
       functionality.

       * configure, sources.am, Makefile.in, gcj/Makefile.in,
       include/Makefile.in, testsuite/Makefile.in: Regenerated.

From-SVN: r116139
This commit is contained in:
Mark Wielaard 2006-08-14 23:12:35 +00:00
parent abab460491
commit ac1ed908de
1294 changed files with 99479 additions and 35933 deletions

View file

@ -44,24 +44,18 @@ import java.util.LinkedList;
/**
* A monotonic sequence of integers in the finite field 2<sup>32</sup>.
*/
public final class Sequence extends AbstractList
public final class Sequence
extends AbstractList
{
// Field.
// ------------------------------------------------------------------------
private final Integer[] sequence;
// Constructor.
// ------------------------------------------------------------------------
/**
* Create a sequence of integers from 0 to <i>end</i>, with an increment
* of 1. If <i>end</i> is less than 0, then the sequence will wrap around
* through all positive integers then negative integers until the end
* value is reached. Naturally, this will result in an enormous object,
* so don't do this.
*
* Create a sequence of integers from 0 to <i>end</i>, with an increment of
* 1. If <i>end</i> is less than 0, then the sequence will wrap around
* through all positive integers then negative integers until the end value is
* reached. Naturally, this will result in an enormous object, so don't do
* this.
*
* @param end The ending value.
*/
public Sequence(int end)
@ -71,10 +65,10 @@ public final class Sequence extends AbstractList
/**
* Create a sequence of integers from <i>start</i> to <i>end</i>, with an
* increment of 1. If <i>end</i> is less than <i>start</i>, then the sequence
* will wrap around until the end value is reached. Naturally, this will
* result in an enormous object, so don't do this.
*
* increment of 1. If <i>end</i> is less than <i>start</i>, then the
* sequence will wrap around until the end value is reached. Naturally, this
* will result in an enormous object, so don't do this.
*
* @param start The starting value.
* @param end The ending value.
*/
@ -88,13 +82,13 @@ public final class Sequence extends AbstractList
* increment of <i>span</i>. If <i>end</i> is less than <i>start</i>, then
* the sequence will wrap around until the end value is reached. Naturally,
* this will result in an enormous object, so don't do this.
*
* <p><i>span</i> can be negative, resulting in a decresing sequence.
*
* <p>If <i>span</i> is 0, then the sequence will contain {<i>start</i>,
* <p>
* <i>span</i> can be negative, resulting in a decresing sequence.
* <p>
* If <i>span</i> is 0, then the sequence will contain {<i>start</i>,
* <i>end</i>} if <i>start</i> != <i>end</i>, or just the singleton
* <i>start</i> if <i>start</i> == <i>end</i>.
*
*
* @param start The starting value.
* @param end The ending value.
* @param span The increment value.
@ -104,36 +98,26 @@ public final class Sequence extends AbstractList
if (span == 0)
{
if (start != end)
{
sequence = new Integer[] { new Integer(start), new Integer(end) };
}
sequence = new Integer[] { Integer.valueOf(start),
Integer.valueOf(end) };
else
{
sequence = new Integer[] { new Integer(start) };
}
sequence = new Integer[] { Integer.valueOf(start) };
}
else
{
LinkedList l = new LinkedList();
for (int i = start; i != end; i += span)
{
l.add(new Integer(i));
}
l.add(new Integer(end));
l.add(Integer.valueOf(i));
l.add(Integer.valueOf(end));
sequence = (Integer[]) l.toArray(new Integer[l.size()]);
}
}
// Instance methods.
// ------------------------------------------------------------------------
public Object get(int index)
{
if (index < 0 || index >= size())
{
throw new IndexOutOfBoundsException("index=" + index + ", size="
+ size());
}
throw new IndexOutOfBoundsException("index=" + index + ", size=" + size());
return sequence[index];
}