From 649cca429c9476cec1026ec533bf3d559611b929 Mon Sep 17 00:00:00 2001 From: Sergei Morozov Date: Mon, 27 Sep 2021 18:09:50 -0700 Subject: [PATCH] Deprecate schema methods related to explicit foreign key indexes --- UPGRADE.md | 8 ++++++++ src/Schema/Schema.php | 2 ++ src/Schema/SchemaConfig.php | 10 +++++++++- 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/UPGRADE.md b/UPGRADE.md index a0a7327e6e8..955216026f1 100644 --- a/UPGRADE.md +++ b/UPGRADE.md @@ -8,6 +8,14 @@ awareness about deprecated code. # Upgrade to 3.2 +## Deprecated schema methods related to explicit foreign key indexes. + +The following methods have been deprecated: + +- `Schema::hasExplicitForeignKeyIndexes()`, +- `SchemaConfig::hasExplicitForeignKeyIndexes()`, +- `SchemaConfig::setExplicitForeignKeyIndexes()`. + ## Deprecated `Schema::getTableNames()`. The `Schema::getTableNames()` method has been deprecated. In order to obtain schema table names, diff --git a/src/Schema/Schema.php b/src/Schema/Schema.php index fe7186fd499..1cc84e160be 100644 --- a/src/Schema/Schema.php +++ b/src/Schema/Schema.php @@ -89,6 +89,8 @@ public function __construct( } /** + * @deprecated + * * @return bool */ public function hasExplicitForeignKeyIndexes() diff --git a/src/Schema/SchemaConfig.php b/src/Schema/SchemaConfig.php index 56d49c4a798..182451ddef5 100644 --- a/src/Schema/SchemaConfig.php +++ b/src/Schema/SchemaConfig.php @@ -7,7 +7,11 @@ */ class SchemaConfig { - /** @var bool */ + /** + * @deprecated + * + * @var bool + */ protected $hasExplicitForeignKeyIndexes = false; /** @var int */ @@ -20,6 +24,8 @@ class SchemaConfig protected $defaultTableOptions = []; /** + * @deprecated + * * @return bool */ public function hasExplicitForeignKeyIndexes() @@ -28,6 +34,8 @@ public function hasExplicitForeignKeyIndexes() } /** + * @deprecated + * * @param bool $flag * * @return void