Doctrine


Doctrine\DBAL\Schema\ForeignKeyConstraint
/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 26

Class ForeignKeyConstraint

Class:ForeignKeyConstraint - Superclass: AbstractAsset
AbstractAsset
⌊ ForeignKeyConstraint
All Implemented Interfaces:
Constraint

public class ForeignKeyConstraint
extends AbstractAsset

The abstract asset allows to reset the name of all assets without publishing this to the public userland.

This encapsulation hack is necessary to keep a consistent state of the database schema. Say we have a list of tables array($tableName => Table($tableName)); if you want to rename the table, you have to make sure

License:
http://www.opensource.org/licenses/lgpl-license.php LGPL
See Also:
www.doctrine-project.org
Since:
2.0
Version:
$Revision$
Author:
Benjamin Eberlei

Field Summary
protected string

$_cascade

protected array

$_foreignColumnNames

protected string

$_foreignTableName

protected array

$_localColumnNames

protected Table

$_localTable

protected array

$_options

Fields inherited from Doctrine\DBAL\Schema\AbstractAsset
_name
Constructor Summary

ForeignKeyConstraint(array localColumnNames, string foreignTableName, array foreignColumnNames, string|null name, mixed options, string cascade)

Method Summary
void

getColumns()

array

getForeignColumns()

string

getForeignTableName()

array

getLocalColumns()

string

getLocalTableName()

void

getOption(mixed name)

void

hasOption(mixed name)

string|null

onDelete()

Foreign Key onDelete status

string|null

onUpdate()

Foreign Key onUpdate status

void

setLocalTable(Table table)

Methods inherited from Doctrine\DBAL\Schema\AbstractAsset
getName

Field Detail

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 51

_cascade

protected string $_cascade = ''


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 46

_foreignColumnNames

protected array $_foreignColumnNames


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 41

_foreignTableName

protected string $_foreignTableName


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 36

_localColumnNames

protected array $_localColumnNames


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 31

_localTable

protected Table $_localTable


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 56

_options

protected array $_options


Constructor Detail

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 66

ForeignKeyConstraint

public ForeignKeyConstraint(array localColumnNames, string foreignTableName, array foreignColumnNames, string|null name, mixed options, string cascade)


Method Detail

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 99

getColumns

public void getColumns()

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 115

getForeignColumns

public array getForeignColumns()


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 107

getForeignTableName

public string getForeignTableName()


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 94

getLocalColumns

public array getLocalColumns()


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 78

getLocalTableName

public string getLocalTableName()


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 125

getOption

public void getOption(mixed name)

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 120

hasOption

public void hasOption(mixed name)

/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 145

onDelete

public string|null onDelete()

Foreign Key onDelete status


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 135

onUpdate

public string|null onUpdate()

Foreign Key onUpdate status


/Doctrine/DBAL/Schema/ForeignKeyConstraint.php at line 86

setLocalTable

public void setLocalTable(Table table)


Doctrine