\Horde_ActiveSync_Message_Contact

Horde_ActiveSync_Message_Contact::

Summary

Methods
Properties
Constants
__construct()
__destruct()
getProtocolVersion()
propertyExists()
__get()
__set()
__call()
__isset()
setSupported()
getSupported()
isGhosted()
decodeStream()
encodeStream()
isEmpty()
getClass()
$flags
$commandType
$categories
$anniversary
$assistantname
$assistnamephonenumber
$birthday
$business2phonenumber
$businesscity
$businesscountry
$businesspostalcode
$businessstate
$businessstreet
$businessfaxnumber
$businessphonenumber
$carphonenumber
$categories
$children
$companyname
$department
$email1address
$email2address
$email3address
$fileas
$firstname
$home2phonenumber
$homecity
$homecountry
$homepostalcode
$homestate
$homestreet
$homefaxnumber
$homephonenumber
$jobtitle
$lastname
$middlename
$mobilephonenumber
$officelocation
$othercity
$othercountry
$otherpostalcode
$otherstate
$otherstreet
$pagernumber
$radiophonenumber
$spouse
$suffix
$title
$webpage
$yomicompanyname
$yomifirstname
$yomilastname
$picture
$customerid
$governmentid
$imaddress
$imaddress2
$imaddress3
$managername
$companymainphone
$accountname
$nickname
$mms
$alias
$weightedrank
$body
$bodysize
$bodytruncated
$rtf
$airsyncbasebody
KEY_ATTRIBUTE
KEY_VALUES
KEY_TYPE
KEY_PROPERTY
TYPE_DATE
TYPE_HEX
TYPE_DATE_DASHES
TYPE_MAPI_STREAM
TYPE_MAPI_GOID
TYPE_DATE_LOCAL
PROPERTY_NO_CONTAINER
ANNIVERSARY
ASSISTANTNAME
ASSISTNAMEPHONENUMBER
BIRTHDAY
BODY
BODYSIZE
BODYTRUNCATED
BUSINESS2PHONENUMBER
BUSINESSCITY
BUSINESSCOUNTRY
BUSINESSPOSTALCODE
BUSINESSSTATE
BUSINESSSTREET
BUSINESSFAXNUMBER
BUSINESSPHONENUMBER
CARPHONENUMBER
CATEGORIES
CATEGORY
CHILDREN
CHILD
COMPANYNAME
DEPARTMENT
EMAIL1ADDRESS
EMAIL2ADDRESS
EMAIL3ADDRESS
FILEAS
FIRSTNAME
HOME2PHONENUMBER
HOMECITY
HOMECOUNTRY
HOMEPOSTALCODE
HOMESTATE
HOMESTREET
HOMEFAXNUMBER
HOMEPHONENUMBER
JOBTITLE
LASTNAME
MIDDLENAME
MOBILEPHONENUMBER
OFFICELOCATION
OTHERCITY
OTHERCOUNTRY
OTHERPOSTALCODE
OTHERSTATE
OTHERSTREET
PAGERNUMBER
RADIOPHONENUMBER
SPOUSE
SUFFIX
TITLE
WEBPAGE
YOMICOMPANYNAME
YOMIFIRSTNAME
YOMILASTNAME
RTF
PICTURE
CUSTOMERID
GOVERNMENTID
IMADDRESS
IMADDRESS2
IMADDRESS3
MANAGERNAME
COMPANYMAINPHONE
ACCOUNTNAME
NICKNAME
MMS
ALIAS
WEIGHTEDRANK
_validateDecodedValues()
_preEncodeValidation()
_checkEncoding()
_checkSendEmpty()
_getAttribute()
_formatDate()
_parseDate()
$_mapping
$_properties
$_logger
$_supported
$_exists
$_version
$_device
$_streamFilters
N/A
_hex2bin()
No private properties found
N/A

Constants

KEY_ATTRIBUTE

KEY_ATTRIBUTE

KEY_VALUES

KEY_VALUES

KEY_TYPE

KEY_TYPE

KEY_PROPERTY

KEY_PROPERTY

TYPE_DATE

TYPE_DATE

TYPE_HEX

TYPE_HEX

TYPE_DATE_DASHES

TYPE_DATE_DASHES

TYPE_MAPI_STREAM

TYPE_MAPI_STREAM

TYPE_MAPI_GOID

TYPE_MAPI_GOID

TYPE_DATE_LOCAL

TYPE_DATE_LOCAL

PROPERTY_NO_CONTAINER

PROPERTY_NO_CONTAINER

ANNIVERSARY

ANNIVERSARY

