com.sentilla.platform.tmote
Class FlashFile
java.lang.Object
com.sentilla.platform.tmote.Action
com.sentilla.platform.tmote.FlashFile
- All Implemented Interfaces:
- com.sentilla.io.DataInput, com.sentilla.io.DataOutput, com.sentilla.io.DataRandomAccess, com.sentilla.io.Input, com.sentilla.io.InputStream, com.sentilla.io.ObjectInput, com.sentilla.io.ObjectOutput, com.sentilla.io.ObjectRandomAccess, com.sentilla.io.Output, com.sentilla.io.RandomAccessFile, Action
- Direct Known Subclasses:
- FileMapEntry
public class FlashFile
- extends Action
- implements com.sentilla.io.RandomAccessFile, com.sentilla.io.InputStream
Private: for Sentilla internal use only.
Field Summary |
protected com.sentilla.io.ByteBuffer |
data
|
protected byte |
op
|
protected boolean |
overwrite
|
op
protected byte op
overwrite
protected boolean overwrite
data
protected com.sentilla.io.ByteBuffer data
FlashFile
public FlashFile()
FlashFile
protected FlashFile(FlashFile dupe)
open
public void open(int filename)
create
public void create(int filename)
create
public void create(int filename,
int preallocated_size)
remove
public void remove(int filename)
getName
public int getName()
getOffset
public int getOffset()
- Specified by:
getOffset
in interface com.sentilla.io.DataRandomAccess
length
public int length()
- Specified by:
length
in interface com.sentilla.io.DataRandomAccess
available
public int available()
- Specified by:
available
in interface com.sentilla.io.InputStream
seek
public void seek(int offset)
- Specified by:
seek
in interface com.sentilla.io.DataRandomAccess
readBoolean
public boolean readBoolean()
throws com.sentilla.io.IORuntimeException
- Specified by:
readBoolean
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readByte
public byte readByte()
throws com.sentilla.io.IORuntimeException
- Specified by:
readByte
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readUnsignedByte
public int readUnsignedByte()
throws com.sentilla.io.IORuntimeException
- Specified by:
readUnsignedByte
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readShort
public short readShort()
throws com.sentilla.io.IORuntimeException
- Specified by:
readShort
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readChar
public char readChar()
throws com.sentilla.io.IORuntimeException
- Specified by:
readChar
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readInt
public int readInt()
throws com.sentilla.io.IORuntimeException
- Specified by:
readInt
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readLong
public long readLong()
throws com.sentilla.io.IORuntimeException
- Specified by:
readLong
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readFloat
public float readFloat()
throws com.sentilla.io.IORuntimeException
- Specified by:
readFloat
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readDouble
public double readDouble()
throws com.sentilla.io.IORuntimeException
- Specified by:
readDouble
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readUTF
public String readUTF()
throws com.sentilla.io.IORuntimeException
- Specified by:
readUTF
in interface com.sentilla.io.DataInput
- Throws:
com.sentilla.io.IORuntimeException
readObject
public Object readObject()
throws com.sentilla.io.IORuntimeException
- Specified by:
readObject
in interface com.sentilla.io.ObjectInput
- Throws:
com.sentilla.io.IORuntimeException
writeBoolean
public void writeBoolean(boolean a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeBoolean
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeByte
public void writeByte(int a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeByte
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeShort
public void writeShort(int a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeShort
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeChar
public void writeChar(int a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeChar
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeInt
public void writeInt(int a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeInt
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeLong
public void writeLong(long a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeLong
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeFloat
public void writeFloat(float a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeFloat
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeDouble
public void writeDouble(double a)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeDouble
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeUTF
public void writeUTF(String s)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeUTF
in interface com.sentilla.io.DataOutput
- Throws:
com.sentilla.io.IORuntimeException
writeObject
public void writeObject(Object obj)
throws com.sentilla.io.IORuntimeException
- Specified by:
writeObject
in interface com.sentilla.io.ObjectOutput
- Throws:
com.sentilla.io.IORuntimeException
read
public byte read()
throws com.sentilla.io.IORuntimeException
- Specified by:
read
in interface com.sentilla.io.Input
- Throws:
com.sentilla.io.IORuntimeException
read
public int read(byte[] b)
throws com.sentilla.io.IORuntimeException
- Specified by:
read
in interface com.sentilla.io.Input
- Throws:
com.sentilla.io.IORuntimeException
read
public int read(byte[] b,
int offset,
int length)
throws com.sentilla.io.IORuntimeException
- Specified by:
read
in interface com.sentilla.io.Input
- Throws:
com.sentilla.io.IORuntimeException
skip
public void skip(int n)
throws com.sentilla.io.IORuntimeException
- Specified by:
skip
in interface com.sentilla.io.Input
- Throws:
com.sentilla.io.IORuntimeException
close
public void close()
throws com.sentilla.io.IORuntimeException
- Specified by:
close
in interface com.sentilla.io.Input
- Specified by:
close
in interface com.sentilla.io.Output
- Throws:
com.sentilla.io.IORuntimeException
write
public void write(int b)
throws com.sentilla.io.IORuntimeException
- Specified by:
write
in interface com.sentilla.io.Output
- Throws:
com.sentilla.io.IORuntimeException
write
public void write(byte[] b)
throws com.sentilla.io.IORuntimeException
- Specified by:
write
in interface com.sentilla.io.Output
- Throws:
com.sentilla.io.IORuntimeException
write
public void write(byte[] b,
int offset,
int length)
throws com.sentilla.io.IORuntimeException
- Specified by:
write
in interface com.sentilla.io.Output
- Throws:
com.sentilla.io.IORuntimeException
setOverwriteMode
public void setOverwriteMode(boolean doOverwrite)
flush
public void flush()
throws com.sentilla.io.IORuntimeException
- Specified by:
flush
in interface com.sentilla.io.Output
- Throws:
com.sentilla.io.IORuntimeException
Copyright © 2007 Sentilla Corporation. All Rights Reserved.