PHP Interface Horde_Kolab_Storage_Driver, horde

Copyright 2004-2016 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
Afficher le fichier Open project: horde/horde Interface Usage Examples

Méthodes publiques

Méthode Description
appendMessage ( string $folder, resource $msg ) : mixed Appends a message to the given folder.
create ( string $folder ) : null Create the specified folder.
createBackend ( ) : mixed Create the backend driver.
delete ( string $folder ) : null Delete the specified folder.
deleteAcl ( string $folder, string $user ) : null Delete the access rights for user on a folder.
deleteMessages ( string $folder, integer $uids ) : null Deletes messages from the specified folder.
expunge ( string $folder ) : null Expunges messages in the current folder.
fetchBodypart ( string $folder, array $uid, array $id ) : resource | string Retrieves a bodypart for the given message ID and mime part ID.
fetchComplete ( string $folder, array $uid ) : array Retrieves a complete message.
fetchHeaders ( string $folder, array $uid ) : Horde_Mime_Headers Retrieves the message headers.
fetchStructure ( string $folder, array $uids ) : array Retrieves the messages for the given message ids.
getAcl ( string $folder ) : array Retrieve the access rights for a folder.
getAnnotation ( string $folder, string $annotation ) : string Fetches the annotation from a folder.
getAuth ( ) : string Return the id of the user currently authenticated.
getBackend ( ) : mixed Returns the actual backend driver.
getId ( ) : string Return the unique connection id.
getMyAcl ( string $folder ) : string Retrieve the access rights the current user has on a folder.
getNamespace ( ) : Horde_Kolab_Storage_Driver_Namespace Retrieve the namespace information for this connection.
getParameters ( ) : array Return the connection parameters.
getStamp ( string $folder ) : Horde_Kolab_Storage_Folder_Stamp Returns a stamp for the current folder status. This stamp can be used to identify changes in the folder data.
getUids ( string $folder ) : array Returns the message ids of the messages in this folder.
hasAclSupport ( ) : boolean Does the backend support ACL?
hasCatenateSupport ( ) : boolean Checks if the backend supports CATENATE.
listAnnotation ( string $annotation ) : array Retrieves the specified annotation for the complete list of folders.
listFolders ( ) : array Retrieves a list of folders from the server.
moveMessage ( integer $uid, string $old_folder, string $new_folder ) : null Moves a message to a new folder.
rename ( string $old, string $new ) : null Rename the specified folder.
setAcl ( string $folder, string $user, string $acl ) : null Set the access rights for a folder.
setAnnotation ( string $folder, string $annotation, array $value ) : null Sets the annotation on a folder.
setBackend ( mixed $backend ) : null Set the backend driver.
status ( string $folder ) : array Returns the status of the current folder.

Method Details

appendMessage() public méthode

Appends a message to the given folder.
public appendMessage ( string $folder, resource $msg ) : mixed
$folder string The folder to append the message(s) to.
$msg resource The message to append.
Résultat mixed True or the UID of the new message in case the backend supports UIDPLUS.

create() public méthode

Create the specified folder.
public create ( string $folder ) : null
$folder string The folder to create.
Résultat null

createBackend() public méthode

Create the backend driver.
public createBackend ( ) : mixed
Résultat mixed The backend driver.

delete() public méthode

Delete the specified folder.
public delete ( string $folder ) : null
$folder string The folder to delete.
Résultat null

deleteAcl() public méthode

Delete the access rights for user on a folder.
public deleteAcl ( string $folder, string $user ) : null
$folder string The folder to act upon.
$user string The user to delete the ACL for
Résultat null

deleteMessages() public méthode

Deletes messages from the specified folder.
public deleteMessages ( string $folder, integer $uids ) : null
$folder string The folder to delete messages from.
$uids integer IMAP message ids.
Résultat null

expunge() public méthode

Expunges messages in the current folder.
public expunge ( string $folder ) : null
$folder string The folder to expunge.
Résultat null

fetchBodypart() public méthode

Retrieves a bodypart for the given message ID and mime part ID.
public fetchBodypart ( string $folder, array $uid, array $id ) : resource | string
$folder string The folder to fetch the messages from.
$uid array The message UID.
$id array The mime part ID.
Résultat resource | string The body part, as a stream resource or string.

fetchComplete() public méthode

