dsql.value
Class RecordProxy
java.lang.Object
dsql.DMExecuted
dsql.value.Value
dsql.value.NonScalarValue
dsql.value.RecordProxy
- All Implemented Interfaces:
- ColumnHolder, DotAt
- public class RecordProxy
- extends NonScalarValue
- implements DotAt, ColumnHolder
A pointer to a record in a table. This class implements the
DotAt interface, which means its contents can be accessed
with ".@n". It also implements the ColumnHolder interface,
so that it can be used in Table or set operations whenever
a record is expected.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
RecordProxy
public RecordProxy(TableResult _table,
int _recordIndex)
throws ExecuteException
toString
public java.lang.String toString()
getString
public java.lang.String getString()
throws ExecuteException
- Specified by:
getString
in class Value
- Returns:
- a string representation of this value, to be used
within dsql expressions. This is distinct from toString(),
which is used to output the object for debugging purposes.
- Throws:
ExecuteException
getBoolean
public boolean getBoolean()
throws ExecuteException
- Specified by:
getBoolean
in class Value
- Returns:
- true if this Value is "non-zero", e.g. non-empty string,
tables has some record, etc.
- Throws:
ExecuteException
print
public void print(ASTPrint printer)
throws ExecuteException
- Description copied from class:
Value
- Print this value using printer
- Specified by:
print
in class Value
- Throws:
ExecuteException
getField
public java.lang.Object getField(java.lang.String name)
throws ExecuteException
- Access an object's field
- Overrides:
getField
in class NonScalarValue
- Throws:
ExecuteException
getField
public java.lang.Object getField(int i)
throws ExecuteException
- Description copied from interface:
DotAt
- First column is 1
- Specified by:
getField
in interface DotAt
- Throws:
ExecuteException
setField
public java.lang.Object setField(int i,
Value val)
throws ExecuteException
- Specified by:
setField
in interface DotAt
- Throws:
ExecuteException
updateField
public void updateField()
throws ExecuteException
- Throws:
ExecuteException
getMeta
public ConstructedResults getMeta()
throws ExecuteException
- Specified by:
getMeta
in class Value
- Returns:
- meta-information about this Value, e.g. for a table,
it returns the names,types,width,etc. of its columns.
- Throws:
ExecuteException
getColumn
public java.lang.Object getColumn(int i)
throws ExecuteException
- Specified by:
getColumn
in interface ColumnHolder
- Parameters:
i
- column number (first column is 1)
- Returns:
- column value; usually a String, but can also be
a complex object, such as
XmlDataValue
.
- Throws:
ExecuteException
getColumnString
public java.lang.String getColumnString(int i)
throws ExecuteException
- Specified by:
getColumnString
in interface ColumnHolder
- Throws:
ExecuteException
getColumn
public java.lang.Object getColumn(java.lang.String s)
throws ExecuteException
- Specified by:
getColumn
in interface ColumnHolder
- Parameters:
s
- column name
- Returns:
- column value; usually a String, but can also be
a complex object, such as
XmlDataValue
.
- Throws:
ExecuteException
getColumnString
public java.lang.String getColumnString(java.lang.String s)
throws ExecuteException
- Specified by:
getColumnString
in interface ColumnHolder
- Throws:
ExecuteException
getColumnCount
public int getColumnCount()
throws ExecuteException
- Specified by:
getColumnCount
in interface ColumnHolder
- Throws:
ExecuteException
getColumnLabel
public java.lang.String getColumnLabel(int i)
throws ExecuteException
- Specified by:
getColumnLabel
in interface ColumnHolder
- Throws:
ExecuteException
getColumnDisplaySize
public int getColumnDisplaySize(int i)
throws ExecuteException
- Specified by:
getColumnDisplaySize
in interface ColumnHolder
- Throws:
ExecuteException
getTable
protected TableResult getTable()
throws ExecuteException
- Throws:
ExecuteException