net.sourceforge.neurosdbm.db
Class NIOFile

java.lang.Object
  extended bynet.sourceforge.neurosdbm.db.NIOFile

public class NIOFile
extends java.lang.Object


Field Summary
private  java.nio.ByteBuffer buffer
           
private static int BUFFER_SIZE
           
private  java.nio.channels.WritableByteChannel channel
           
private  java.lang.String filename
           
private  int numberOfBuffers
           
 
Constructor Summary
NIOFile(java.lang.String filename)
           
 
Method Summary
 void append(byte value)
           
 void append(byte[] bytes)
           
 void append(char value)
           
 void append(int value)
           
 void append(java.lang.String str)
           
 void append(Word word)
           
 void append(WordPointer ptr)
           
private  void newBuffer()
           
 int position()
           
 void write()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

filename

private java.lang.String filename

BUFFER_SIZE

private static final int BUFFER_SIZE
See Also:
Constant Field Values

buffer

private java.nio.ByteBuffer buffer

channel

private java.nio.channels.WritableByteChannel channel

numberOfBuffers

private int numberOfBuffers
Constructor Detail

NIOFile

public NIOFile(java.lang.String filename)
        throws java.io.FileNotFoundException,
               java.io.IOException
Method Detail

append

public void append(byte value)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(int value)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(char value)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(byte[] bytes)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(Word word)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(WordPointer ptr)
            throws java.io.IOException
Throws:
java.io.IOException

append

public void append(java.lang.String str)
            throws java.io.IOException
Throws:
java.io.IOException

newBuffer

private void newBuffer()
                throws java.io.IOException
Throws:
java.io.IOException

write

public void write()
           throws java.io.IOException
Throws:
java.io.IOException

position

public int position()


Copyright © 2004 NeurosDBM Dev Team All Rights Reserved.