Retrieves a complete message.
public fetchComplete ( string $folder, array $uid ) : array
$folder string The folder to fetch the messages from.
$uid array The message UID.
Résultat array The message encapsuled as an array that contains a Horde_Mime_Headers and a Horde_Mime_Part object.

fetchHeaders() public méthode

Retrieves the message headers.
public fetchHeaders ( string $folder, array $uid ) : Horde_Mime_Headers
$folder string The folder to fetch the message from.
$uid array The message UID.
Résultat Horde_Mime_Headers The message headers.

fetchStructure() public méthode

Retrieves the messages for the given message ids.
public fetchStructure ( string $folder, array $uids ) : array
$folder string The folder to fetch the messages from.
$uids array The message UIDs.
Résultat array An array of message structures parsed into Horde_Mime_Part instances.

getAcl() public méthode

Retrieve the access rights for a folder.
public getAcl ( string $folder ) : array
$folder string The folder to retrieve the ACL for.
Résultat array An array of rights.

getAnnotation() public méthode

Fetches the annotation from a folder.
public getAnnotation ( string $folder, string $annotation ) : string
$folder string The name of the folder.
$annotation string The annotation to get.
Résultat string The annotation value.

getAuth() public méthode

Return the id of the user currently authenticated.
public getAuth ( ) : string
Résultat string The id of the user that opened the connection.

getBackend() public méthode

If there is no driver set the driver should be constructed within this method.
public getBackend ( ) : mixed
Résultat mixed The backend driver.

getId() public méthode

Return the unique connection id.
public getId ( ) : string
Résultat string The connection id.

getMyAcl() public méthode

Retrieve the access rights the current user has on a folder.
public getMyAcl ( string $folder ) : string
$folder string The folder to retrieve the user ACL for.
Résultat string The user rights.

getNamespace() public méthode

Retrieve the namespace information for this connection.
public getNamespace ( ) : Horde_Kolab_Storage_Driver_Namespace
Résultat Horde_Kolab_Storage_Driver_Namespace The initialized namespace handler.

getParameters() public méthode

Return the connection parameters.
public getParameters ( ) : array
Résultat array The connection parameters.

getStamp() public méthode

Returns a stamp for the current folder status. This stamp can be used to identify changes in the folder data.
public getStamp ( string $folder ) : Horde_Kolab_Storage_Folder_Stamp
$folder string Return the stamp for this folder.
Résultat Horde_Kolab_Storage_Folder_Stamp A stamp indicating the current folder status.

getUids() public méthode

Returns the message ids of the messages in this folder.
public getUids ( string $folder ) : array
$folder string Check the status of this folder.
Résultat array The message ids.

hasAclSupport() public méthode

Does the backend support ACL?
public hasAclSupport ( ) : boolean
Résultat boolean True if the backend supports ACLs.

hasCatenateSupport() public méthode

Checks if the backend supports CATENATE.
public hasCatenateSupport ( ) : boolean
Résultat boolean True if the backend supports CATENATE.

listAnnotation() public méthode

Retrieves the specified annotation for the complete list of folders.
public listAnnotation ( string $annotation ) : array
$annotation string The name of the annotation to retrieve.
Résultat array An associative array combining the folder names as key with the corresponding annotation value.

listFolders() public méthode

Retrieves a list of folders from the server.
public listFolders ( ) : array
Résultat array The list of folders.

moveMessage() public méthode

Moves a message to a new folder.
public moveMessage ( integer $uid, string $old_folder, string $new_folder ) : null
$uid integer IMAP message id.
$old_folder string Source folder.
$new_folder string Target folder.
Résultat null

rename() public méthode

Rename the specified folder.
public rename ( string $old, string $new ) : null
$old string The folder to rename.
$new string The new name of the folder.
Résultat null

setAcl() public méthode

Set the access rights for a folder.
public setAcl ( string $folder, string $user, string $acl ) : null
$folder string The folder to act upon.
$user string The user to set the ACL for.
$acl string The ACL.
Résultat null

setAnnotation() public méthode

Sets the annotation on a folder.
public setAnnotation ( string $folder, string $annotation, array $value ) : null
$folder string The name of the folder.
$annotation string The annotation to set.
$value array The values to set
Résultat null

setBackend() public méthode

Set the backend driver.
public setBackend ( mixed $backend ) : null
$backend mixed The driver that should be used.
Résultat null

status() public méthode

Returns the status of the current folder.
public status ( string $folder ) : array
$folder string Check the status of this folder.
Résultat array An array that contains 'uidvalidity' and 'uidnext'.