PHP 클래스 IMP_Imap, horde

저자: Michael Slusarz ([email protected])
상속: implements Serializable
파일 보기 프로젝트 열기: horde/horde 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$_backends array Cached backend configuration.
$_changed boolean Has this object changed?
$_config IMP_Imap_Config Backend config.
$_id string Object identifier.
$_ob Horde_Imap_Client_Base The IMAP client object.
$_temp array Temporary data cache (destroyed at end of request).

공개 메소드들

메소드 설명
__call ( string $method, array $params ) : mixed All other calls to this class are routed to the underlying Horde_Imap_Client_Base object.
__construct ( string $id ) Constructor.
__get ( $key )
__toString ( )
access ( integer $right ) : boolean Checks access rights for a server.
accessCompose ( integer $right, integer $data ) : boolean Checks compose access rights for a server.
createBaseImapObject ( string $username, string $password, string $skey ) : Horde_Imap_Client_Base Create the base Horde_Imap_Client object (from an entry in backends.php).
createImapObject ( array $config, boolean $imap = true ) : Horde_Imap_Client_Base Create a Horde_Imap_Client object.
doPostLoginTasks ( ) Perform post-login tasks.
getCacheId ( string $mailbox, array $addl = [] ) : string Return the cache ID for this mailbox.
getNamespace ( string $mailbox, boolean $personal = false ) : mixed Get namespace info for a full mailbox path.
getSlices ( string $mbox, Horde_Imap_Client_Ids $ids, integer $size = 5242880 ) : array Returns a list of messages, split into slices based on the total message size.
isImap ( ) : boolean Determine if this is a connection to an IMAP server.
isPop3 ( ) : boolean Determine if this is a connection to an IMAP server.
loadServerConfig ( string $server = null ) : mixed Loads the IMP server configuration from backends.php.
parseCacheId ( string $id ) : array Parses the cache ID for this mailbox.
serialize ( )
unserialize ( $data )
updateFetchIgnore ( ) Update the list of mailboxes to ignore when caching FETCH data in the IMAP client object.

보호된 메소드들

메소드 설명
_copy ( ) Handle copy() calls that hit multiple servers.
_getPerm ( string $perm ) : string Get the full permission name for a permission.
_renameMailbox ( ) Handle copy() calls. This call may hit multiple servers, so need to handle separately from other IMAP calls.
_search ( string $mailbox, Horde_Imap_Client_Search_Query $query = null, array $opts = [] ) : array Prepares an IMAP search query. Needed because certain configuration parameters may need to be dynamically altered before passed to the Imap_Client object.
_status ( $args ) Handle status() calls. This call may hit multiple servers.

메소드 상세

__call() 공개 메소드

All other calls to this class are routed to the underlying Horde_Imap_Client_Base object.
public __call ( string $method, array $params ) : mixed
$method string Method name.
$params array Method parameters.
리턴 mixed The return from the requested method.

__construct() 공개 메소드

Constructor.
public __construct ( string $id )
$id string Object identifier.

__get() 공개 메소드

public __get ( $key )

__toString() 공개 메소드

public __toString ( )

_copy() 보호된 메소드

Handle copy() calls that hit multiple servers.
protected _copy ( )

_getPerm() 보호된 메소드

Get the full permission name for a permission.
protected _getPerm ( string $perm ) : string
$perm string The permission.
리턴 string The full (backend-specific) permission name.

_renameMailbox() 보호된 메소드

Handle copy() calls. This call may hit multiple servers, so need to handle separately from other IMAP calls.
protected _renameMailbox ( )

_status() 보호된 메소드

Handle status() calls. This call may hit multiple servers.
protected _status ( $args )

access() 공개 메소드

Checks access rights for a server.
public access ( integer $right ) : boolean
$right integer Access right.
리턴 boolean Does the access right exist?

accessCompose() 공개 메소드

