|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--xBaseJ.Client.DBF
Constructor Summary | |
DBF(java.lang.String inDBFname,
java.lang.String inhost,
int inport)
opens a DBF at the server |
|
DBF(java.lang.String inDBFname,
java.lang.String inhost,
int inport,
boolean stayConnected)
opens a DBF at the server |
Method Summary | |
void |
close()
closes the database NOT FULLY IMPLEMENTED |
void |
delete()
marks the current records as deleted |
boolean |
deleted()
|
boolean |
find(java.lang.String keyString)
used to find a record with an equal or greater string value when done the record pointer and field contents will be changed |
void |
findNext()
used to get the next record in the Index list when done the record pointer and field contents will be changed |
void |
findPrev()
used to get the previous record in the Index list when done the record pointer and field contents will be changed |
int |
fldcount()
Deprecated. use getFieldCount |
int |
getCurrentRecordNumber()
|
Field |
getField(int i)
|
Field |
getField(java.lang.String name)
|
int |
getFieldCount()
|
java.lang.String |
getName()
|
int |
getRecordCount()
|
void |
gotoRecord(long recno)
used to read a record at a particular place in the database when done the record pointer and field contents will be changed |
void |
read()
used to read the next record, after the current record pointer, in the database when done the record pointer and field contents will be changed |
void |
readPrev()
used to read the previous record, before the current record pointer, in the database when done the record pointer and field contents will be changed |
int |
reccount()
Deprecated. use getRecordCount |
int |
recno()
Deprecated. use getCurrentRecordNumber |
void |
setLock(boolean lockSwitch)
locks/unlocks the whole table |
void |
setRecordLock(boolean lockSwitch)
locks/unlocks the current record. |
void |
startBottom()
used to position record pointer at the last record or index in the database when done the record pointer will be changed. |
void |
startTop()
used to position record pointer at the first record or index in the database when done the record pointer will be changed. |
void |
undelete()
marks the current records as not deleted |
void |
update()
updates the record at the current position |
void |
useIndex(java.lang.String name)
opens an index associated with the database |
void |
useTag(java.lang.String name)
assigns Tag associated with the database used in find, findnext and findprev Tags are not defined in the dbfs.dbf file |
void |
write()
used to write a new record in the database when done the record pointer is at the end of the database |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public DBF(java.lang.String inDBFname, java.lang.String inhost, int inport, boolean stayConnected) throws xBaseJException, java.io.IOException, java.net.UnknownHostException
DBFname
- database as defined on the serverinhost
- host name or ip addressinport
- host listening portstayConnected
- boolean indicator for persitant connectionxBaseJException
- File does exist and told not to destroy it.xBaseJException
- Told to destroy but operating system can not destroyjava.io.IOException
- Java error caused by called methodsjava.lang.SecurityException
- Java error caused by called methods, most likely trying to create on a remote systempublic DBF(java.lang.String inDBFname, java.lang.String inhost, int inport) throws xBaseJException, java.io.IOException, java.net.UnknownHostException
DBFname
- database as defined on the serverinhost
- host name or ip addressinport
- host listening portxBaseJException
- File does exist and told not to destroy it.xBaseJException
- Told to destroy but operating system can not destroyjava.io.IOException
- Java error caused by called methodsjava.lang.SecurityException
- Java error caused by called methods, most likely trying to create on a remote systemMethod Detail |
public void setLock(boolean lockSwitch) throws xBaseJException, java.io.IOException
lockSwitch
- - true - lock the table, false - unlockxBaseJException
- most likely table already locked by another processjava.io.IOException
- Java error caused by called methodspublic void setRecordLock(boolean lockSwitch) throws xBaseJException, java.io.IOException
lockSwitch
- - true - lock the record, false - unlockxBaseJException
- most likely table or record is already locked by another process
record cursor not on a valid record - read a record firstjava.io.IOException
- Java error caused by called methodspublic void useIndex(java.lang.String name) throws xBaseJException, java.io.IOException
indexname
- an existing index as defined in Server's dbfs.dbfxBaseJException
- xBaseJ Fields defined in Index do not match Fields in databasejava.io.IOException
- Java error caused by called methodspublic void useTag(java.lang.String name) throws xBaseJException, java.io.IOException
Tag
- as defined in the MDX File.xBaseJException
- xBaseJ Fields defined in Index do not match Fields in databasejava.io.IOException
- Java error caused by called methodspublic boolean find(java.lang.String keyString) throws xBaseJException, java.io.IOException
keyString
- a search stringxBaseJException
- xBaseJ no Indexes/Tags opened with databasejava.io.IOException
- Java error caused by called methodspublic void findNext() throws xBaseJException, java.io.IOException
xBaseJException
- xBaseJ Index/Tag not opened or not part of the databasejava.io.IOException
- Java error caused by called methodspublic void findPrev() throws xBaseJException, java.io.IOException
xBaseJException
- xBaseJ Index/Tag not opened or not part of the databasejava.io.IOException
- Java error caused by called methodspublic void startTop() throws xBaseJException, java.io.IOException
xBaseJException
- java.io.IOException
- Java error caused by called methodspublic void startBottom() throws xBaseJException, java.io.IOException
xBaseJException
- java.io.IOException
- Java error caused by called methodspublic int fldcount()
public int recno()
public int reccount() throws xBaseJException, java.io.IOException
xBaseJException
- logic error with serverjava.io.IOException
- logic error with serverpublic int getFieldCount()
public int getCurrentRecordNumber()
public int getRecordCount() throws xBaseJException, java.io.IOException
xBaseJException
- logic error with serverjava.io.IOException
- logic error with serverpublic void read() throws xBaseJException, java.io.IOException
xBaseJException
- usually the end of file conditionjava.io.IOException
- Java error caused by called methodspublic void readPrev() throws xBaseJException, java.io.IOException
xBaseJException
- usually the top of file conditionjava.io.IOException
- Java error caused by called methodspublic void gotoRecord(long recno) throws xBaseJException, java.io.IOException
recno
- the relative position of the record to readxBaseJException
- passed an negative number, 0 or value greater than the number of records in databasejava.io.IOException
- Java error caused by called methodspublic void write() throws xBaseJException, java.io.IOException
xBaseJException
- any one of several errorsjava.io.IOException
- Java error caused by called methodspublic void update() throws xBaseJException, java.io.IOException
xBaseJException
- any one of several errorsjava.io.IOException
- Java error caused by called methodspublic void delete() throws java.io.IOException, xBaseJException
xBaseJException
- usually occurs when no record has been readjava.io.IOException
- Java error caused by called methodspublic void undelete() throws java.io.IOException, xBaseJException
xBaseJException
- usually occurs when no record has been read.java.io.IOException
- Java error caused by called methodspublic void close() throws java.io.IOException, xBaseJException
java.io.IOException
- Java error caused by called methodsxBaseJException
- logic error with serverpublic Field getField(int i) throws java.lang.ArrayIndexOutOfBoundsException, xBaseJException
i
- Field numberxBaseJException
- usually occurs when Field number is less than 1 or greater than the number of Fieldsjava.lang.ArrayIndexOutOfBoundsException
- Java error caused by called methodspublic Field getField(java.lang.String name) throws xBaseJException, java.lang.ArrayIndexOutOfBoundsException
name
- Field namexBaseJException
- Field name is not correctjava.lang.ArrayIndexOutOfBoundsException
- Java error caused by called methodspublic java.lang.String getName()
public boolean deleted() throws java.io.IOException, xBaseJException
xBaseJException
- logic error with serverjava.io.IOException
- logic error with server
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |