Commit | Line | Data |
---|---|---|
6a488035 TO |
1 | <?php |
2 | /* | |
3 | +--------------------------------------------------------------------+ | |
bc77d7c0 | 4 | | Copyright CiviCRM LLC. All rights reserved. | |
6a488035 | 5 | | | |
bc77d7c0 TO |
6 | | This work is published under the GNU AGPLv3 license with some | |
7 | | permitted exceptions and without any warranty. For full license | | |
8 | | and copyright information, see https://civicrm.org/licensing | | |
6a488035 | 9 | +--------------------------------------------------------------------+ |
d25dd0ee | 10 | */ |
6a488035 TO |
11 | |
12 | /** | |
13 | * The extension manager handles installing, disabling enabling, and | |
14 | * uninstalling extensions. | |
15 | * | |
16 | * @package CRM | |
ca5cec67 | 17 | * @copyright CiviCRM LLC https://civicrm.org/licensing |
6a488035 TO |
18 | */ |
19 | interface CRM_Extension_Manager_Interface { | |
7b966967 | 20 | |
2d7fd075 TO |
21 | /** |
22 | * Perform type-specific installation logic (before marking the | |
23 | * extension as installed or clearing the caches). | |
24 | * | |
25 | * @param CRM_Extension_Info $info | |
26 | */ | |
6a488035 | 27 | public function onPreInstall(CRM_Extension_Info $info); |
2d7fd075 TO |
28 | |
29 | /** | |
30 | * Perform type-specific installation logic (after marking the | |
31 | * extension as installed but before clearing the caches). | |
32 | * | |
33 | * @param CRM_Extension_Info $info | |
34 | */ | |
6a488035 TO |
35 | public function onPostInstall(CRM_Extension_Info $info); |
36 | ||
2d7fd075 TO |
37 | /** |
38 | * Perform type-specific installation logic (after marking the | |
39 | * extension as installed and clearing the caches). | |
40 | * | |
41 | * @param CRM_Extension_Info $info | |
42 | */ | |
43 | public function onPostPostInstall(CRM_Extension_Info $info); | |
44 | ||
e0ef6999 EM |
45 | /** |
46 | * @param CRM_Extension_Info $info | |
e0ef6999 | 47 | */ |
6a488035 | 48 | public function onPreEnable(CRM_Extension_Info $info); |
e0ef6999 EM |
49 | |
50 | /** | |
51 | * @param CRM_Extension_Info $info | |
e0ef6999 | 52 | */ |
6a488035 TO |
53 | public function onPostEnable(CRM_Extension_Info $info); |
54 | ||
55 | /** | |
56 | * Perform type-specific removal logic (before updating the extension | |
57 | * row in the "civicrm_extension" table). | |
03e04002 | 58 | * |
f41911fd TO |
59 | * @param CRM_Extension_Info $info |
60 | * May be generated from xml or DB (which is lossy). | |
6a488035 TO |
61 | * @see CRM_Extension_Manager::createInfoFromDB |
62 | */ | |
63 | public function onPreDisable(CRM_Extension_Info $info); | |
64 | ||
65 | /** | |
66 | * Perform type-specific removal logic (after updating the extension | |
67 | * row in the "civicrm_extension" table). | |
68 | * | |
f41911fd TO |
69 | * @param CRM_Extension_Info $info |
70 | * May be generated from xml or DB (which is lossy). | |
6a488035 TO |
71 | * @see CRM_Extension_Manager::createInfoFromDB |
72 | */ | |
73 | public function onPostDisable(CRM_Extension_Info $info); | |
74 | ||
75 | /** | |
76 | * Perform type-specific removal logic (before removing the extension | |
77 | * row in the "civicrm_extension" table). | |
78 | * | |
f41911fd TO |
79 | * @param CRM_Extension_Info $info |
80 | * May be generated from xml or DB (which is lossy). | |
6a488035 TO |
81 | * @see CRM_Extension_Manager::createInfoFromDB |
82 | */ | |
83 | public function onPreUninstall(CRM_Extension_Info $info); | |
84 | ||
85 | /** | |
86 | * Perform type-specific removal logic (after removing the extension | |
87 | * row in the "civicrm_extension" table). | |
88 | * | |
f41911fd TO |
89 | * @param CRM_Extension_Info $info |
90 | * May be generated from xml or DB (which is lossy). | |
6a488035 TO |
91 | * @see CRM_Extension_Manager::createInfoFromDB |
92 | */ | |
93 | public function onPostUninstall(CRM_Extension_Info $info); | |
94 | ||
e0ef6999 EM |
95 | /** |
96 | * @param CRM_Extension_Info $oldInfo | |
97 | * @param CRM_Extension_Info $newInfo | |
e0ef6999 | 98 | */ |
6a488035 | 99 | public function onPreReplace(CRM_Extension_Info $oldInfo, CRM_Extension_Info $newInfo); |
e0ef6999 EM |
100 | |
101 | /** | |
102 | * @param CRM_Extension_Info $oldInfo | |
103 | * @param CRM_Extension_Info $newInfo | |
95ea96be EM |
104 | */ |
105 | public function onPostReplace(CRM_Extension_Info $oldInfo, CRM_Extension_Info $newInfo); | |
96025800 | 106 | |
6a488035 | 107 | } |