TableSchema

Type
Class
Namespace
craft\db
Inherits
craft\db\TableSchema » yii\db\TableSchema » yii\base\BaseObject
Implements
yii\base\Configurable
Since
3.0.0

View source

# Public Properties

Property Description
columnNames array – List of column names
columns yii\db\ColumnSchema – Column metadata of this table.
extendedForeignKeys array
foreignKeys array – Foreign keys of this table.
fullName string – The full name of this table, which includes the schema name prefix, if any.
name string – The name of this table.
primaryKey string[] – Primary keys of this table.
schemaName string – The name of the schema that this table belongs to.
sequenceName string – Sequence name for the primary key.

# extendedForeignKeys

Type
array
Access
Read-only

View source

# Public Methods

Method Description
__call() Calls the named method which is not a class method.
__construct() Constructor.
__get() Returns the value of an object property.
__isset() Checks if a property is set, i.e. defined and not null.
__set() Sets value of an object property.
__unset() Sets an object property to null.
addExtendedForeignKey() Adds an extended foreign key to the internal array.
canGetProperty() Returns a value indicating whether a property can be read.
canSetProperty() Returns a value indicating whether a property can be set.
className() Returns the fully qualified name of this class.
fixPrimaryKey() Manually specifies the primary key for this table.
getColumn() Gets the named column metadata.
getColumnNames() Returns the names of all columns in this table.
getExtendedForeignKeys() Returns the array of extended foreign keys.
hasMethod() Returns a value indicating whether a method is defined.
hasProperty() Returns a value indicating whether a property is defined.
init() Initializes the object.

# addExtendedForeignKey()

Adds an extended foreign key to the internal array.

View source

Arguments

# getExtendedForeignKeys()

Returns the array of extended foreign keys.

View source

Returns

array