Card
extends File
in package
implements
ICard, IACL
Uses
ACLTrait
The Card object represents a single Card from an addressbook.
Tags
Interfaces, Classes and Traits
Table of Contents
- $addressBookInfo : array<string|int, mixed>
- Array with information about the containing addressbook.
- $cardData : array<string|int, mixed>
- Array with information about this Card.
- $carddavBackend : BackendInterface
- CardDAV backend.
- __construct() : mixed
- Constructor.
- delete() : mixed
- Deletes the card.
- get() : string
- Returns the VCard-formatted object.
- getACL() : array<string|int, mixed>
- Returns a list of ACE's for this node.
- getContentType() : string
- Returns the mime content-type.
- getETag() : string
- Returns an ETag for this object.
- getGroup() : string|null
- Returns a group principal.
- getLastModified() : int
- Returns the last modification date as a unix timestamp.
- getName() : string
- Returns the uri for this object.
- getOwner() : string|null
- Returns the owner principal.
- getSize() : int
- Returns the size of this object in bytes.
- getSupportedPrivilegeSet() : array<string|int, mixed>|null
- Returns the list of supported privileges for this node.
- put() : string|null
- Updates the VCard-formatted object.
- setACL() : mixed
- Updates the ACL.
- setName() : mixed
- Renames the node.
Properties
$addressBookInfo
Array with information about the containing addressbook.
protected
array<string|int, mixed>
$addressBookInfo
$cardData
Array with information about this Card.
protected
array<string|int, mixed>
$cardData
$carddavBackend
CardDAV backend.
protected
BackendInterface
$carddavBackend
Methods
__construct()
Constructor.
public
__construct(BackendInterface $carddavBackend, array<string|int, mixed> $addressBookInfo, array<string|int, mixed> $cardData) : mixed
Parameters
- $carddavBackend : BackendInterface
- $addressBookInfo : array<string|int, mixed>
- $cardData : array<string|int, mixed>
Return values
mixed —delete()
Deletes the card.
public
delete() : mixed
Return values
mixed —get()
Returns the VCard-formatted object.
public
get() : string
Return values
string —getACL()
Returns a list of ACE's for this node.
public
getACL() : array<string|int, mixed>
Each ACE has the following properties:
- 'privilege', a string such as {DAV:}read or {DAV:}write. These are currently the only supported privileges
- 'principal', a url to the principal who owns the node
- 'protected' (optional), indicating that this ACE is not allowed to be updated.
Return values
array<string|int, mixed> —getContentType()
Returns the mime content-type.
public
getContentType() : string
Return values
string —getETag()
Returns an ETag for this object.
public
getETag() : string
Return values
string —getGroup()
Returns a group principal.
public
getGroup() : string|null
This must be a url to a principal, or null if there's no owner
Return values
string|null —getLastModified()
Returns the last modification date as a unix timestamp.
public
getLastModified() : int
Return values
int —getName()
Returns the uri for this object.
public
getName() : string
Return values
string —getOwner()
Returns the owner principal.
public
getOwner() : string|null
This must be a url to a principal, or null if there's no owner
Return values
string|null —getSize()
Returns the size of this object in bytes.
public
getSize() : int
Return values
int —getSupportedPrivilegeSet()
Returns the list of supported privileges for this node.
public
getSupportedPrivilegeSet() : array<string|int, mixed>|null
The returned data structure is a list of nested privileges. See Sabre\DAVACL\Plugin::getDefaultSupportedPrivilegeSet for a simple standard structure.
If null is returned from this method, the default privilege set is used, which is fine for most common usecases.
Return values
array<string|int, mixed>|null —put()
Updates the VCard-formatted object.
public
put(string $cardData) : string|null
Parameters
- $cardData : string
Return values
string|null —setACL()
Updates the ACL.
public
setACL(array<string|int, mixed> $acl) : mixed
This method will receive a list of new ACE's as an array argument.
Parameters
- $acl : array<string|int, mixed>
Return values
mixed —setName()
Renames the node.
public
setName(string $name) : mixed
Parameters
- $name : string
-
The new name