ASSISTANTNAME

ASSISTANTNAME

ASSISTNAMEPHONENUMBER

ASSISTNAMEPHONENUMBER

BIRTHDAY

BIRTHDAY

BODY

BODY

BODYSIZE

BODYSIZE

BODYTRUNCATED

BODYTRUNCATED

BUSINESS2PHONENUMBER

BUSINESS2PHONENUMBER

BUSINESSCITY

BUSINESSCITY

BUSINESSCOUNTRY

BUSINESSCOUNTRY

BUSINESSPOSTALCODE

BUSINESSPOSTALCODE

BUSINESSSTATE

BUSINESSSTATE

BUSINESSSTREET

BUSINESSSTREET

BUSINESSFAXNUMBER

BUSINESSFAXNUMBER

BUSINESSPHONENUMBER

BUSINESSPHONENUMBER

CARPHONENUMBER

CARPHONENUMBER

CATEGORIES

CATEGORIES

CATEGORY

CATEGORY

CHILDREN

CHILDREN

CHILD

CHILD

COMPANYNAME

COMPANYNAME

DEPARTMENT

DEPARTMENT

EMAIL1ADDRESS

EMAIL1ADDRESS

EMAIL2ADDRESS

EMAIL2ADDRESS

EMAIL3ADDRESS

EMAIL3ADDRESS

FILEAS

FILEAS

FIRSTNAME

FIRSTNAME

HOME2PHONENUMBER

HOME2PHONENUMBER

HOMECITY

HOMECITY

HOMECOUNTRY

HOMECOUNTRY

HOMEPOSTALCODE

HOMEPOSTALCODE

HOMESTATE

HOMESTATE

HOMESTREET

HOMESTREET

HOMEFAXNUMBER

HOMEFAXNUMBER

HOMEPHONENUMBER

HOMEPHONENUMBER

JOBTITLE

JOBTITLE

LASTNAME

LASTNAME

MIDDLENAME

MIDDLENAME

MOBILEPHONENUMBER

MOBILEPHONENUMBER

OFFICELOCATION

OFFICELOCATION

OTHERCITY

OTHERCITY

OTHERCOUNTRY

OTHERCOUNTRY

OTHERPOSTALCODE

OTHERPOSTALCODE

OTHERSTATE

OTHERSTATE

OTHERSTREET

OTHERSTREET

PAGERNUMBER

PAGERNUMBER

RADIOPHONENUMBER

RADIOPHONENUMBER

SPOUSE

SPOUSE

SUFFIX

SUFFIX

TITLE

TITLE

WEBPAGE

WEBPAGE

YOMICOMPANYNAME

YOMICOMPANYNAME

YOMIFIRSTNAME

YOMIFIRSTNAME

YOMILASTNAME

YOMILASTNAME

RTF

RTF

PICTURE

PICTURE

CUSTOMERID

CUSTOMERID

GOVERNMENTID

GOVERNMENTID

IMADDRESS

IMADDRESS

IMADDRESS2

IMADDRESS2

IMADDRESS3

IMADDRESS3

MANAGERNAME

MANAGERNAME

COMPANYMAINPHONE

COMPANYMAINPHONE

ACCOUNTNAME

ACCOUNTNAME

NICKNAME

NICKNAME

MMS

MMS

ALIAS

ALIAS

WEIGHTEDRANK

WEIGHTEDRANK

Properties

$flags

$flags : \Horde_ActiveSync::FLAG_*

Message flags

Type

\Horde_ActiveSync::FLAG_* — constant

$commandType

$commandType : string

Request type. One of: Horde_ActiveSync::SYNC_ADD, SYNC_MODIFY, SYNC_REMOVE, or SYNC_FETCH. Used internally for enforcing various protocol rules depending on request.

@since 2.31.0

Type

string

$categories

$categories : 

Type

$anniversary

$anniversary : \Horde_Date

Type

\Horde_Date

$assistantname

$assistantname : string

Type

string

$assistnamephonenumber

$assistnamephonenumber : string

Type

string

$birthday

$birthday : \Horde_Date

Type

\Horde_Date

$business2phonenumber

$business2phonenumber : string

Type

string

$businesscity

$businesscity : string

Type

string

$businesscountry

$businesscountry : string

Type

string

$businesspostalcode

$businesspostalcode : string

Type

string

$businessstate

$businessstate : string

Type

string

$businessstreet

$businessstreet : string

Type

string

$businessfaxnumber

$businessfaxnumber : string

Type

string

$businessphonenumber

$businessphonenumber : string

Type

string

$carphonenumber

