PHP 클래스 IMP_Indices, horde

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

보호된 프로퍼티들

프로퍼티 타입 설명
$_indices array The indices list.

공개 메소드들

메소드 설명
__construct ( ) Constructor.
__toString ( ) : string String representation of the object.
add ( ) Add indices.
copy ( string $targetMbox, string $action, array $opts = [] ) : boolean Copies or moves a list of messages to a new mailbox.
count ( ) : integer Index count.
current ( ) * Iterator methods.
delete ( array $opts = [] ) : integer | boolean Deletes a list of messages.
flag ( array $add = [], array $remove = [], array $opts = [] ) : boolean Sets or clears a given flag for a list of messages.
getSingle ( $all = false ) : array Returns mailbox/UID information for the first index.
indices ( ) : array Return a copy of the indices array.
key ( )
mdnCheck ( Horde_Mime_Headers $headers, boolean $confirmed = false ) : boolean Check if we need to send a MDN, and send if needed.
next ( )
offsetExists ( $offset )
offsetGet ( $offset )
offsetSet ( $offset, $value )
offsetUnset ( $offset )
rewind ( )
stripPart ( string $partid = null ) : IMP_Indices Strips one or all MIME parts out of a message.
toArray ( ) : array Returns an array containing compressed UID values.
valid ( )

보호된 메소드들

메소드 설명
_fromSequenceString ( string $str ) : array Parse an IMAP message sequence string into a list of indices.
_toSequenceString ( array $in ) : string Create an IMAP message sequence string from a list of indices.

메소드 상세

__construct() 공개 메소드

Parameters are the same as add().
또한 보기: add()
public __construct ( )

__toString() 공개 메소드

String representation of the object.
public __toString ( ) : string
리턴 string String representation (IMAP sequence string).

_fromSequenceString() 보호된 메소드

Extends Horde_Imap_Client_Ids by allowing mailbox information to appear in the string.
protected _fromSequenceString ( string $str ) : array
$str string The IMAP message sequence string.
리턴 array An array of indices. If string contains mailbox info, return value will be an array of arrays, with keys as mailbox names and values as IDs. Otherwise, return the list of IDs.

_toSequenceString() 보호된 메소드

Extends Horde_Imap_Client_Ids by allowing mailbox information to appear in the string.
protected _toSequenceString ( array $in ) : string
$in array An array of indices.
리턴 string The message sequence string.

add() 공개 메소드

Input format:
1 argument:
-----------
+ Array
  Either:
    KEYS: Mailbox names
    VALUES: UIDs -or- Horde_Imap_Client_Ids object
 -or-
    VALUES: IMAP sequence strings
+ IMP_Compose object
+ IMP_Contents object
+ IMP_Indices object
+ String
  Format: IMAP sequence string

2 arguments:
------------
1st argument: Mailbox name -or- IMP_Mailbox object
2nd argument: Either a single UID, array of UIDs, or a
              Horde_Imap_Client_Ids object.
public add ( )

copy() 공개 메소드

Also handles moves to the tasklist and/or notepad applications.
public copy ( string $targetMbox, string $action, array $opts = [] ) : boolean
$targetMbox string The mailbox to move/copy messages to (UTF-8).
$action string Either 'copy' or 'move'.
$opts array Additional options:
  - create: (boolean) Should the target mailbox be created?
            DEFAULT: false
리턴 boolean True if successful, false if not.

count() 공개 메소드

Index count.
public count ( ) : integer
리턴 integer The number of indices.

current() 공개 메소드

* Iterator methods.
public current ( )

delete() 공개 메소드

Deletes a list of messages.
public delete ( array $opts = [] ) : integer | boolean
$opts array Additional options:
  - keeplog: (boolean) Should any history information of the message be
             kept?
             DEFAULT: false
  - nuke: (boolean) Override user preferences and nuke (i.e.
          permanently delete) the messages instead?
          DEFAULT: false
리턴 integer | boolean The number of messages deleted if successful, false if not successful.

flag() 공개 메소드

Sets or clears a given flag for a list of messages.
public flag ( array $add = [], array $remove = [], array $opts = [] ) : boolean
$add array A list of IMAP flag(s) to add.
$remove array A list of IMAP flag(s) to remove.
$opts array Additional options:
  - silent: (boolean) Don't output notification messages.
            DEFAULT: false
  - unchangedsince: (array) The unchangedsince value to pass to the
                    IMAP store command. Keys are mailbox names, values
                    are the unchangedsince values to use for that
                    mailbox.
                    DEFAULT: array()
리턴 boolean True if successful, false if not.

getSingle() 공개 메소드

Returns mailbox/UID information for the first index.
public getSingle ( $all = false ) : array
리턴 array $all If true, returns all UIDs for the first index in an array. If false, returns the first UID for the first index as a string.

indices() 공개 메소드

Return a copy of the indices array.
public indices ( ) : array
리턴 array The indices array (keys are mailbox names, values are arrays of UIDs).

key() 공개 메소드

public key ( )

mdnCheck() 공개 메소드

Check if we need to send a MDN, and send if needed.
public mdnCheck ( Horde_Mime_Headers $headers, boolean $confirmed = false ) : boolean
$headers Horde_Mime_Headers The headers of the message.
$confirmed boolean Has the MDN request been confirmed?
리턴 boolean True if the MDN request needs to be confirmed.

next() 공개 메소드

public next ( )

offsetExists() 공개 메소드

public offsetExists ( $offset )

offsetGet() 공개 메소드

public offsetGet ( $offset )

offsetSet() 공개 메소드

public offsetSet ( $offset, $value )

offsetUnset() 공개 메소드

public offsetUnset ( $offset )

rewind() 공개 메소드

public rewind ( )

stripPart() 공개 메소드

Strips one or all MIME parts out of a message.
public stripPart ( string $partid = null ) : IMP_Indices
$partid string The MIME ID of the part to strip. All parts are stripped if null.
리턴 IMP_Indices Returns the new indices object.

toArray() 공개 메소드

Returns an array containing compressed UID values.
public toArray ( ) : array
리턴 array Keys are base64 encoded mailbox names, values are sequence strings.

valid() 공개 메소드

public valid ( )

프로퍼티 상세

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

The indices list.
protected array $_indices
리턴 array