Class IMP_Indices
The IMP_Indices class provides functions to handle lists of message
indices.
Copyright 2010-2012 Horde LLC (http://www.horde.org/)
See the enclosed file COPYING for license information (GPL). If you
did not receive this file, see http://www.horde.org/licenses/gpl.
-
IMP_Indices
implements
ArrayAccess,
Countable,
Iterator
Methods summary
public
|
#
__construct( )
Constructor.
Parameters are the same as add().
See
|
public
|
#
add( )
Add indices.
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
+ IMP_Mailbox_List_Track 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
boolean
|
#
getSingle( mixed $all = false )
Returns mailbox/UID information for the first index.
Returns mailbox/UID information for the first index.
Returns
boolean $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.
array A 2-element array with an IMP_Mailbox object and the
UID(s).
|
public
array
|
#
indices( )
Return a copy of the indices array.
Return a copy of the indices array.
Returns
array The indices array (keys are mailbox names, values are
arrays of UIDs).
|
public
string
|
#
formTo( )
Converts an indices object string to a string form representation.
Needed because null characters (used for various internal non-IMAP
mailbox representations) will not work in form elements.
Converts an indices object string to a string form representation.
Needed because null characters (used for various internal non-IMAP
mailbox representations) will not work in form elements.
Returns
string String representation (IMAP sequence string).
|
public
|
#
offsetExists( mixed $offset )
Implementation of
ArrayAccess::offsetExists()
|
public
|
#
offsetGet( mixed $offset )
Implementation of
ArrayAccess::offsetGet()
|
public
|
#
offsetSet( mixed $offset, mixed $value )
Implementation of
ArrayAccess::offsetSet()
|
public
|
#
offsetUnset( mixed $offset )
Implementation of
ArrayAccess::offsetUnset()
|
public
integer
|
#
count( )
Index count.
Returns
integer The number of indices.
Implementation of
Countable::count()
|
public
string
|
#
__toString( )
String representation of the object.
String representation of the object.
Returns
string String representation (IMAP sequence string).
|
public
|
#
current( )
Implementation of
Iterator::current()
|
public
|
#
key( )
Implementation of
Iterator::key()
|
public
|
#
next( )
Implementation of
Iterator::next()
|
public
|
#
rewind( )
Implementation of
Iterator::rewind()
|
public
|
#
valid( )
Implementation of
Iterator::valid()
|