IAddressBook
in
Interface IAddressBook
Tags
Table of Contents
Methods
- createOrUpdate() : array<string|int, mixed>
- delete() : bool
- getDisplayName() : mixed
- In comparison to getKey() this function returns a human readable (maybe translated) name
- getKey() : string
- getPermissions() : mixed
- getUri() : string
- isShared() : bool
- Returns true if this address-book is not owned by the current user, but shared with them.
- isSystemAddressBook() : bool
- search() : array<string|int, mixed>
Methods
createOrUpdate()
public
createOrUpdate(array<string|int, mixed> $properties) : array<string|int, mixed>
Parameters
- $properties : array<string|int, mixed>
-
this array if key-value-pairs defines a contact
Tags
Return values
array<string|int, mixed> —an array representing the contact just created or updated
delete()
public
delete(int $id) : bool
Parameters
- $id : int
-
the unique identifier to a contact
Tags
Return values
bool —successful or not
getDisplayName()
In comparison to getKey() this function returns a human readable (maybe translated) name
public
getDisplayName() : mixed
Tags
getKey()
public
getKey() : string
Tags
Return values
string —defining the technical unique key
getPermissions()
public
getPermissions() : mixed
Tags
getUri()
public
getUri() : string
Tags
Return values
string —defining the unique uri
isShared()
Returns true if this address-book is not owned by the current user, but shared with them.
public
isShared() : bool
Tags
Return values
boolisSystemAddressBook()
public
isSystemAddressBook() : bool
Tags
Return values
boolsearch()
public
search(string $pattern, array<string|int, mixed> $searchProperties, array<string|int, mixed> $options) : array<string|int, mixed>
Parameters
- $pattern : string
-
which should match within the $searchProperties
- $searchProperties : array<string|int, mixed>
-
defines the properties within the query pattern should match
- $options : array<string|int, mixed>
-
Options to define the output format and search behavior
- 'types' boolean (since 15.0.0) If set to true, fields that come with a TYPE property will be an array example: ['id' => 5, 'FN' => 'Thomas Tanghus', 'EMAIL' => ['type => 'HOME', 'value' => 'g@h.i']]
- 'escape_like_param' - If set to false wildcards _ and % are not escaped
- 'limit' - Set a numeric limit for the search results
- 'offset' - Set the offset for the limited search results
- 'wildcard' - (since 23.0.0) Whether the search should use wildcards
Tags
Return values
array<string|int, mixed> —an array of contacts which are arrays of key-value-pairs example result: [ ['id' => 0, 'FN' => 'Thomas Müller', 'EMAIL' => 'a@b.c', 'GEO' => '37.386013;-122.082932'], ['id' => 5, 'FN' => 'Thomas Tanghus', 'EMAIL' => ['d@e.f', 'g@h.i']] ]