2003-02-12 Michael Koch <konqueror@gmx.de>
* java/nio/ByteBuffer.java (allocate): Implemented. (wrap): Implemented. * java/nio/CharBuffer.java: Some documentation added and reworked. (endian): Removed. (allocate): Implemented. (wrap): Implemented. (array): Throw exceptions. (arrayOffset): Throw exceptions. (toString): Implemented. (length): Implemented. (put): Implemented. (charAt): Implemented. From-SVN: r62760
This commit is contained in:
committed by
Michael Koch
parent
ceda50e9d5
commit
ad2e63d5df
@@ -37,6 +37,8 @@ exception statement from your version. */
|
||||
|
||||
package java.nio;
|
||||
|
||||
import gnu.java.nio.ByteBufferImpl;
|
||||
|
||||
/**
|
||||
* @since 1.4
|
||||
*/
|
||||
@@ -58,7 +60,7 @@ public abstract class ByteBuffer extends Buffer implements Comparable
|
||||
*/
|
||||
public static ByteBuffer allocate (int capacity)
|
||||
{
|
||||
return null;
|
||||
return new ByteBufferImpl (capacity, 0, capacity);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -69,7 +71,7 @@ public abstract class ByteBuffer extends Buffer implements Comparable
|
||||
*/
|
||||
final public static ByteBuffer wrap (byte[] array, int offset, int length)
|
||||
{
|
||||
return null;
|
||||
return new ByteBufferImpl (array, offset, length);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user