Documentation

Mock extends AbstractBackend
in package

Abstract Principal Backend.

Currently this class has no function. It's here for consistency and so we have a non-bc-breaking way to add a default generic implementation to functions we may add in the future.

Table of Contents

$groupMembers  : mixed
$principals  : mixed
__construct()  : mixed
addPrincipal()  : mixed
findByUri()  : string
Finds a principal by its URI.
getGroupMemberSet()  : mixed
getGroupMembership()  : mixed
getPrincipalByPath()  : mixed
getPrincipalsByPrefix()  : mixed
searchPrincipals()  : mixed
setGroupMemberSet()  : mixed
updatePrincipal()  : mixed
Updates one ore more webdav properties on a principal.

Properties

$groupMembers

public mixed $groupMembers = []

$principals

public mixed $principals

Methods

__construct()

public __construct([array<string|int, mixed> $principals = null ]) : mixed
Parameters
$principals : array<string|int, mixed> = null
Return values
mixed

addPrincipal()

public addPrincipal(array<string|int, mixed> $principal) : mixed
Parameters
$principal : array<string|int, mixed>
Return values
mixed

findByUri()

Finds a principal by its URI.

public findByUri(string $uri, string $principalPrefix) : string

This method may receive any type of uri, but mailto: addresses will be the most common.

Implementation of this API is optional. It is currently used by the CalDAV system to find principals based on their email addresses. If this API is not implemented, some features may not work correctly.

This method must return a relative principal path, or null, if the principal was not found or you refuse to find it.

Parameters
$uri : string
$principalPrefix : string
Return values
string

getGroupMemberSet()

public getGroupMemberSet(mixed $path) : mixed
Parameters
$path : mixed
Return values
mixed

getGroupMembership()

public getGroupMembership(mixed $path) : mixed
Parameters
$path : mixed
Return values
mixed

getPrincipalByPath()

public getPrincipalByPath(mixed $path) : mixed
Parameters
$path : mixed
Return values
mixed

getPrincipalsByPrefix()

public getPrincipalsByPrefix(mixed $prefix) : mixed
Parameters
$prefix : mixed
Return values
mixed

searchPrincipals()

public searchPrincipals(mixed $prefixPath, array<string|int, mixed> $searchProperties[, mixed $test = 'allof' ]) : mixed
Parameters
$prefixPath : mixed
$searchProperties : array<string|int, mixed>
$test : mixed = 'allof'
Return values
mixed

setGroupMemberSet()

public setGroupMemberSet(mixed $path, array<string|int, mixed> $members) : mixed
Parameters
$path : mixed
$members : array<string|int, mixed>
Return values
mixed

updatePrincipal()

Updates one ore more webdav properties on a principal.

public updatePrincipal(string $path, PropPatch $propPatch) : mixed

The list of mutations is stored in a Sabre\DAV\PropPatch object. To do the actual updates, you must tell this object which properties you're going to process with the handle() method.

Calling the handle method is like telling the PropPatch object "I promise I can handle updating this property".

Read the PropPatch documentation for more info and examples.

Parameters
$path : string
$propPatch : PropPatch
Return values
mixed

Search results