Doctrine\DBAL\Schema\Column
Object representation of a database column
- Author: Benjamin Eberlei <kontakt@beberlei.de>
Synopsis
class Column
extends AbstractAsset
{
- // members
- protected Type $_type;
- protected int $_length;
- protected integer $_precision;
- protected integer $_scale;
- protected bool $_unsigned;
- protected bool $_fixed;
- protected bool $_notnull;
- protected string $_default;
- protected bool $_autoincrement;
- protected array $_platformOptions;
- protected string $_columnDefinition;
- protected string $_comment;
- protected array $_customSchemaOptions;
- // Inherited members from AbstractAsset
- protected string $_name;
- protected string $_namespace;
- protected bool $_quoted;
- // methods
- public void __construct()
- public Column setOptions()
- public Column setType()
- public Column setLength()
- public Column setPrecision()
- public Column setScale()
- public Column setUnsigned()
- public Column setFixed()
- public Column setNotnull()
- public Column setDefault()
- public Column setPlatformOptions()
- public Column setPlatformOption()
- public Column setColumnDefinition()
- public void getType()
- public void getLength()
- public void getPrecision()
- public void getScale()
- public void getUnsigned()
- public void getFixed()
- public void getNotnull()
- public void getDefault()
- public void getPlatformOptions()
- public void hasPlatformOption()
- public void getPlatformOption()
- public void getColumnDefinition()
- public void getAutoincrement()
- public void setAutoincrement()
- public void setComment()
- public void getComment()
- public Column setCustomSchemaOption()
- public boolean hasCustomSchemaOption()
- public mixed getCustomSchemaOption()
- public Column setCustomSchemaOptions()
- public array getCustomSchemaOptions()
- public void visit()
- public array toArray()
- // Inherited methods from AbstractAsset
- protected void _setName()
- public bool isInDefaultNamespace()
- public string getNamespaceName()
- public string getShortestName()
- public string getFullQualifiedName()
- public bool isQuoted()
- protected bool isIdentifierQuoted()
- protected string trimQuotes()
- public string getName()
- public string getQuotedName()
- protected string _generateIdentifierName()
Hierarchy
Members
protected
- $_autoincrement — Doctrine\DBAL\Schema\bool
- $_columnDefinition — string
- $_comment — string
- $_customSchemaOptions — array
- $_default — string
- $_fixed — Doctrine\DBAL\Schema\bool
- $_length — int
- $_name — string
- $_namespace
—
string
Namespace of the asset. If none isset the default namespace is assumed. - $_notnull — Doctrine\DBAL\Schema\bool
- $_platformOptions — array
- $_precision — int
- $_quoted — Doctrine\DBAL\Schema\bool
- $_scale — int
- $_type — \Doctrine\DBAL\Types\Type
- $_unsigned — Doctrine\DBAL\Schema\bool
Methods
public
- __construct() — Create a new Column
- getAutoincrement()
- getColumnDefinition()
- getComment()
- getCustomSchemaOption()
- getCustomSchemaOptions()
- getDefault()
- getFixed()
- getLength()
- getNotnull()
- getPlatformOption()
- getPlatformOptions()
- getPrecision()
- getScale()
- getType()
- getUnsigned()
- hasCustomSchemaOption()
- hasPlatformOption()
- setAutoincrement()
- setColumnDefinition()
- setComment()
- setCustomSchemaOption()
- setCustomSchemaOptions()
- setDefault()
- setFixed()
- setLength()
- setNotnull()
- setOptions()
- setPlatformOption()
- setPlatformOptions()
- setPrecision()
- setScale()
- setType()
- setUnsigned()
- toArray()
- visit()
Inherited from Doctrine\DBAL\Schema\AbstractAsset
protected
- _generateIdentifierName() — Generate an identifier from a list of column names obeying a certain string length.
- _setName() — Set name of this asset
- isIdentifierQuoted() — Check if this identifier is quoted.
- trimQuotes() — Trim quotes from the identifier.
public
- getFullQualifiedName() — The normalized name is full-qualified and lowerspaced. Lowerspacing is actually wrong, but we have to do it to keep our sanity. If you are using database objects that only differentiate in the casing (FOO vs Foo) then you will NOT be able to use Doctrine Schema abstraction.
- getName() — Return name of this schema asset.
- getNamespaceName() — Get namespace name of this asset.
- getQuotedName() — Get the quoted representation of this asset but only if it was defined with one. Otherwise return the plain unquoted value as inserted.
- getShortestName() — The shortest name is stripped of the default namespace. All other namespaced elements are returned as full-qualified names.
- isInDefaultNamespace() — Is this asset in the default namespace?
- isQuoted() — Check if this asset's name is quoted