| 1 | <?php |
| 2 | namespace Civi\Angular; |
| 3 | |
| 4 | interface ChangeSetInterface { |
| 5 | |
| 6 | /** |
| 7 | * Get the symbolic name of the changeset. |
| 8 | * |
| 9 | * @return string |
| 10 | */ |
| 11 | public function getName(); |
| 12 | |
| 13 | /** |
| 14 | * Declare that $module requires additional dependencies. |
| 15 | * |
| 16 | * @param string $module |
| 17 | * @param string|array $dependencies |
| 18 | * @return ChangeSet |
| 19 | */ |
| 20 | public function requires($module, $dependencies); |
| 21 | |
| 22 | /** |
| 23 | * Declare a change to HTML. |
| 24 | * |
| 25 | * @param string $file |
| 26 | * A file name, wildcard, or regex. |
| 27 | * Ex: '~/crmHello/intro.html' (filename) |
| 28 | * Ex: '~/crmHello/*.html' (wildcard) |
| 29 | * Ex: ';(Edit|List)Ctrl\.html$;' (regex) |
| 30 | * @param callable $callback |
| 31 | * Function which accepts up to two parameters: |
| 32 | * - phpQueryObject $doc |
| 33 | * - string $path |
| 34 | * @return ChangeSet |
| 35 | */ |
| 36 | public function alterHtml($file, $callback); |
| 37 | |
| 38 | } |