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

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

java.lang.Object
  extended by com.lapetus_ltd._2009.xml.types.XLptsDBCreateStatementColumnCollateType
      extended by com.lapetus_ltd.api.db.xml.types.TLptsDBCreateStatementColumnCollateType

public class TLptsDBCreateStatementColumnCollateType
extends XLptsDBCreateStatementColumnCollateType

Class Description : Initialisation class for Database CREATE collation type.

This class is used to set the Collation (like locale/charset) of a column in a CREATE statement.

$LastChangedRevision: 946 $
$LastChangedDate:: 2010-07-26 07:51:27#$


Field Summary
 
Fields inherited from class com.lapetus_ltd._2009.xml.types.XLptsDBCreateStatementColumnCollateType
collate
 
Constructor Summary
TLptsDBCreateStatementColumnCollateType()
           This constructor initiates the Column Collate of a Create Column Type.
TLptsDBCreateStatementColumnCollateType(XLptsDBCreateStatementColumnCollateType ccc)
           This constructor copies the Column Collate from an existing XLptsDBCreateStatementColumnCollateType.
 
Method Summary
 
Methods inherited from class com.lapetus_ltd._2009.xml.types.XLptsDBCreateStatementColumnCollateType
getCollate, setCollate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TLptsDBCreateStatementColumnCollateType

public TLptsDBCreateStatementColumnCollateType()

This constructor initiates the Column Collate of a Create Column Type.

Thread Safe : Yes

Spawns its own Thread : No

May Return NULL : Never.

Notes : Default Constructor initiates the column collate to an empty string.

Example :


    //Create the statement and set the Type of Statement to CREATE
    TLptsStatement createStatement = new TLptsStatement(connection,XLptsDBTypeOfStatementType.CREATE);
    ...
    //Create the columns
    TLptsDBCreateStatementColumnType idColumn = new TLptsDBCreateStatementColumnType();
    //Set the column name
    idColumn.setColumn("id");
    ...
    //Text type columns have Collation. Collation is not available for all DB's and it is not consistent across DBs.
    TLptsDBCreateStatementColumnCollateType collate = new TLptsDBCreateStatementColumnCollateType();
    collate.setCollate("SQL_Latin1_General_CP1253_CI_AS");
    idColumn.setCollate(collate);
    ...
 


TLptsDBCreateStatementColumnCollateType

public TLptsDBCreateStatementColumnCollateType(XLptsDBCreateStatementColumnCollateType ccc)

This constructor copies the Column Collate from an existing XLptsDBCreateStatementColumnCollateType.

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 XLptsDBCreateStatementColumnCollateType class.

Example :


 public void example(XLptsDBCreateStatementColumnCollateType ccd)
 {
   TLptsCreateColumnCollate columnCollate = new TLptsCreateColumnCollate(ccc);
 }
 

Parameters:
ccc - the class object to copy.


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