Horde_Mail_Rfc822_Group
extends Horde_Mail_Rfc822_Object
in package
implements
Countable
Object representation of a RFC 822 group e-mail address.
Tags
Interfaces, Classes, Traits and Enums
- Countable
Table of Contents
- $addresses : Horde_Mail_Rfc822_GroupList
- List of group e-mail address objects.
- $groupname : string
- $groupname_encoded : string
- $label : string
- $valid : bool
- $_groupname : string
- Group name (MIME decoded).
- __construct() : mixed
- Constructor.
- __get() : mixed
- __set() : mixed
- __toString() : string
- String representation of object.
- count() : int
- Address count.
- match() : bool
- Compare this object against other data.
- writeAddress() : string
- Write an address given information in this part.
- _writeAddress() : string
- Class-specific implementation of writeAddress().
Properties
$addresses
List of group e-mail address objects.
public
Horde_Mail_Rfc822_GroupList
$addresses
$groupname
public
string
$groupname
Groupname (UTF-8).
$groupname_encoded read-only
public
string
$groupname_encoded
MIME encoded groupname (UTF-8).
$label read-only
public
string
$label
The shorthand label for this group.
$valid read-only
public
bool
$valid
Returns true if there is enough information in object to create a valid address.
$_groupname
Group name (MIME decoded).
protected
string
$_groupname
= 'Group'
Methods
__construct()
Constructor.
public
__construct([string $groupname = null ][, mixed $addresses = null ]) : mixed
Parameters
- $groupname : string = null
-
If set, used as the group name.
- $addresses : mixed = null
-
If a GroupList object, used as the address list. Any other non-null value is parsed and used as the address list (addresses not verified; sub-groups are ignored).
Return values
mixed —__get()
public
__get(mixed $name) : mixed
Parameters
- $name : mixed
Return values
mixed —__set()
public
__set(mixed $name, mixed $value) : mixed
Parameters
- $name : mixed
- $value : mixed
Return values
mixed —__toString()
String representation of object.
public
__toString() : string
Return values
string —Returns the full e-mail address.
count()
Address count.
public
count() : int
Return values
int —The number of addresses.
match()
Compare this object against other data.
public
match(mixed $ob) : bool
Parameters
- $ob : mixed
-
Address data.
Return values
bool —True if the data reflects the same canonical address.
writeAddress()
Write an address given information in this part.
public
writeAddress([mixed $opts = array() ]) : string
Parameters
- $opts : mixed = array()
-
If boolean true, is equivalent to passing true for both 'encode' and 'idn'. If an array, these keys are supported:
- comment: (boolean) If true, include comment(s) in output? @since 2.6.0 DEFAULT: false
- encode: (mixed) MIME encode the personal/groupname parts? If boolean true, encodes in 'UTF-8'. If a string, encodes using this charset. DEFAULT: false
- idn: (boolean) If true, encodes IDN domain names (RFC 3490). DEFAULT: false
- noquote: (boolean) If true, don't quote personal part. [@since 2.4.0] DEFAULT: false
Return values
string —The correctly escaped/quoted address.
_writeAddress()
Class-specific implementation of writeAddress().
protected
_writeAddress(mixed $opts) : string
Parameters
- $opts : mixed
-
See writeAddress().
Return values
string —The correctly escaped/quoted address.