Available methods for Opravila (nag)
Application: nag
Prefix: tasks
Name: Opravila
Example:
// inside ObalaNET 1
$result = $registry->call("tasks/METHOD_NAME", array(PARAMETERS));
// inside ObalaNET 2
$result = $registry->callByPackage("nag", "METHOD_NAME", array(PARAMETERS));
// XML RPC (http://pear.php.net/package/XML_RPC)
require_once "XML/RPC.php";
$msg = new XML_RPC_Message("tasks.METHOD_NAME", PARAMETERS);
$cli = new XML_RPC_Client("/rpc.php", "http://HOSTNAME");
$resp = $cli->send($msg);
$val = $resp->value();
$result = XML_RPC_decode($val);
// XML RPC 2 (http://pear.php.net/package/XML_RPC2)
require_once "XML/RPC2/Client.php";
$client = XML_RPC2_Client::create("http://HOSTNAME/rpc.php", array("prefix" => "tasks"));
$result = $client->METHOD_NAME(PARAMETER_1, PARAMETER_2, PARAMETER_3 ...);
// Python Example (http://wiki.horde.org/XmlRpcPythonHowTo)
import xmlrpclib
url = "http://HOSTNAME/rpc.php"
server = xmlrpclib.ServerProxy(url, verbose=0)
result = server.tasks.METHOD_NAME(PARAMETER_1, PARAMETER_2, PARAMETER_3 ...)
More detailed examples: http://www.drugapisarna.si/wicked/ZunanjaUporaba
perms - Nag external API int...
Call: (mixed) perms()
Description :
Nag external API interface.
$Horde: nag/lib/api.php,v 1.158 2007/12/28 13:36:25 jan Exp $
This file defines Nag's external API interface. Other applications can
interact with Nag through this API.
removeUserData - ...
Call: (mixed) removeUserData((mixed) user)
Parameters:
| Type |
Name |
Documentation |
| mixed |
user |
browse - Browse through Nag's...
Call: (array) browse( [ (string) path, (array) properties ] )
Description :
Browse through Nag's object tree.
'icon', and 'browseable'.
Parameters:
| Type |
Name |
Documentation |
| string |
path |
The level of the tree to browse. |
| array |
properties |
The item properties to return. Defaults to 'name', |
put - Saves a file into th...
Call: (array) put((string) path, (string) content, (string) content_type)
Description :
Saves a file into the Nag tree.
Parameters:
| Type |
Name |
Documentation |
| string |
path |
The path where to PUT the file. |
| string |
content |
The file content. |
| string |
content_type |
The file's content type. |
path_delete - Deletes a file from ...
Call: (mixed) path_delete((string) path)
Description :
Deletes a file from the Nag tree.
Parameters:
| Type |
Name |
Documentation |
| string |
path |
The path to the file. |
addTasklist - ...
Call: (mixed) addTasklist((mixed) name [ , (mixed) description ] )
Parameters:
| Type |
Name |
Documentation |
| mixed |
name |
| mixed |
description |
listTasklists - Defaults to false....
Call: (array) listTasklists((boolean) owneronly, (integer) permission)
Description :
Defaults to false.
Parameters:
| Type |
Name |
Documentation |
| boolean |
owneronly |
Only return tasklists that this user owns? |
| integer |
permission |
The permission to filter tasklists by. |
listTasks - ...
Call: (mixed) listTasks( [ (mixed) sortby, (mixed) sortdir ] )
Parameters:
| Type |
Name |
Documentation |
| mixed |
sortby |
| mixed |
sortdir |
listAlarms - Lists alarms for a g...
Call: (array) listAlarms((integer) time [ , (string) user ] )
Description :
Lists alarms for a given moment.
Parameters:
| Type |
Name |
Documentation |
| integer |
time |
The time to retrieve alarms for. |
| string |
user |
The user to retreive alarms for. All users if null. |
list - Returns an array of ...
Call: (array) list( [ (mixed) tasklist ] )
Description :
Returns an array of UIDs for all tasks that the current user is authorized
to see.
the user can access.
Parameters:
| Type |
Name |
Documentation |
| mixed |
tasklist |
The tasklist or an array of taskslists to list. |
listBy - Returns an array of ...
Call: (array) listBy((string) action, (integer) timestamp [ , (string) tasklist ] )
Description :
Returns an array of UIDs for tasks that have had $action happen since
$timestamp.
user's default tasklist will be used.
Parameters:
| Type |
Name |
Documentation |
| string |
action |
n The action to check for - add, modify, or delete. |
| integer |
timestamp |
The time to start the search. |
| string |
tasklist |
t The tasklist to be used. If 'null', the |
getActionTimestamp - Returns the timestam...
Call: (integer) getActionTimestamp((string) uid, (string) action [ , (string) tasklist ] )
Description :
Returns the timestamp of an operation for a given uid an action.
user's default tasklist will be used.
Parameters:
| Type |
Name |
Documentation |
| string |
uid |
The uid to look for. |
| string |
action |
The action to check for - add, modify, or delete. |
| string |
tasklist |
The tasklist to be used. If 'null', the |
import - Imports one or more ...
Call: (string) import((string) content, (string) contentType [ , (string) tasklist ] )
Description :
Imports one or more tasks represented in the specified content type.
If a UID is present in the content and the task is already in the
database, a replace is performed rather than an add.
text/x-icalendar
text/x-vcalendar
text/x-vtodo
imported. If 'null', the user's default
tasklist will be used.
or PEAR_Error on failure.
Parameters:
| Type |
Name |
Documentation |
| string |
content |
The content of the task. |
| string |
contentType |
What format is the data in? Currently supports: |
| string |
tasklist |
The tasklist into which the task will be |
export - Exports a task, iden...
Call: (string) export((string) uid, (string) contentType)
Description :
Exports a task, identified by UID, in the requested content type.
A string with one of:
text/calendar - (VCALENDAR 2.0. Recommended as this is specified in
rfc2445)
text/x-vtodo - (seems to be used by horde only. Do we need this?)
text/x-vcalendar - (old VCALENDAR 1.0 format. Still in wide use)
text/x-icalendar
Parameters:
| Type |
Name |
Documentation |
| string |
uid |
Identify the task to export. |
| string |
contentType |
What format should the data be in? |
exportTasklist - Exports a tasklist i...
Call: (string) exportTasklist((string) tasklist, (string) contentType)
Description :
Exports a tasklist in the requested content type.
A string with one of:
text/calendar (VCALENDAR 2.0. Recommended as
this is specified in rfc2445)
text/x-vtodo Seems to be used by horde only.
Do we need this?
text/x-vcalendar (old VCALENDAR 1.0 format.
Still in wide use)
text/x-icalendar
Parameters:
| Type |
Name |
Documentation |
| string |
tasklist |
The tasklist to export. |
| string |
contentType |
What format should the data be in? |
delete - Deletes a task ident...
Call: (boolean) delete((array) uid)
Description :
Deletes a task identified by UID.
or an array.
Parameters:
| Type |
Name |
Documentation |
| array |
uid |
Identify the task to delete, either a single UID |
replace - Replaces the task id...
Call: (boolean) replace((string) uid, (string) content, (string) contentType)
Description :
Replaces the task identified by UID with the content represented in the
specified content type.
If you want to replace multiple tasks with the UID specified in the
VCALENDAR data, you may use _nag_import instead. This automatically does a
replace if existings UIDs are found.
- text/x-icalendar
- text/x-vcalendar
- text/x-vtodo
- text/calendar
Parameters:
| Type |
Name |
Documentation |
| string |
uid |
Identify the task to replace. |
| string |
content |
The content of the task. |
| string |
contentType |
What format is the data in? Currently supports: |
listCostObjects - Lists active tasks a...
Call: (mixed) listCostObjects((mixed) criteria)
Description :
Lists active tasks as cost objects.
Parameters:
| Type |
Name |
Documentation |
| mixed |
criteria |
listTimeObjectCategories - ...
Call: (mixed) listTimeObjectCategories()
listTimeObjects - Lists active tasks a...
Call: (mixed) listTimeObjects((array) categories, (mixed) start, (mixed) end)
Description :
Lists active tasks as time objects.
Parameters:
| Type |
Name |
Documentation |
| array |
categories |
The time categories (from listTimeObjectCategories) to list. |
| mixed |
start |
The start date of the period. |
| mixed |
end |
The end date of the period. |