Extensions - Define the upgrader base class
authorTim Otten <totten@civicrm.org>
Sat, 17 Apr 2021 06:23:20 +0000 (23:23 -0700)
committerTim Otten <totten@civicrm.org>
Wed, 21 Apr 2021 06:28:31 +0000 (23:28 -0700)
commit31236900a84338576791324d9c0650ce86871a62
treef68d60375d0787ced2e2c7a2b147062cdf39596b
parentce9781c51cd49082ed097b29979d74cee858b316
Extensions - Define the upgrader base class

This class is based on refactoring the civix template.

Major sections have been split out into traits.  This should make it more
readable (and potentially make it easier to remix).

This base-class should generally provide an equivalent DX for subclass authors:

* Variables have the same names.
* Most method signatures are identical (e.g.  `executeFoo()`)
* Some methods have been redeclared in equivalent form (`addTask()` - using splat instead `func_get_args()`).
* Two internal functions have slightly diff signatures (`enqueuePendingRevisions()`, `_queueAdapter()``).
CRM/Extension/Upgrader/Base.php [new file with mode: 0644]
CRM/Extension/Upgrader/IdentityTrait.php [new file with mode: 0644]
CRM/Extension/Upgrader/QueueTrait.php [new file with mode: 0644]
CRM/Extension/Upgrader/RevisionsTrait.php [new file with mode: 0644]
CRM/Extension/Upgrader/TasksTrait.php [new file with mode: 0644]