Namespace and ClassPath rewrites

This commit is contained in:
2022-11-18 18:06:46 +01:00
parent c277aababc
commit 951ff14c5f
217 changed files with 1017 additions and 936 deletions

View File

@@ -0,0 +1,23 @@
<?php
namespace Core\Driver\SQL\Constraint;
use Core\Driver\SQL\Strategy\Strategy;
class ForeignKey extends Constraint {
private string $referencedTable;
private string $referencedColumn;
private ?Strategy $strategy;
public function __construct(string $columnName, string $refTable, string $refColumn, ?Strategy $strategy = NULL) {
parent::__construct($columnName);
$this->referencedTable = $refTable;
$this->referencedColumn = $refColumn;
$this->strategy = $strategy;
}
public function getReferencedTable(): string { return $this->referencedTable; }
public function getReferencedColumn(): string { return $this->referencedColumn; }
public function onDelete(): ?Strategy { return $this->strategy; }
}