OpenMediaVault  0.6 (Kralizec)
The open network attached storage solution
 All Classes Functions Variables Groups Pages
Public Member Functions | Protected Member Functions | List of all members
OMVModuleAbstract Class Reference
Inheritance diagram for OMVModuleAbstract:
OMVObject OMVModuleServiceAbstract

Public Member Functions

 getName ()
 
 setDirty ()
 
 setDirtyByName ($name)
 
 isDirty ()
 
- Public Member Functions inherited from OMVObject
 __construct ()
 
 getLastError ()
 

Protected Member Functions

 exec ($command, &$output=NULL)
 
 getAdminContext ()
 
 addTask ($id, $name, $params)
 
 execTasks ($id)
 
- Protected Member Functions inherited from OMVObject
 setLastError ($error)
 
 debug ()
 

Detailed Description

This file is part of OpenMediaVault.

License:
http://www.gnu.org/licenses/gpl.html GPL Version 3
Author
Volker Theile volke.nosp@m.r.th.nosp@m.eile@.nosp@m.open.nosp@m.media.nosp@m.vaul.nosp@m.t.org

OpenMediaVault is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or any later version.

OpenMediaVault is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with OpenMediaVault. If not, see http://www.gnu.org/licenses/. The core module class.

Member Function Documentation

OMVModuleAbstract::addTask (   $id,
  $name,
  $params 
)
finalprotected

Add a task that can be performed at a later date.

Parameters
idThe identifier of the task type.
nameThe name of the class method to be executed.
paramsThe parameters passed to the method when it is executed.
Returns
None.
Exceptions
E_MISC_FAILURE
OMVModuleAbstract::exec (   $command,
$output = NULL 
)
finalprotected

Helper function to execute an external program.

Parameters
commandThe command that will be executed.
outputIf the output argument is present, then the specified array will be filled with every line of output from the command. Trailing whitespace, such as
, is not included in this array.
Returns
The exit code of the command.
OMVModuleAbstract::execTasks (   $id)
finalprotected

Execute the tasks with the given identifier.

Parameters
idThe identifier of the tasks to be executed.
Returns
None.
OMVModuleAbstract::getAdminContext ( )
finalprotected

Helper function to get the administrator context.

Returns
The administrator context object.
OMVModuleAbstract::getName ( )
abstract

Get the name of the module.

Returns
The name of the module.
OMVModuleAbstract::isDirty ( )
final

Helper function to check whether the module is marked dirty.

Returns
TRUE if the module is marked dirty, otherwise FALSE.
OMVModuleAbstract::setDirty ( )
final

Helper function to mark this module as dirty.

Returns
The list of dirty modules.
OMVModuleAbstract::setDirtyByName (   $name)
final

Helper function to mark the given module as dirty.

Parameters
nameThe name of the module.
Returns
The list of dirty modules.

The documentation for this class was generated from the following file: