com.tivoli.twg.engine
Class TWGDbQueryColumn

java.lang.Object
  extended bycom.tivoli.twg.engine.TWGDbQueryColumn
All Implemented Interfaces:
java.io.Serializable

public class TWGDbQueryColumn
extends java.lang.Object
implements java.io.Serializable

* The class describes information about a column in a result set of a query. *

See Also:
*, Serialized Form

Constructor Summary
TWGDbQueryColumn(byte[] buf, int offset)
          Constructor to creat a TWGDbQueryColumn from intel byte buffer.
TWGDbQueryColumn(java.lang.String realName, java.lang.String displayColName, int colType, int colLength, java.lang.String colTokenName)
          Constructor for TWGDbQueryColumn.
TWGDbQueryColumn(java.lang.String realName, java.lang.String displayColName, int colType, int colLength, java.lang.String colTokenName, boolean filterColumn, boolean mappedColumn, int colIndex, java.lang.String tableTokenName)
          Constructor for TWGDbQueryColumn.
 
Method Summary
 int getBufferLen()
          Get length of buffer containing information about query column.
 int getColumnId()
          Get the column number.
 java.lang.Integer getColumnLength()
          Get the number of characters in column.
 java.lang.String getColumnTokenName()
          The instance method gets the token name for the column
 int getColumnType()
          Get the column type.
 java.lang.String getDisplayColumnName()
          Get the column display name used in printouts and displays.
 java.lang.String getRealColumnName()
          Get the column real name.
 java.lang.String getTableDisplayName()
          Get the display name for the table that the column is in
 java.lang.String getTableTokenName()
          Get the token name for the table that the column is in.
 boolean isFilterColumn()
          Get whether the column values should be displayed on the filter panel.
 boolean isMappedColumn()
          Return true if the column value in a query result set will be translated.
 int setBufferParms(byte[] buf, int offset)
          Method to write out a buffer information about the query column.
 void setColumnId(int column_id)
          Set the column number.
 void setFilterColumn(boolean filter)
          Set whether the column values should be displayed on the filter panel.
 void setMappedColumn(boolean mapped)
          Set whether column is translated for NLS via resource bundles.
 void setTableDisplayName(java.lang.String displayName)
          Set the display name for the table for this column
 void setTableToken(java.lang.String tableToken)
          Set the table token name for the column
 java.lang.String toString()
          Convert column to String for debug
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TWGDbQueryColumn

public TWGDbQueryColumn(java.lang.String realName,
                        java.lang.String displayColName,
                        int colType,
                        int colLength,
                        java.lang.String colTokenName)
Constructor for TWGDbQueryColumn.


TWGDbQueryColumn

public TWGDbQueryColumn(java.lang.String realName,
                        java.lang.String displayColName,
                        int colType,
                        int colLength,
                        java.lang.String colTokenName,
                        boolean filterColumn,
                        boolean mappedColumn,
                        int colIndex,
                        java.lang.String tableTokenName)
Constructor for TWGDbQueryColumn.


TWGDbQueryColumn

public TWGDbQueryColumn(byte[] buf,
                        int offset)
                 throws TWGDbException
Constructor to creat a TWGDbQueryColumn from intel byte buffer.

Parameters:
buf - - the byte array
offset - - the offset in the buffer that the query column starts at
Method Detail

setMappedColumn

public void setMappedColumn(boolean mapped)
Set whether column is translated for NLS via resource bundles.

Parameters:
mapped - - true if the column can is to be translated, otherwise false /*

isMappedColumn

public boolean isMappedColumn()
Return true if the column value in a query result set will be translated. Return false if not.

Returns:
true for a mapped column, otherwise false

setFilterColumn

public void setFilterColumn(boolean filter)
Set whether the column values should be displayed on the filter panel.

Parameters:
filter - - true to make the column a filter column

isFilterColumn

public boolean isFilterColumn()
Get whether the column values should be displayed on the filter panel.

Returns:
true if column is a filter column, otherwise false

setColumnId

public void setColumnId(int column_id)
Set the column number.

Parameters:
column_id - - column number.

getColumnId

public int getColumnId()
Get the column number.

Returns:
the column number

setTableToken

public void setTableToken(java.lang.String tableToken)
Set the table token name for the column

Parameters:
tableToken - - the table token name

getTableTokenName

public java.lang.String getTableTokenName()
Get the token name for the table that the column is in.

Returns:
String

getRealColumnName

public java.lang.String getRealColumnName()
Get the column real name.

Returns:
String

getDisplayColumnName

public java.lang.String getDisplayColumnName()
Get the column display name used in printouts and displays.

Returns:
String

getColumnType

public int getColumnType()
Get the column type. Valid types are in TWGDatabase

Returns:
the column type

getColumnLength

public java.lang.Integer getColumnLength()
Get the number of characters in column. This only applies to String type column(VARCHAR, CHAR);

Returns:
the column length

getColumnTokenName

public java.lang.String getColumnTokenName()
The instance method gets the token name for the column

Returns:
String

setTableDisplayName

public void setTableDisplayName(java.lang.String displayName)
Set the display name for the table for this column

Parameters:
displayName - - the display name

getTableDisplayName

public java.lang.String getTableDisplayName()
Get the display name for the table that the column is in

Returns:
String

setBufferParms

public int setBufferParms(byte[] buf,
                          int offset)
Method to write out a buffer information about the query column.

Returns:
int - offset

getBufferLen

public int getBufferLen()
Get length of buffer containing information about query column.


toString

public java.lang.String toString()
Convert column to String for debug

Returns:
String with a textual description of the column.