|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface TableRecord
Defines an object for table records that can read the field values or write values to the fields given a field name or field index.
Method Summary | |
---|---|
void |
clear()
Clears the content of the TableRecord object. |
int |
findColumn(String name)
Gets the integer index of a field with the given name (1-relative). |
byte |
getByte(int index)
Gets the byte value of a field given the index. |
byte |
getByte(String name)
Gets the byte value of a field given the name. |
double |
getDouble(int index)
Gets the double value of a field given the index. |
double |
getDouble(String name)
Gets the double value of a field given the name. |
float |
getFloat(int index)
Gets the float value of a field given the index. |
float |
getFloat(String name)
Gets the float value of a field given the name. |
int |
getInt(int index)
Gets the integer value of a field given the index. |
int |
getInt(String name)
Gets the integer value of a field given the name. |
long |
getLong(int index)
Gets the long value of a field given the index. |
long |
getLong(String name)
Gets the long value of a field given the name. |
short |
getShort(int index)
Gets the short value of a field given the index. |
short |
getShort(String name)
Gets the short value of a field given the name. |
String |
getString(int index)
Gets the string value of a field given the index. |
String |
getString(String name)
Gets the string value of a field given the name. |
void |
setByte(int index,
byte value)
Sets one byte value to a field given the index. |
void |
setByte(String name,
byte value)
Sets one byte value to a field given the name. |
void |
setDouble(int index,
double value)
Sets eight bytes containing the double value to a field given the index. |
void |
setDouble(String name,
double value)
Sets eight bytes containing the double value to a field given the name. |
void |
setFloat(int index,
float value)
Sets four bytes containing the float value to a field given the index. |
void |
setFloat(String name,
float value)
Sets four bytes containing the float value to a field given the name. |
void |
setInt(int index,
int value)
Sets four bytes containing the integer value to a field given the index. |
void |
setInt(String name,
int value)
Sets four bytes containing the integer value to a field given the name. |
void |
setLong(int index,
long value)
Sets eight bytes containing the long value to the record given the field index. |
void |
setLong(String name,
long value)
Sets eight bytes containing the long value to the record given the field name. |
void |
setShort(int index,
short value)
Sets two bytes containing the short value to a field given the index. |
void |
setShort(String name,
short value)
Sets two bytes containing the short value to a field given the index. |
void |
setString(int index,
String value)
Sets a string value to a field given the index. |
void |
setString(String value)
Sets a String value to the record at the current offset. |
void |
setString(String name,
String value)
Sets a string value to a field given the name. |
Method Detail |
---|
int findColumn(String name)
name
- the name of a field
short getShort(int index)
index
- the column index (1-relative)
IllegalArgumentException
- If cannot convert the number to shortshort getShort(String name)
name
- the field name
byte getByte(int index)
index
- the field index (1-relative)
IllegalArgumentException
- If cannot convert the number to bytebyte getByte(String name)
name
- the field name
long getLong(int index)
It throws NumberFormatException if the number is out of range when converting from ASCII_Integer to long.
index
- the field index (1-relative)
IllegalArgumentException
- If cannot convert the number to long
NumberFormatException
- If the number is out of range for a longlong getLong(String name)
name
- the field name
int getInt(String name)
name
- the field name
int getInt(int index)
It throws NumberFormatException if the number is out of range when converting from ASCII_Integer to int.
index
- the field index (1-relative)
IllegalArgumentException
- If cannot convert the number to int
NumberFormatException
- If the number is out of range for an intdouble getDouble(String name)
name
- the field name
double getDouble(int index)
If the number is out of range when converting from ASCII_Real to double, the method returns Double.POSITIVE_INFINITY or Double.NEGATIVE_INFINITY.
index
- the field index (1-relative)
IllegalArgumentException
- If cannot convert the number to doublefloat getFloat(String name)
name
- the field name
float getFloat(int index)
If the number is out of range when converting from ASCII_Real to float, the method returns Float.POSITIVE_INFINITY or Float.NEGATIVE_INFINITY.
index
- the field index (1-relative)
IllegalArgumentException
- If cannot convert the number to floatString getString(String name)
name
- the field name
String getString(int index)
index
- the field index (1-relative)
IllegalArgumentException
- If data type is not supportedvoid setString(int index, String value)
index
- the field index (1-relative)value
- a string value
IllegalArgumentException
- If the size of the value is greater than the field lengthvoid setString(String name, String value)
name
- the field namevalue
- a string value
IllegalArgumentException
- If the size of the value is greater than field lengthvoid setString(String value)
value
- a String valuevoid setInt(int index, int value)
index
- the field index (1-relative)value
- an integer valuevoid setInt(String name, int value)
name
- the field namevalue
- an integer valuevoid setDouble(int index, double value)
index
- the field index (1-relative)value
- a double valuevoid setDouble(String name, double value)
name
- the field namevalue
- a double valuevoid setFloat(int index, float value)
index
- the field index (1-relative)value
- a float valuevoid setFloat(String name, float value)
name
- the field namevalue
- a float valuevoid setShort(int index, short value)
index
- the field index (1-relative)value
- a short valuevoid setShort(String name, short value)
name
- the field namevalue
- a short valuevoid setByte(int index, byte value)
index
- the field index (1-relative)value
- a byte valuevoid setByte(String name, byte value)
name
- the field namevalue
- a byte valuevoid setLong(int index, long value)
index
- the field index (1-relative)value
- a long valuevoid setLong(String name, long value)
name
- the field namevalue
- a long valuevoid clear()
TableRecord
object.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |