eZ Publish  [4.2]
eZCollaborationItemHandler Class Reference

The class eZCollaborationItemHandler does. More...

+ Inheritance diagram for eZCollaborationItemHandler:

List of all members.

Public Member Functions

 attribute ($attribute)
 attributes ()
 classes ()
 content ($collaborationItem)
 contentAttribute ($collaborationItem, $attribute)
 customInput ($name)
 eZCollaborationItemHandler ($typeIdentifier, $typeName, $parameters=array())
 handleCustomAction ($module, $collaborationItem)
 hasAttribute ($attr)
 hasContentAttribute ($collaborationItem, $attribute)
 hasCustomInput ($name)
 isCustomAction ($name)
 messageCount ($collaborationItem)
 notificationCollectionHandling ()
 notificationParticipantTemplate ($participantRole)
 notificationTypes ()
 participantRoleString ($participantRole)
 participantTypeString ($participantType)
 readItem ($collaborationItem, $viewMode=false)
 removeItem ($collaborationItem)
 roleName ($collaborationID, $roleID)
 template ($viewMode)
 templateName ()
 title ($collaborationItem)
 unreadMessageCount ($collaborationItem)
 useMessages ($collaborationItem)

Static Public Member Functions

static activeHandlers ()
static defaultRepositories ()
static extensionRepositories ()
static fetchList ()
static handleCollaborationEvent ($event, $item, &$parameters)
static handlerRepositories ()
static ini ()
static instantiate ($handler, $repositories=false)

Public Attributes

 $Info
const NOTIFICATION_COLLECTION_ONE_FOR_ALL = 1
const NOTIFICATION_COLLECTION_PER_PARTICIPATION_ROLE = 3
const NOTIFICATION_COLLECTION_PER_USER = 2

Detailed Description

The class eZCollaborationItemHandler does.

Definition at line 40 of file ezcollaborationitemhandler.php.


Member Function Documentation

static eZCollaborationItemHandler::activeHandlers ( ) [static]
Returns:
an array with handler identifiers that are considered active.

Definition at line 511 of file ezcollaborationitemhandler.php.

Referenced by fetchList().

eZCollaborationItemHandler::attribute ( attribute)
Returns:
the attribute $attribute if it exists or null.

Definition at line 88 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::attributes ( )

Definition at line 71 of file ezcollaborationitemhandler.php.

Referenced by hasAttribute().

eZCollaborationItemHandler::classes ( )
Returns:
a list of classes this handler supports.

Definition at line 302 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::content ( collaborationItem)
Returns:
the content of the collaborationitem.
Note:
This is specific to the item type, some might return an array and others an object.

Reimplemented in eZApproveCollaborationHandler.

Definition at line 421 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::contentAttribute ( collaborationItem,
attribute 
)
Returns:
the attribute $attribute if it exists in the content data or null.

Definition at line 287 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::customInput ( name)
Returns:
value of the custom input variable $name.

Definition at line 459 of file ezcollaborationitemhandler.php.

Referenced by eZApproveCollaborationHandler\handleCustomAction().

static eZCollaborationItemHandler::defaultRepositories ( ) [static]
Returns:
an array with directories which acts as default collaboration repositories.
See also:
handlerRepositories

Definition at line 471 of file ezcollaborationitemhandler.php.

Referenced by handlerRepositories().

static eZCollaborationItemHandler::extensionRepositories ( ) [static]
Returns:
an array with directories which acts as collaboration extension repositories.
See also:
handlerRepositories

Definition at line 482 of file ezcollaborationitemhandler.php.

Referenced by handlerRepositories().

eZCollaborationItemHandler::eZCollaborationItemHandler ( typeIdentifier,
typeName,
parameters = array() 
)

Initializes the handler with identifier and name. Optional parameters can be placed in $parameters.

Definition at line 53 of file ezcollaborationitemhandler.php.

Referenced by eZApproveCollaborationHandler\eZApproveCollaborationHandler().

static eZCollaborationItemHandler::fetchList ( ) [static]
Returns:
a list of collaboration handler objects.
See also:
instantiate, activeHandlers

Definition at line 573 of file ezcollaborationitemhandler.php.

Referenced by eZCollaborationNotificationHandler\collaborationHandlers().

static eZCollaborationItemHandler::handleCollaborationEvent ( event,
item,
&$  parameters 
) [static]

Handles a notification event for collaboration items.

Note:
The default implementation sends out a generic email.
Transaction unsafe. If you call several transaction unsafe methods you must enclose the calls within a db transaction; thus within db->begin and db->commit.

Definition at line 135 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::handleCustomAction ( module,
collaborationItem 
)

This function is called when a custom action is executed for a specific collaboration item. The module object is available in $module and the item in $collaborationItem.

Note:
The default does nothing, the function must be reimplemented in real handlers.
See also:
isCustomAction

Reimplemented in eZApproveCollaborationHandler.

