class Index extends MappingModel
Information about indices of a table.
Methods
__construct(string $name = null)
Creates a new Index instance. |
||
loadMapping(array $attributes)
Loads a mapping definition from an array. |
from MappingModel | |
array |
getAttributes()
Returns all definition attributes. |
from MappingModel |
mixed |
getAttribute(string $name, mixed $default = null)
Returns a particular attribute by a case-insensitive name. |
from MappingModel |
appendXml(DOMNode $node)
Appends DOM elements to represent this object in XML. |
||
VendorInfo |
addVendorInfo(VendorInfo|array $vendor)
Adds a new VendorInfo instance to this current model object. |
from MappingModel |
VendorInfo |
getVendorInfoForType(string $type)
Returns a VendorInfo object by its type. |
from MappingModel |
string |
getConfiguredBehavior(string $behavior)
Returns the best class name for a given behavior. |
from MappingModel |
string |
toString()
String representation of the current object. |
from MappingModel |
string |
__toString()
String representation of the current object. |
from MappingModel |
boolean |
isUnique()
Returns the uniqueness of this index. |
|
setName(string $name)
Sets the index name. |
||
string |
getName()
Returns the index name. |
|
setTable(Table $table)
Sets the index parent Table. |
||
Table |
getTable()
Returns the index parent table. |
|
string |
getTableName()
Returns the name of the index parent table. |
|
addColumn(mixed $data)
Adds a new column to the index. |
||
setColumns(array $columns)
Sets an array of columns to use for the index. |
||
boolean |
hasColumnSize(string $name)
Returns whether or not there is a size for the specified column. |
|
integer |
getColumnSize(string $name)
Returns the size for the specified column. |
|
resetColumnsSize()
Resets the columns sizes. |
||
boolean |
hasColumnAtPosition(integer $pos, string $name, integer $size = null, boolean $caseInsensitive = false)
Returns whether or not this index has a given column at a given position. |
|
boolean |
hasColumns()
Returns whether or not the index has columns. |
|
array |
getColumns()
Returns the list of local columns. |
Details
at line 34
public
__construct(string $name = null)
Creates a new Index instance.
in MappingModel at line 38
public
loadMapping(array $attributes)
Loads a mapping definition from an array.
in MappingModel at line 58
public array
getAttributes()
Returns all definition attributes.
All attribute names (keys) are lowercase.
in MappingModel at line 73
public mixed
getAttribute(string $name, mixed $default = null)
Returns a particular attribute by a case-insensitive name.
If the attribute is not set, then the second default value is
returned instead.
at line 259
public
appendXml(DOMNode $node)
Appends DOM elements to represent this object in XML.
in MappingModel at line 138
public VendorInfo
addVendorInfo(VendorInfo|array $vendor)
Adds a new VendorInfo instance to this current model object.
in MappingModel at line 158
public VendorInfo
getVendorInfoForType(string $type)
Returns a VendorInfo object by its type.
in MappingModel at line 176
public string
getConfiguredBehavior(string $behavior)
Returns the best class name for a given behavior.
If not found, the method tries to autoload \Propel\Generator\Behavior\[Bname]\[Bname]Behavior
in MappingModel at line 198
public string
toString()
String representation of the current object.
in MappingModel at line 213
public string
__toString()
String representation of the current object.
at line 51
public boolean
isUnique()
Returns the uniqueness of this index.
at line 61
public
setName(string $name)
Sets the index name.
at line 71
public string
getName()
Returns the index name.
at line 105
public
setTable(Table $table)
Sets the index parent Table.
at line 115
public Table
getTable()
Returns the index parent table.
at line 125
public string
getTableName()
Returns the name of the index parent table.
at line 135
public
addColumn(mixed $data)
Adds a new column to the index.
at line 158
public
setColumns(array $columns)
Sets an array of columns to use for the index.
at line 173
public boolean
hasColumnSize(string $name)
Returns whether or not there is a size for the specified column.
at line 184
public integer
getColumnSize(string $name)
Returns the size for the specified column.
at line 194
public
resetColumnsSize()
Resets the columns sizes.
This method is useful for generated indices for FKs.
at line 208
public boolean
hasColumnAtPosition(integer $pos, string $name, integer $size = null, boolean $caseInsensitive = false)
Returns whether or not this index has a given column at a given position.
at line 237
public boolean
hasColumns()
Returns whether or not the index has columns.
at line 249
public array
getColumns()
Returns the list of local columns.
You should not edit this list.