$carphonenumber : string

Type

string

$categories

$categories : array

Type

array

$children

$children : array

Type

array

$companyname

$companyname : string

Type

string

$department

$department : string

Type

string

$email1address

$email1address : string

Type

string

$email2address

$email2address : string

Type

string

$email3address

$email3address : string

Type

string

$fileas

$fileas : string

Type

string

$firstname

$firstname : string

Type

string

$home2phonenumber

$home2phonenumber : string

Type

string

$homecity

$homecity : string

Type

string

$homecountry

$homecountry : string

Type

string

$homepostalcode

$homepostalcode : string

Type

string

$homestate

$homestate : string

Type

string

$homestreet

$homestreet : string

Type

string

$homefaxnumber

$homefaxnumber : string

Type

string

$homephonenumber

$homephonenumber : string

Type

string

$jobtitle

$jobtitle : string

Type

string

$lastname

$lastname : string

Type

string

$middlename

$middlename : string

Type

string

$mobilephonenumber

$mobilephonenumber : string

Type

string

$officelocation

$officelocation : string

Type

string

$othercity

$othercity : string

Type

string

$othercountry

$othercountry : string

Type

string

$otherpostalcode

$otherpostalcode : string

Type

string

$otherstate

$otherstate : string

Type

string

$otherstreet

$otherstreet : string

Type

string

$pagernumber

$pagernumber : string

Type

string

$radiophonenumber

$radiophonenumber : string

Type

string

$spouse

$spouse : string

Type

string

$suffix

$suffix : string

Type

string

$title

$title : string

Type

string

$webpage

$webpage : string

Type

string

$yomicompanyname

$yomicompanyname : string

Type

string

$yomifirstname

$yomifirstname : string

Type

string

$yomilastname

$yomilastname : string

Type

string

$picture

$picture : string

Type

string

$customerid

$customerid : string

Type

string

$governmentid

$governmentid : string

Type

string

$imaddress

$imaddress : string

Type

string

$imaddress2

$imaddress2 : string

Type

string

$imaddress3

$imaddress3 : string

Type

string

$managername

$managername : string

Type

string

$companymainphone

$companymainphone : string

Type

string

$accountname

$accountname : string

Type

string

$nickname

$nickname : string

Type

string

$mms

$mms : string

Type

string

$alias

$alias : string

(EAS >= 14.0 only)

Type

string

$weightedrank

$weightedrank : string

(EAS >= 14.0 only)

Type

string

$body

$body : string

(EAS 2.5 only)

Type

string

$bodysize

$bodysize : integer

(EAS 2.5 only)

Type

integer

$bodytruncated

$bodytruncated : integer

(EAS 2.5 only)

Type

integer

$rtf

$rtf : integer

(EAS 2.5 only)

Type

integer

$airsyncbasebody

$airsyncbasebody : \Horde_ActiveSync_Message_AirSyncBaseBody

(EAS >= 12.0 only)

Type

\Horde_ActiveSync_Message_AirSyncBaseBody

$_mapping

$_mapping : array

Property mapping.

Type

array

$_properties

$_properties : array

Property values.

Type

array

$_logger

$_logger : \Horde_Log_Logger

Logger

Type

\Horde_Log_Logger

$_supported

$_supported : array

An array describing the non-ghosted elements this message supports.

Type

array

$_exists

$_exists : array

Existence cache, used for working with ghosted properties.

Type

array

$_version

$_version : float

The version of EAS we are to support.

Type

float

$_streamFilters

$_streamFilters : array

Cache of current stream filters.

Type

array

Methods

__construct()

__construct(array  $options = array()) : \Horde_ActiveSync_Message_Base

Const'r

Parameters

array $options

Configuration options for the message:

  • logger: (Horde_Log_Logger) A logger instance DEFAULT: none (No logging).
  • protocolversion: (float) The version of EAS to support. DEFAULT: Horde_ActiveSync::VERSION_TWOFIVE (2.5)
  • device: (Horde_ActiveSync_Device) The device object. @since 2.9.2

Returns

\Horde_ActiveSync_Message_Base

__destruct()

__destruct() 

getProtocolVersion()

getProtocolVersion() : float

Return the EAS version this object supports.

Returns

float —

A HordeActiveSync::VERSION* constant.

propertyExists()

propertyExists(string  $property) : boolean

Check the existence of a property in this message.

Parameters

string $property

The property name

Returns

boolean

__get()

__get(string  $property) : mixed

Accessor

Parameters

string $property

Property to get.

Returns

mixed —

The value of the requested property.

__set()

__set(string  $property, mixed  $value) 

