Documentation

IMP_Flag_User extends IMP_Flag_Imap
in package

This class provides the data structure for a user-defined message flag.

Tags
author

Michael Slusarz slusarz@horde.org

category

Horde

copyright

2010-2017 Horde LLC

license

http://www.horde.org/licenses/gpl GPL

Table of Contents

Constants

DEFAULT_BG  = '#fff'

Properties

$bgcolor  : string
$bgdefault  : bool
$canset  : bool
$css  : string
$cssicon  : string
$fgcolor  : string
$form_set  : string
$form_unset  : string
$hash  : string
$id  : string
$imapflag  : string
$label  : string
$span  : string
$_bgcolor  : string
The background color.
$_canset  : mixed
$_css  : mixed
$_cssIcon  : string
The CSS class for the icon.
$_id  : string
Unique ID.
$_imapflag  : string
The IMAP flag string used on the server.
$_label  : string
The flag label.

Methods

__construct()  : mixed
Constructor.
__get()  : mixed
__serialize()  : array<string|int, mixed>
__set()  : mixed
__toString()  : string
String representation of the object.
__unserialize()  : void
changed()  : mixed
Given a list of flag objects, determines if this flag's status has changed.
getLabel()  : string
Return the flag label.
matchFlag()  : bool
Set flag by doing IMAP flag matching.
serialize()  : mixed
unserialize()  : mixed
_getLabel()  : mixed

Constants

DEFAULT_BG

public mixed DEFAULT_BG = '#fff'

Properties

$bgcolor

public string $bgcolor

The background color.

$bgdefault read-only

public bool $bgdefault

Is the background color the default?

$canset read-only

public bool $canset

Can this flag be set by the user?

$css read-only

public string $css

The CSS class for the icon when the flag is set.

$cssicon read-only

public string $cssicon

The CSS class for the icon.

$fgcolor read-only

public string $fgcolor

The foreground (text) color.

$form_set read-only

public string $form_set

Form value to use when setting flag.

$form_unset read-only

public string $form_unset

Form value to use when unsetting flag.

$hash read-only

public string $hash

Unique hash of this flag.

$id read-only

public string $id

Unique ID.

$imapflag read-only

public string $imapflag

The IMAP flag string.

$label read-only

public string $label

The query label.

$span read-only

public string $span

Return SPAN HTML to output the icon for use in a mailbox row.

$_bgcolor

The background color.

protected string $_bgcolor = ''

$_canset

protected mixed $_canset = \true

$_css

protected mixed $_css = 'flagUser'

$_cssIcon

The CSS class for the icon.

protected string $_cssIcon = ''

$_id

Unique ID.

protected string $_id = ''

$_imapflag

The IMAP flag string used on the server.

protected string $_imapflag

$_label

The flag label.

protected string $_label

Methods

__construct()

Constructor.

public __construct(string $label[, string $flag = null ][, string $bgcolor = null ]) : mixed
Parameters
$label : string

The label.

$flag : string = null

The IMAP flag.

$bgcolor : string = null

The background color.

__get()

public __get(mixed $name) : mixed
Parameters
$name : mixed

__serialize()

public __serialize() : array<string|int, mixed>
Return values
array<string|int, mixed>

__set()

public __set(mixed $name, mixed $value) : mixed
Parameters
$name : mixed
$value : mixed
Tags
throws
IMP_Exception

__toString()

String representation of the object.

public __toString() : string
Return values
string

String representation (Flag ID).

__unserialize()

public __unserialize(array<string|int, mixed> $data) : void
Parameters
$data : array<string|int, mixed>

changed()

Given a list of flag objects, determines if this flag's status has changed.

public changed(array<string|int, mixed> $obs, bool $add) : mixed
Parameters
$obs : array<string|int, mixed>

A list of IMP_Flag_Base objects.

$add : bool

True if these flags were added, false if they were removed.

Return values
mixed

Null if no change, true if flag is added, false if flag is removed.

getLabel()

Return the flag label.

public getLabel([bool $set = true ]) : string
Parameters
$set : bool = true

Return label for setting the flag?

Return values
string

The label.

matchFlag()

Set flag by doing IMAP flag matching.

public matchFlag(array<string|int, mixed> $data) : bool
Parameters
$data : array<string|int, mixed>

List of IMAP flags.

Return values
bool

True if the flag should be set. False if the flag should never be set. Null if flag should not be set, but could be set by other matching interfaces.

serialize()

public serialize() : mixed

unserialize()

public unserialize(mixed $data) : mixed
Parameters
$data : mixed

_getLabel()

protected _getLabel() : mixed

        
On this page

Search results