private static function Contexts::canSwitch in Hook Update Deploy Tools 7
Check availability of modules & methods needed to enable/disable a context.
Any items called in here throw exceptions if they fail
4 calls to Contexts::canSwitch()
- Contexts::checkDisabled in src/
Contexts.php - Check to see if contexts are actually disabled.
- Contexts::checkEnabled in src/
Contexts.php - Check to see if the contexts are actually enabled.
- Contexts::disable in src/
Contexts.php - Disables an array of contexts and checks to make sure they were disabled.
- Contexts::enable in src/
Contexts.php - Enables an array of contexts and checks to make sure they were enabled.
File
- src/
Contexts.php, line 201
Class
- Contexts
- Public method for managing Contexts that verifies the changes.
Namespace
HookUpdateDeployToolsCode
private static function canSwitch() {
Check::canUse('context');
Check::canCall('context_load');
Check::canCall('context_enabled_contexts');
Check::canUse('ctools');
ctools_include('export');
Check::canCall('ctools_export_crud_disable');
Check::canCall('ctools_export_crud_enable');
}