Copyright 2009,2010, Lapetus Systems Ltd. (All rights reserved)

com.lapetus_ltd.api.db.xml.types
Class TLptsDBStatementTableType

java.lang.Object
  extended by com.lapetus_ltd._2009.xml.types.XLptsDBStatementTableType
      extended by com.lapetus_ltd.api.db.xml.types.TLptsDBStatementTableType

public class TLptsDBStatementTableType
extends XLptsDBStatementTableType

Class Description : This initiates the XLptsDBStatementTableType, which holds the data for a single table in TLptsStatement.

Because the columns and tables are utilised in a flat fashion in STATEMENTS, there is no hierarchy (table-column, one to many).
So therefore the columns need to keep information as to the table they belong to. This is kept in the form of a table name and unique id.
The information in this table class is therefore linked to the columns that exist in the table via the above column data.

This class is used by the TLptsStatement to capture the table information from the connection at the time of Statement creation.
The application can get this data from TLptsStatement.getTableItemById(java.lang.String),TLptsStatement.getTableItemByName(java.lang.String),
and TLptsStatement.getTableListItem().

$LastChangedRevision: 1165 $
$LastChangedDate:: 2010-11-03 10:37:03#$


Field Summary
 
Fields inherited from class com.lapetus_ltd._2009.xml.types.XLptsDBStatementTableType
id, selected, tableName, type
 
Constructor Summary
TLptsDBStatementTableType(java.lang.String table)
          This constructor initiates the Statement Table Type.
TLptsDBStatementTableType(XLptsDBStatementTableType stt)
           This constructor copies the StatementTable information from an XLptsDBStatementTableType.
 
Method Summary
 boolean equals(java.lang.Object obj)
           Check for equal TLptsDBStatementTableType objects.
 TLptsDBStatementTableType getCopy()
           Returns an identical copy of the TLptsDBStatementTableType.
 java.lang.String toString()
           Returns the table name.
 
Methods inherited from class com.lapetus_ltd._2009.xml.types.XLptsDBStatementTableType
getId, getTableName, getType, isSelected, setId, setSelected, setTableName, setType
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TLptsDBStatementTableType

public TLptsDBStatementTableType(java.lang.String table)
This constructor initiates the Statement Table Type.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : This Constructor set table name the argument and defaults.

Example :


 TLptsDBStatementTableType table = new TLptsDBStatementTableType("tableName");

 }

Parameters:
table - The name of the table.

TLptsDBStatementTableType

public TLptsDBStatementTableType(XLptsDBStatementTableType stt)

This constructor copies the StatementTable information from an XLptsDBStatementTableType.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Use this function every time you need to copy or instantiate a type XLptsDBStatementTableType class.

Example :


 public void example(XLptsDBStatementTableType stt)
 {
   TLptsDBStatementTableType table = new TLptsDBStatementTableType(stt);
 }

 

Parameters:
stt - the class object to copy.
Method Detail

equals

public boolean equals(java.lang.Object obj)

Check for equal TLptsDBStatementTableType objects.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : n/a

Notes : Use this to compare two TLptsDBStatementTableType objects by there id's.

Example :


 TLptsDBStatementTableType table1 = new TLptsDBStatementTableType();
 TLptsDBStatementTableType table2 = new TLptsDBStatementTableType();
 return table1.equals(table2);

 

Overrides:
equals in class java.lang.Object
Parameters:
obj - the Statement Table Type
Returns:
true if they are equal, else false.

getCopy

public TLptsDBStatementTableType getCopy()

Returns an identical copy of the TLptsDBStatementTableType.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Use this function if you want to get an identical table.

Example :


 TLptsDBStatementTableType table = new TLptsDBStatementTableType();
 LinkedList  newTableList = new LinkedList();
 newTableList.add(table.getCopy);

 


toString

public java.lang.String toString()

Returns the table name.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Use this function if you want to get table name.

Example :


 TLptsDBStatementTableType table = new TLptsDBStatementTableType();
 if(table.toString.equals("clients"))
     return true;

 

Overrides:
toString in class java.lang.Object


Copyright 2009,2010, Lapetus Systems Ltd. (All rights reserved)