aboutsummaryrefslogtreecommitdiff
path: root/libjava/classpath/java/nio/DoubleBuffer.java
diff options
context:
space:
mode:
Diffstat (limited to 'libjava/classpath/java/nio/DoubleBuffer.java')
-rw-r--r--libjava/classpath/java/nio/DoubleBuffer.java52
1 files changed, 26 insertions, 26 deletions
diff --git a/libjava/classpath/java/nio/DoubleBuffer.java b/libjava/classpath/java/nio/DoubleBuffer.java
index 1a51f18..c17058c 100644
--- a/libjava/classpath/java/nio/DoubleBuffer.java
+++ b/libjava/classpath/java/nio/DoubleBuffer.java
@@ -1,4 +1,4 @@
-/* DoubleBuffer.java --
+/* DoubleBuffer.java --
Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of GNU Classpath.
@@ -51,7 +51,7 @@ public abstract class DoubleBuffer extends Buffer
final double[] backing_buffer;
DoubleBuffer (int capacity, int limit, int position, int mark,
- RawData address, double[] backing_buffer, int array_offset)
+ RawData address, double[] backing_buffer, int array_offset)
{
super (capacity, limit, position, mark, address);
this.backing_buffer = backing_buffer;
@@ -86,11 +86,11 @@ public abstract class DoubleBuffer extends Buffer
{
return wrap (array, 0, array.length);
}
-
+
/**
* This method transfers <code>double</code>s from this buffer into the given
* destination array. Before the transfer, it checks if there are fewer than
- * length <code>double</code>s remaining in this buffer.
+ * length <code>double</code>s remaining in this buffer.
*
* @param dst The destination array
* @param offset The offset within the array of the first <code>double</code>
@@ -169,7 +169,7 @@ public abstract class DoubleBuffer extends Buffer
* must be non-negative and no larger than src.length.
* @param length The number of bytes to be read from the given array;
* must be non-negative and no larger than src.length - offset.
- *
+ *
* @exception BufferOverflowException If there is insufficient space in this
* buffer for the remaining <code>double</code>s in the source array.
* @exception IndexOutOfBoundsException If the preconditions on the offset
@@ -192,7 +192,7 @@ public abstract class DoubleBuffer extends Buffer
* into the buffer.
*
* @param src The array to copy into the buffer.
- *
+ *
* @exception BufferOverflowException If there is insufficient space in this
* buffer for the remaining <code>double</code>s in the source array.
* @exception ReadOnlyBufferException If this buffer is read-only.
@@ -225,7 +225,7 @@ public abstract class DoubleBuffer extends Buffer
throw new UnsupportedOperationException ();
checkIfReadOnly();
-
+
return backing_buffer;
}
@@ -242,7 +242,7 @@ public abstract class DoubleBuffer extends Buffer
throw new UnsupportedOperationException ();
checkIfReadOnly();
-
+
return array_offset;
}
@@ -254,7 +254,7 @@ public abstract class DoubleBuffer extends Buffer
* <code>s[position()] + 31 + (s[position()+1] + 30)*31**1 + ... +
* (s[limit()-1]+30)*31**(limit()-1)</code>.
* Where s is the buffer data, in Double.doubleToLongBits() form
- * Note that the hashcode is dependent on buffer content,
+ * Note that the hashcode is dependent on buffer content,
* and therefore is not useful if the buffer content may change.
*
* @return the hash code (casted to int)
@@ -265,8 +265,8 @@ public abstract class DoubleBuffer extends Buffer
long multiplier = 1;
for (int i = position() + 1; i < limit(); ++i)
{
- multiplier *= 31;
- hashCode += (Double.doubleToLongBits(get(i)) + 30)*multiplier;
+ multiplier *= 31;
+ hashCode += (Double.doubleToLongBits(get(i)) + 30)*multiplier;
}
return ((int)hashCode);
}
@@ -295,21 +295,21 @@ public abstract class DoubleBuffer extends Buffer
int num = Math.min(remaining(), other.remaining());
int pos_this = position();
int pos_other = other.position();
-
+
for (int count = 0; count < num; count++)
{
- double a = get(pos_this++);
- double b = other.get(pos_other++);
-
- if (a == b)
- continue;
-
- if (a < b)
- return -1;
-
- return 1;
+ double a = get(pos_this++);
+ double b = other.get(pos_other++);
+
+ if (a == b)
+ continue;
+
+ if (a < b)
+ return -1;
+
+ return 1;
}
-
+
return remaining() - other.remaining();
}
@@ -331,7 +331,7 @@ public abstract class DoubleBuffer extends Buffer
* Writes the <code>double</code> at this buffer's current position,
* and then increments the position.
*
- * @exception BufferOverflowException If there no remaining
+ * @exception BufferOverflowException If there no remaining
* <code>double</code>s in this buffer.
* @exception ReadOnlyBufferException If this buffer is read-only.
*/
@@ -344,7 +344,7 @@ public abstract class DoubleBuffer extends Buffer
* than the buffer's limit.
*/
public abstract double get (int index);
-
+
/**
* Absolute put method.
*
@@ -356,7 +356,7 @@ public abstract class DoubleBuffer extends Buffer
/**
* Compacts this buffer.
- *
+ *
* @exception ReadOnlyBufferException If this buffer is read-only.
*/
public abstract DoubleBuffer compact ();