1<?php
2
3namespace Doctrine\DBAL\Schema;
4
5use Doctrine\DBAL\Platforms\AbstractPlatform;
6
7/**
8 * Marker interface for constraints.
9 */
10interface Constraint
11{
12    /**
13     * @return string
14     */
15    public function getName();
16
17    /**
18     * @return string
19     */
20    public function getQuotedName(AbstractPlatform $platform);
21
22    /**
23     * Returns the names of the referencing table columns
24     * the constraint is associated with.
25     *
26     * @return string[]
27     */
28    public function getColumns();
29
30    /**
31     * Returns the quoted representation of the column names
32     * the constraint is associated with.
33     *
34     * But only if they were defined with one or a column name
35     * is a keyword reserved by the platform.
36     * Otherwise the plain unquoted value as inserted is returned.
37     *
38     * @param AbstractPlatform $platform The platform to use for quotation.
39     *
40     * @return string[]
41     */
42    public function getQuotedColumns(AbstractPlatform $platform);
43}
44