mirror of
https://github.com/Icinga/icingaweb2-module-businessprocess.git
synced 2026-05-28 04:34:08 -04:00
Storage: clean up interface
This commit is contained in:
parent
8f1ce049de
commit
a03feb03c5
2 changed files with 39 additions and 17 deletions
|
|
@ -60,12 +60,7 @@ class LegacyStorage extends Storage
|
|||
}
|
||||
|
||||
/**
|
||||
* All processes readable by the current user
|
||||
*
|
||||
* The returned array has the form <process name> => <nice title>, sorted
|
||||
* by title
|
||||
*
|
||||
* @return array
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function listProcesses()
|
||||
{
|
||||
|
|
@ -85,12 +80,7 @@ class LegacyStorage extends Storage
|
|||
}
|
||||
|
||||
/**
|
||||
* All process names readable by the current user
|
||||
*
|
||||
* The returned array has the form <process name> => <process name> and is
|
||||
* sorted
|
||||
*
|
||||
* @return array
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function listProcessNames()
|
||||
{
|
||||
|
|
@ -110,9 +100,7 @@ class LegacyStorage extends Storage
|
|||
}
|
||||
|
||||
/**
|
||||
* All available process names, regardless of eventual restrictions
|
||||
*
|
||||
* @return array
|
||||
* @inheritdoc
|
||||
*/
|
||||
public function listAllProcessNames()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -28,10 +28,41 @@ abstract class Storage
|
|||
}
|
||||
|
||||
/**
|
||||
* All processes readable by the current user
|
||||
*
|
||||
* The returned array has the form <process name> => <nice title>, sorted
|
||||
* by title
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
abstract public function listProcesses();
|
||||
|
||||
/**
|
||||
* All process names readable by the current user
|
||||
*
|
||||
* The returned array has the form <process name> => <process name> and is
|
||||
* sorted
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
abstract public function listProcessesNames();
|
||||
|
||||
/**
|
||||
* All available process names, regardless of eventual restrictions
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
abstract public function listAllProcessNames();
|
||||
|
||||
/**
|
||||
* Whether a configuration with the given name exists
|
||||
*
|
||||
* @param $name
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
abstract public function hasProcess($name);
|
||||
|
||||
/**
|
||||
* @param $name
|
||||
* @return BusinessProcess
|
||||
|
|
@ -39,10 +70,13 @@ abstract class Storage
|
|||
abstract public function loadProcess($name);
|
||||
|
||||
/**
|
||||
* @param BusinessProcess $name
|
||||
* Store eventual changes applied to the given configuration
|
||||
*
|
||||
* @param BusinessProcess $config
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
abstract public function storeProcess(BusinessProcess $name);
|
||||
abstract public function storeProcess(BusinessProcess $config);
|
||||
|
||||
/**
|
||||
* @param $name
|
||||
|
|
|
|||
Loading…
Reference in a new issue