Definition at line 432 of file ezcollaborationitemhandler.php.

static eZCollaborationItemHandler::handlerRepositories ( ) [static]
Returns:
an array with directories which acts as collaboration repositories.
See also:
defaultRepositories, extensionRepositories

Definition at line 493 of file ezcollaborationitemhandler.php.

Referenced by fetchList(), and instantiate().

eZCollaborationItemHandler::hasAttribute ( attr)
Returns:
true if the attribute $attribute exists.

Definition at line 80 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::hasContentAttribute ( collaborationItem,
attribute 
)
Returns:
true if the attribute $attribute exists in the content data.

Definition at line 274 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::hasCustomInput ( name)
Returns:
true if the custom input variable $name exists.

Definition at line 449 of file ezcollaborationitemhandler.php.

static eZCollaborationItemHandler::ini ( ) [static]
Returns:
the ini object which handles collaboration settings.

Definition at line 385 of file ezcollaborationitemhandler.php.

Referenced by activeHandlers(), defaultRepositories(), and extensionRepositories().

static eZCollaborationItemHandler::instantiate ( handler,
repositories = false 
) [static]
Returns:
a unique instance of the handler for the identifier $handler. If $repositories is left out it will use the handlerRepositories.

Definition at line 522 of file ezcollaborationitemhandler.php.

Referenced by fetchList(), and eZCollaborationItem\handler().

eZCollaborationItemHandler::isCustomAction ( name)
Returns:
true if the current custom action is $name.

Definition at line 439 of file ezcollaborationitemhandler.php.

Referenced by eZApproveCollaborationHandler\handleCustomAction().

eZCollaborationItemHandler::messageCount ( collaborationItem)
Returns:
the number of messages for the collaboration item $collaborationItem.
Note:
The default implementation returns 0, if you want real counts the handler must reimplement this function.

Reimplemented in eZApproveCollaborationHandler.

Definition at line 348 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::notificationCollectionHandling ( )
Returns:
how the handler wants collections to be made.
Note:
The default is to create one collection for all participants.

Definition at line 118 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::notificationParticipantTemplate ( participantRole)

Reimplemented in eZApproveCollaborationHandler.

Definition at line 123 of file ezcollaborationitemhandler.php.

Referenced by handleCollaborationEvent().

eZCollaborationItemHandler::notificationTypes ( )
Returns:
what kind of notification types this handler supports. Can either return an array or a boolean. If it returns true the handler supports notification but does not have subnotifications. If it returns false the handler does not support notificiation. If it returns an array the array contains a list associative arrays each containing a name and value entry.

Definition at line 109 of file ezcollaborationitemhandler.php.

Referenced by attribute().

eZCollaborationItemHandler::participantRoleString ( participantRole)
Returns:
a textual representation of the participant role id $participantRole
Note:
It's up to the real handlers to implement this if they use custom participation roles.

Definition at line 403 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::participantTypeString ( participantType)
Returns:
a textual representation of the participant type id $participantType
Note:
It's up to the real handlers to implement this if they use custom participation types.

Definition at line 394 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::readItem ( collaborationItem,
viewMode = false 
)

This is called whenever the item is considered to be read, it can be used by handlers to update when the item was last read.

Note:
Default implementation does nothing.

Reimplemented in eZApproveCollaborationHandler.

Definition at line 368 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::removeItem ( collaborationItem)

This is called whenever a collaboration item is to be removed. Reimplementing this function can be used to cleanup external tables or other resources.

Definition at line 377 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::roleName ( collaborationID,
roleID 
)
Returns:
a description of the role id $roleID in the current language.
Note:
It's up to the real handlers to implement this if they use custom participation roles.

Definition at line 412 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::template ( viewMode)
Returns:
the template name for the viewmode $viewmode.

Definition at line 310 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::templateName ( )
Returns:
the name of the template file for this handler. Default is to append .tpl to the identifier.

Definition at line 320 of file ezcollaborationitemhandler.php.

Referenced by template().

eZCollaborationItemHandler::title ( collaborationItem)
Returns:
the title of the collaboration item.

Reimplemented in eZApproveCollaborationHandler.

Definition at line 328 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::unreadMessageCount ( collaborationItem)
Returns:
the number of unread messages for the collaboration item $collaborationItem.
Note:
The default implementation returns 0, if you want real counts the handler must reimplement this function.

Reimplemented in eZApproveCollaborationHandler.

Definition at line 358 of file ezcollaborationitemhandler.php.

eZCollaborationItemHandler::useMessages ( collaborationItem)
Returns:
true if the collaboration item $collaborationItem supports messages.
Note:
The handler can either determine this by passing $useMessages to the constructor or by reimplementing this function to do it per item.

Definition at line 338 of file ezcollaborationitemhandler.php.


Member Data Documentation

eZCollaborationItemHandler::$Info

Definition at line 591 of file ezcollaborationitemhandler.php.


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