public interface DataResultSet
| Modifier and Type | Interface and Description |
|---|---|
static class |
DataResultSet.Field
A Field represents definition (e.g.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addField(DataResultSet.Field field, String defaultValue)
Add a new field to the existing list of fields.
|
void |
addRow(DataObject row)
Add a new row of value.
|
void |
addRow(List<String> items)
Add a new row as an array of string values
|
DataResultSet.Field |
getField(int index)
Retrieve the field object at a given index
|
DataResultSet.Field |
getField(String name)
Retrieve the field object with the given field name.
|
List<DataResultSet.Field> |
getFields()
Retrieve fields for all columns
|
List<DataObject> |
getRows()
Retrieve values of all rows
|
boolean |
hasField(String name)
Determines if the field is present in this result set by a given field name
|
void |
insertRow(DataObject row, int index)
Add a new row of data at the given index.
|
void |
insertRow(List<String> items, int index)
Add a new row as an array of string values at the given index.
|
void |
removeField(String field)
Remove a field from all rows by a given field name Note: this is an expensive operation; all internal data structures will be updated.
|
void |
removeRow(int row)
Remove a row at a given index
|
void |
setFields(List<DataResultSet.Field> fields)
Set the fields for all columns
|
boolean hasField(String name)
name - the field nameDataResultSet.Field getField(String name)
name - the name of the fieldDataResultSet.Field getField(int index)
index - the column indexList<DataResultSet.Field> getFields()
void setFields(List<DataResultSet.Field> fields)
fields - the fields for all columnsvoid addField(DataResultSet.Field field, String defaultValue)
field - the field to adddefaultValue - a default value for the new column in each rowvoid removeField(String field)
field - the field to removevoid addRow(DataObject row)
row - a data object with a mapping of the list field names to valuesvoid addRow(List<String> items)
items - the row valuesvoid insertRow(DataObject row, int index)
index - the index into the list to insert this rowrow - a data object with a mapping of the list field names to valuesaddRow(DataObject)void insertRow(List<String> items, int index)
index - the index to insert the rowitems - the row valuesvoid removeRow(int row)
row - the zero-based row indexList<DataObject> getRows()