Skip to content
Snippets Groups Projects
Unverified Commit 17e41003 authored by colemanw's avatar colemanw Committed by GitHub
Browse files

Merge pull request #32597 from totten/master-schema-trait-depr

(NFC) SchemaTrait - Flag as deprecated
parents 1b6bf5a9 d595be04
Branches
No related tags found
No related merge requests found
......@@ -10,7 +10,22 @@
*/
/**
* The SchemaTrait provides utilities for altering tables during an upgrade.
* (Semi-Deprecated) The SchemaTrait provides utilities for altering tables during an upgrade.
* It may be useful for some niche refactorings, but it is not recommended for new code/functionality.
* For new code, use `E::schema()` (aka `SchemaHelper.php`).
*
* `SchemaTrait` and `E::schema()` both provide a list of helper functions, but `E::schema()`
* is more adaptable:
*
* - `E::schema()` can be called in more ways. It can be called by full-size Upgrader classes,
* by standalone lifecycle-hooks, and/or by sysadmin scripts [cv].
* - `E::schema()` is amenable to backports. `civix upgrade` can give you a new
* version of `E::schema()` even if the extension targets older `<ver>`sions of CiviCRM.
*
* `SchemaTrait` may have some niche uses when refactoring `CRM_Extension_Upgrader_Base` (or a
* comparable class). This kind of use-case should be extremely rare.
*
* @deprecated
*/
trait CRM_Extension_Upgrader_SchemaTrait {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment