|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.edg.info.sqlutil.rdb.Tuple
A relational tuple (row in a table). This consists of a set of column names (as String objects) and a set of column values, each of which is a String, Integer/Double or null, representing STRING, NUMERIC and NULL Constant types.
Constructor Summary | |
Tuple()
Creates a new empty Tuple. |
|
Tuple(java.util.List columnNames)
Creates a new tuple, given it's column names. |
|
Tuple(java.lang.String[] columnNames)
Creates a new Tuple object. |
Method Summary | |
boolean |
equals(java.lang.Object obj)
|
int |
getAttIndex(java.lang.String name)
Return the index of the attribute corresponding to the name |
java.lang.String |
getAttName(int index)
Return the name of the attribute corresponding to the index |
java.lang.Object |
getAttValue(int index)
Return the value of the attribute corresponding to the index |
java.lang.Object |
getAttValue(java.lang.String name)
Return the value of the attribute whith the given name |
java.lang.String[] |
getColumnNames()
Gets the array of column names as Strings. |
java.util.List |
getColumnValues()
Gets the column values as a List of Double, Integer or String objects. |
java.lang.String[] |
getColumnValuesAsStrings()
Gets the column values as an array of Strings. |
long |
getEstimatedSize()
Get an estimate for the amount of memory required to store this tuple. |
int |
getNumAtt()
Return the number of attributes in the tuple. |
int |
hashCode()
|
boolean |
isAttribute(java.lang.String attrName)
To know if an attributes is already defined |
Tuple |
project(java.util.Vector map)
Projects this Tuple according to the given SELECT map. |
void |
setAtt(java.lang.String name,
java.lang.Object value)
Set the value of the given attribute name |
void |
setRow(java.util.List row)
Set the current tuple's column values. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Tuple()
public Tuple(java.util.List columnNames)
columnNames
- List of column names.public Tuple(java.lang.String[] columnNames)
columnNames
- DOCUMENT ME!Method Detail |
public long getEstimatedSize()
public void setAtt(java.lang.String name, java.lang.Object value)
name
- the string representing the attribute namevalue
- the Object representing the attribute valuepublic int getAttIndex(java.lang.String name)
name
- integer giving the index of the attribute
public java.lang.String getAttName(int index)
index
- integer giving the index of the attribute
public java.lang.Object getAttValue(int index) throws java.sql.SQLException
index
- integer giving the index of the attribute
java.sql.SQLException
- If the index is out of bounds.public java.lang.Object getAttValue(java.lang.String name) throws java.sql.SQLException
name
- Attribute name.
java.sql.SQLException
- If the name does not exist in this tuple.public boolean isAttribute(java.lang.String attrName)
attrName
- the name of the attribute
public java.lang.String[] getColumnNames()
public java.lang.String[] getColumnValuesAsStrings()
public java.util.List getColumnValues()
public int getNumAtt()
public void setRow(java.util.List row)
row
- A vector of column values.public boolean equals(java.lang.Object obj)
Object.equals(java.lang.Object)
public int hashCode()
Object.hashCode()
public java.lang.String toString()
Object.toString()
public Tuple project(java.util.Vector map) throws java.sql.SQLException
map
- Vector of SelectItem objects.
java.sql.SQLException
- If the projection can not be completed.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |