TColumn - TTable - public abstract class UserCoreRow<TColumn extends UserColumn,TTable extends UserTable<TColumn>> extends Object
| Modifier and Type | Field and Description |
|---|---|
protected int[] |
columnTypes
Cursor column types of this row, based upon the data values
|
protected TTable |
table
User table
|
protected Object[] |
values
Array of row values
|
| Modifier | Constructor and Description |
|---|---|
protected |
UserCoreRow(TTable table)
Constructor to create an empty row
|
protected |
UserCoreRow(TTable table,
int[] columnTypes,
Object[] values)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
int |
columnCount()
Get the column count
|
TColumn |
getColumn(int index)
Get the column at the index
|
TColumn |
getColumn(String columnName)
Get the column of the column name
|
int |
getColumnIndex(String columnName)
Get the index of the column name
|
String |
getColumnName(int index)
Get the column name at the index
|
String[] |
getColumnNames()
Get the column names
|
long |
getId()
Get the id value, which is the value of the primary key
|
TColumn |
getPkColumn()
Get the primary key column
|
int |
getPkColumnIndex()
Get the primary key column index
|
int |
getRowColumnType(int index)
Get the Cursor column data type at the index
|
int |
getRowColumnType(String columnName)
Get the Cursor column data type of the column name
|
int[] |
getRowColumnTypes()
Get the Cursor column data types
|
TTable |
getTable()
Get the table
|
Object |
getValue(int index)
Get the value at the index
|
Object |
getValue(String columnName)
Get the value of the column name
|
Object[] |
getValues()
Get the row values
|
void |
resetId()
Clears the id so the row can be used as part of an insert or create
|
void |
setValue(int index,
Object value)
Set the column value at the index
|
void |
setValue(String columnName,
Object value)
Set the column value of the column name
|
protected void |
validateValue(TColumn column,
Object value,
Class<?>... valueTypes)
Validate the value and its actual value types against the column data
type class
|
protected final int[] columnTypes
protected final Object[] values
protected UserCoreRow(TTable table, int[] columnTypes, Object[] values)
table - columnTypes - values - protected UserCoreRow(TTable table)
table - public int columnCount()
public String[] getColumnNames()
public String getColumnName(int index)
index - public int getColumnIndex(String columnName)
columnName - public Object getValue(int index)
index - public Object getValue(String columnName)
columnName - public Object[] getValues()
public int[] getRowColumnTypes()
Cursor#FIELD_TYPE_STRING,
Cursor#FIELD_TYPE_INTEGER,
Cursor#FIELD_TYPE_FLOAT,
Cursor#FIELD_TYPE_BLOB,
Cursor#FIELD_TYPE_NULLpublic int getRowColumnType(int index)
index - Cursor#FIELD_TYPE_STRING,
Cursor#FIELD_TYPE_INTEGER,
Cursor#FIELD_TYPE_FLOAT,
Cursor#FIELD_TYPE_BLOB,
Cursor#FIELD_TYPE_NULLpublic int getRowColumnType(String columnName)
columnName - Cursor#FIELD_TYPE_STRING,
Cursor#FIELD_TYPE_INTEGER,
Cursor#FIELD_TYPE_FLOAT,
Cursor#FIELD_TYPE_BLOB,
Cursor#FIELD_TYPE_NULLpublic TTable getTable()
public TColumn getColumn(int index)
index - public TColumn getColumn(String columnName)
columnName - public long getId()
public int getPkColumnIndex()
public TColumn getPkColumn()
public void setValue(int index,
Object value)
index - value - public void setValue(String columnName, Object value)
columnName - value - public void resetId()
Copyright © 2016 National Geospatial-Intelligence Agency. All rights reserved.