Class TDbTableInfo

Description

TDbTableInfo class describes the meta data of a database table.

  • since: 3.1
  • version: $Id: TDbTableInfo.php 1910 2007-05-08 07:49:50Z wei $
  • author: Wei Zhuo <weizho[at]gmail[dot]com>

Located in /Data/Common/TDbTableInfo.php (line 21)

TComponent
   |
   --TDbTableInfo
Direct descendents
Class Description
TMssqlTableInfo TMssqlTableInfo class provides additional table information for Mssql database.
TMysqlTableInfo TMysqlTableInfo class provides additional table information for MySQL database.
TPgsqlTableInfo TPgsqlTableInfo class provides additional table information for PostgreSQL database.
TSqliteTableInfo TSqliteTableInfo class provides additional table information for PostgreSQL database.
Method Summary
TDbTableInfo __construct ([array $tableInfo = array()], [mixed $primary = array()], [mixed $foreign = array()])
TDbTableColumn getColumn (string $name)
array getColumnNames (array 0)
array getForeignKeys ()
mixed getInfo (string $name, [mixed $default = null])
boolean getIsView ()
string[] getPrimaryKeys ()
string getTableFullName ()
string getTableName ()
void setInfo (string $name, mixed $value)
Methods
Constructor __construct (line 36)

Sets the database table meta data information.

  • access: public
TDbTableInfo __construct ([array $tableInfo = array()], [mixed $primary = array()], [mixed $foreign = array()])
  • array $tableInfo: table column information.
createCommandBuilder (line 48)
  • return: new command builder
  • access: public
TDbCommandBuilder createCommandBuilder (TDbConnection $connection)

Redefined in descendants as:
getColumn (line 109)
  • return: column information.
  • access: public
TDbTableColumn getColumn (string $name)
  • string $name: column id
getColumnNames (line 120)
  • return: table column names (identifier quoted)
  • access: public
array getColumnNames (array 0)
  • array 0: list of column Id, empty to get all columns.
getColumns (line 100)
  • return: TDbTableColumn column meta data.
  • access: public
TMap getColumns ()
getForeignKeys (line 139)
  • return: tuples of foreign table and column name.
  • access: public
array getForeignKeys ()
getInfo (line 59)
  • return: information array value.
  • access: protected
mixed getInfo (string $name, [mixed $default = null])
  • string $name: information array key name
  • mixed $default: default value if information array value is null
getIsView (line 92)
  • return: whether the table is a view, default is false.
  • access: public
boolean getIsView ()
getLowerCaseColumnNames (line 147)
  • return: lowercased column key names mapped to normal column ids.
  • access: public
array getLowerCaseColumnNames ()
getPrimaryKeys (line 131)
  • return: names of primary key columns.
  • access: public
string[] getPrimaryKeys ()
getTableFullName (line 84)
  • return: full name of the table, database dependent.
  • access: public
string getTableFullName ()

Redefined in descendants as:
getTableName (line 76)
  • return: name of the table this column belongs to.
  • access: public
string getTableName ()
setInfo (line 68)
  • access: protected
void setInfo (string $name, mixed $value)
  • string $name: information array key name
  • mixed $value: new information array value.

Inherited Methods

Inherited From TComponent

TComponent::addParsedObject()
TComponent::attachEventHandler()
TComponent::canGetProperty()
TComponent::canSetProperty()
TComponent::createdOnTemplate()
TComponent::detachEventHandler()
TComponent::evaluateExpression()
TComponent::evaluateStatements()
TComponent::getEventHandlers()
TComponent::getSubProperty()
TComponent::hasEvent()
TComponent::hasEventHandler()
TComponent::hasProperty()
TComponent::raiseEvent()
TComponent::setSubProperty()
TComponent::__get()
TComponent::__set()

Documentation generated on Mon, 21 Apr 2008 11:34:54 -0400 by phpDocumentor 1.3.0RC4