OpenMediaVault
0.6 (Kralizec)
The open network attached storage solution
|
Static Public Member Functions | |
static | exec ($service, $method, $params, $context, $mode=OMV_RPC_MODE_LOCAL, $restoreSrvEnv=FALSE) |
Additional Inherited Members | |
![]() | |
__construct () | |
getLastError () | |
![]() | |
setLastError ($error) | |
debug () | |
This file is part of OpenMediaVault.
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/. This class provides methods regarding remote procedure calls.
|
static |
Execute the given RPC.
service | The name of the service. |
method | The name of the method. |
params | The parameters hash object to be passed to the method of the given service. |
context | The context hash object of the caller containing the fields username and role. |
mode | The mode how to execute this RPC. The following modes are available:
|
restoreSrvEnv | Restore various web server and execution environment information. This might be helpful in some cases if these information are required in the engine backend. Note, this only takes action when mode is OMV_RPC_MODE_REMOTE. Defauts to FALSE. |
E_RPC_SERVICE_NOT_FOUND | |
E_RPC_SERVICE_METHOD_NOT_EXISTS | |
E_MISC_FAILURE | |
E_ENGINED_CREATE_SOCKET | |
E_ENGINED_CONNECT_SOCKET | |
E_ENGINED_WRITE_SOCKET | |
E_ENGINED_READ_SOCKET |