Checks compose access rights for a server.
public accessCompose ( integer $right, integer $data ) : boolean
$right integer Access right.
$data integer Data required to check the rights: - ACCESS_COMPOSE_BODYSIZE The size of the body data. - ACCESS_COMPOSE_RECIPIENTS - ACCESS_COMPOSE_TIMELIMIT The number of e-mail recipients.
리턴 boolean Is the access allowed?

createBaseImapObject() 공개 메소드

Create the base Horde_Imap_Client object (from an entry in backends.php).
public createBaseImapObject ( string $username, string $password, string $skey ) : Horde_Imap_Client_Base
$username string The username to authenticate with.
$password string The password to authenticate with.
$skey string Create a new object using this server key.
리턴 Horde_Imap_Client_Base Client object.

createImapObject() 공개 메소드

Create a Horde_Imap_Client object.
public createImapObject ( array $config, boolean $imap = true ) : Horde_Imap_Client_Base
$config array The IMAP configuration.
$imap boolean True if IMAP connection, false if POP3.
리턴 Horde_Imap_Client_Base Client object.

doPostLoginTasks() 공개 메소드

Perform post-login tasks.
public doPostLoginTasks ( )

getCacheId() 공개 메소드

Return the cache ID for this mailbox.
public getCacheId ( string $mailbox, array $addl = [] ) : string
$mailbox string The mailbox name (UTF-8).
$addl array Local IMP metadata to add to the cache ID.
리턴 string The cache ID.

getNamespace() 공개 메소드

Get namespace info for a full mailbox path.
public getNamespace ( string $mailbox, boolean $personal = false ) : mixed
$mailbox string The mailbox path. (self:NS_DEFAULT will return the default personal namespace.)
$personal boolean If true, will return empty namespace only if it is a personal namespace.
리턴 mixed The namespace info for the mailbox path or null if the path doesn't exist.

getSlices() 공개 메소드

Returns a list of messages, split into slices based on the total message size.
public getSlices ( string $mbox, Horde_Imap_Client_Ids $ids, integer $size = 5242880 ) : array
$mbox string IMAP mailbox.
$ids Horde_Imap_Client_Ids ID list.
$size integer Maximum size of a slice.
리턴 array An array of Horde_Imap_Client_Ids objects.

isImap() 공개 메소드

Determine if this is a connection to an IMAP server.
public isImap ( ) : boolean
리턴 boolean True if connected to IMAP server.

isPop3() 공개 메소드

Determine if this is a connection to an IMAP server.
public isPop3 ( ) : boolean
리턴 boolean True if connected to IMAP server.

loadServerConfig() 공개 정적인 메소드

Loads the IMP server configuration from backends.php.
public static loadServerConfig ( string $server = null ) : mixed
$server string Returns this labeled entry only.
리턴 mixed If $server is set return this entry; else, return the entire servers array. Returns false on error.

parseCacheId() 공개 메소드

Parses the cache ID for this mailbox.
public parseCacheId ( string $id ) : array
$id string Cache ID generated by getCacheId().
리턴 array Two element array: - date: (integer) Date information (day of year), if embedded in cache ID. - token: (string) Mailbox sync token.

serialize() 공개 메소드

public serialize ( )

unserialize() 공개 메소드

public unserialize ( $data )

updateFetchIgnore() 공개 메소드

Update the list of mailboxes to ignore when caching FETCH data in the IMAP client object.
public updateFetchIgnore ( )

프로퍼티 상세

$_backends 보호되어 있는 정적으로 프로퍼티

Cached backend configuration.
protected static array $_backends
리턴 array

$_changed 보호되어 있는 프로퍼티

Has this object changed?
protected bool $_changed
리턴 boolean

$_config 보호되어 있는 프로퍼티

Backend config.
protected IMP_Imap_Config $_config
리턴 IMP_Imap_Config

$_id 보호되어 있는 프로퍼티

Object identifier.
protected string $_id
리턴 string

$_ob 보호되어 있는 프로퍼티

The IMAP client object.
protected Horde_Imap_Client_Base $_ob
리턴 Horde_Imap_Client_Base

$_temp 보호되어 있는 프로퍼티

Temporary data cache (destroyed at end of request).
protected array $_temp
리턴 array