Setter

Parameters

string $property

The property to set.

mixed $value

The value to set it to.

Throws

\InvalidArgumentException

__call()

__call(mixed  $method, array  $arg) : mixed

Magic caller method.

Parameters

mixed $method

The method to call.

array $arg

Method arguments.

Returns

mixed

__isset()

__isset(string  $property) : \boolean.

Magic method.

Parameters

string $property

The property name to check.

Returns

\boolean.

setSupported()

setSupported(array  $fields) 

Set the list of non-ghosted fields for this message.

Parameters

array $fields

The array of fields, keyed by the fully qualified property name i.e., POOMCONTACTS:Anniversary. To signify an empty SUPPORTED container $fields should contain a single element equal to Horde_ActiveSync::ALL_GHOSTED.

getSupported()

getSupported() : array

Get the list of non-ghosted properties for this message.

Returns

array —

The array of non-ghosted properties

isGhosted()

isGhosted(string  $property, array  $options = array()) : boolean

Determines if the property specified has been ghosted by the client.

A property is ghosted if it is NOT listed in the SUPPORTED list sent by the client AND is NOT present in the request data.

Parameters

string $property

The property to check

array $options

An array of options:

  • ignoreEmptyPictureTagCheck: boolean If true, will not check for the QUIRK_INCORRECTLY_SENDS_EMPTY_PICTURE_TAG quirk. @since 2.32.0

Returns

boolean

decodeStream()

decodeStream(\Horde_ActiveSync_Wbxml_Decoder  $decoder) 

Recursively decodes the WBXML from input stream. This means that if this message contains complex types (like Appointment.Recuurence for example) the sub-objects are auto-instantiated and decoded as well. Places the decoded objects in the local properties array.

Parameters

\Horde_ActiveSync_Wbxml_Decoder $decoder

Throws

\Horde_ActiveSync_Exception

encodeStream()

encodeStream(\Horde_ActiveSync_Wbxml_Encoder  $encoder) 

Encodes this object (and any sub-objects) as wbxml to the output stream.

Output is ordered according to $_mapping

Parameters

\Horde_ActiveSync_Wbxml_Encoder $encoder

The wbxml stream encoder

Throws

\Horde_ActiveSync_Exception

isEmpty()

isEmpty() : boolean

Returns whether or not this message actually contains any data to send.

Returns

boolean —

True if message is empty, otherwise false.

getClass()

getClass() : string

Return message type

Returns

string

_validateDecodedValues()

_validateDecodedValues() : boolean

Give concrete classes the chance to enforce rules.

Returns

boolean —

True on success, otherwise false.

_preEncodeValidation()

_preEncodeValidation() : boolean

Give concrete classes the chance to enforce rules before encoding messages to send to the client.

Returns

boolean —

True if values were valid (or could be made valid). False if values are unable to be validated.

_checkEncoding()

_checkEncoding(mixed  $data, string  $tag) : mixed

Checks if the data needs to be encoded like e.g., when outputing binary data in-line during ITEMOPERATIONS requests. Concrete classes should override this if needed.

Parameters

mixed $data

The data to check. A string or stream resource.

string $tag

The tag we are outputing.

Returns

mixed —

The encoded data. A string or stream resource with a filter attached.

_checkSendEmpty()

_checkSendEmpty(string  $tag) : boolean

Check if we should send a specific property even if it's empty.

Parameters

string $tag

The property tag.

Returns

boolean

_getAttribute()

_getAttribute(string  $name, \stting  $default = null) : mixed

Helper method to allow default values for unset properties.

Parameters

string $name

The property name

\stting $default

The default value to return if $property is empty

Returns

mixed

_formatDate()

_formatDate(\Horde_Date  $dt, integer  $type) : string

Format a date string for sending to the EAS client.

So we have to send a different date type depending on where it's used. Used when encoding a date value to send to the client.

Parameters

\Horde_Date $dt

The Horde_Date object to format (should normally be in local tz).

integer $type

The type to format as (TYPE_DATE or TYPE_DATE_DASHES)

Returns

string —

The formatted date

_parseDate()

_parseDate(string  $ts) : \Horde_Date|boolean

Override parent class so we can normalize the Date object before returning it.

Used when decoding an incoming date value from the client.

Parameters

string $ts

The timestamp

Returns

\Horde_Date|boolean —

The Horde_Date object (UTC) or false if unable to parse the date.

_hex2bin()

_hex2bin(string  $data) : string

Function which converts a hex entryid to a binary entryid.

Parameters

string $data

The hexadecimal string

Returns

string —

The binary data