|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xBaseJ.fields.Field
public abstract class Field
This class is courtesy of the xBaseJ project: http://xbasej.sourceforge.net/ Copyright 1997-2007 - American Coders, LTD - Raleigh NC USA
American Coders, Ltd P. O. Box 97462 Raleigh, NC 27615 USA 1-919-846-2014 http://www.americancoders.com
| Field Summary | |
|---|---|
protected byte[] |
buffer
|
protected ByteBuffer |
bytebuffer
|
protected boolean |
deleted
|
protected long |
myoffset
|
protected String |
name
|
protected int |
nength
|
static String |
otherValidCharacters
|
| Constructor Summary | |
|---|---|
Field()
creates a Field object. not useful for the abstract Field class |
|
| Method Summary | |
|---|---|
Object |
clone()
|
String |
get()
|
byte[] |
getBytes()
returns the original byte array as stored in the file. |
int |
getDecimalPositionCount()
|
int |
getLength()
|
String |
getName()
|
abstract char |
getType()
|
void |
put(byte[] inValue)
set field contents with binary data, no database updates until a DBF update or write is issued if inValue is too short buffer is filled with binary zeros. |
void |
put(String inValue)
set field contents, no database updates until a DBF update or write is issued |
void |
read()
|
void |
readExternal(ObjectInput in)
used by externalize methods |
void |
setBuffer(ByteBuffer inBuffer)
|
void |
setBufferSpace()
|
void |
setField(String iName,
int iLength,
ByteBuffer inbuffer)
|
void |
update()
|
void |
write()
|
void |
writeExternal(ObjectOutput out)
used by externalize methods |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String name
protected int nength
protected byte[] buffer
protected boolean deleted
protected ByteBuffer bytebuffer
protected long myoffset
public static String otherValidCharacters
| Constructor Detail |
|---|
public Field()
CharField,
DateField,
LogicalField,
MemoField,
NumField| Method Detail |
|---|
public void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface Externalizablein - ObjectInput stream
IOException - - most likely class changed since written
ClassNotFoundException - - only when dummy constructro not found
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface Externalizableout - ObjectOutput stream
IOException - Java.io error
public Object clone()
throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedException
public void setField(String iName,
int iLength,
ByteBuffer inbuffer)
throws xBaseJException
xBaseJExceptionpublic void setBuffer(ByteBuffer inBuffer)
public void setBufferSpace()
public String getName()
public int getLength()
public abstract char getType()
public int getDecimalPositionCount()
public void read()
throws IOException,
xBaseJException
IOException
xBaseJExceptionpublic String get()
public byte[] getBytes()
public void write()
throws IOException,
xBaseJException
IOException
xBaseJException
public void update()
throws IOException,
xBaseJException
IOException
xBaseJException
public void put(String inValue)
throws xBaseJException
inValue - value to set
xBaseJException - value length too long
public void put(byte[] inValue)
throws xBaseJException
inValue - byte array
xBaseJException - value length too long
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||