Nextcloud Circles API

MembersService
in package
Uses TNCRequest, TArrayTools

Class MembersService

Tags
deprecated

Table of Contents

$TYPE_ARRAY  : mixed
$TYPE_BOOLEAN  : mixed
$TYPE_INTEGER  : mixed
$TYPE_NULL  : mixed
$TYPE_SERIALIZABLE  : mixed
$TYPE_STRING  : mixed
$accountsRequest  : AccountsRequest
$circlesRequest  : DeprecatedCirclesRequest
$configService  : ConfigService
$eventsService  : EventsService
$fileSharesRequest  : FileSharesRequest
$fileSharingBroadcaster  : FileSharingBroadcaster
$gsUpstreamService  : GSUpstreamService
$l10n  : IL10N
$membersRequest  : DeprecatedMembersRequest
$miscService  : MiscService
$tokensRequest  : TokensRequest
$userId  : string
$userManager  : IUserManager
__construct()  : mixed
MembersService constructor.
addMember()  : array<string|int, mixed>
addMember();
addMemberBasedOnItsType()  : mixed
add a new member based on its type.
clientService()  : IClientService
doRequest()  : void
getCircleFromMembership()  : DeprecatedCircle
getMember()  : DeprecatedMember
getMember();
getMemberById()  : DeprecatedMember
getUserDisplayName()  : string
levelMember()  : array<string|int, mixed>
onUserRemoved()  : mixed
When a user is removed, remove him from all Circles
removeMember()  : array<string|int, DeprecatedMember>
retrieveJson()  : array<string|int, mixed>
setMaxDownloadSize()  : mixed
typeOf()  : string
updateCachedFromCircle()  : mixed
updateCachedName()  : mixed
updateMember()  : mixed
validKey()  : bool
verifyIdentBasedOnItsType()  : mixed
// TODO - check this on GS setup Verify the availability of an ident, based on its type.
cleanArray()  : mixed
extractArray()  : mixed
get()  : string
getArray()  : array<string|int, mixed>
getBool()  : bool
getFloat()  : float
getInt()  : int
getList()  : array<string|int, mixed>
getObj()  : mixed
mustContains()  : mixed
addContact()  : mixed
// TODO - check this on GS setup Add contact as member.
addEmailAddress()  : mixed
add mail address as contact.
addGroupMembers()  : array<string|int, DeprecatedMember>
addLocalMember()  : mixed
addMassiveMails()  : array<string|int, DeprecatedMember>
// TODO - check this on GS setup
addMassiveMembers()  : array<string|int, DeprecatedMember>
add a bunch of users to a circle based on the type of the 'bunch'
addSingleMember()  : DeprecatedMember
add a single member to a circle.
filterDuplicate()  : array<string|int, mixed>
generationClientOptions()  : mixed
getGlobalScaleUserDisplayName()  : string
useClient()  : IResponse
verifyIdentContact()  : mixed
Verify if a contact exist in current user address books.
verifyIdentEmailAddress()  : mixed
Verify if a mail have a valid format.
verifyIdentLocalMember()  : mixed
Verify if a local account is valid.

Properties

$TYPE_ARRAY

public static mixed $TYPE_ARRAY = 'Array'

$TYPE_BOOLEAN

public static mixed $TYPE_BOOLEAN = 'Boolean'

$TYPE_INTEGER

public static mixed $TYPE_INTEGER = 'Integer'

$TYPE_SERIALIZABLE

public static mixed $TYPE_SERIALIZABLE = 'Serializable'

$TYPE_STRING

public static mixed $TYPE_STRING = 'String'

$circlesRequest

private DeprecatedCirclesRequest $circlesRequest

$fileSharingBroadcaster

private FileSharingBroadcaster $fileSharingBroadcaster

$membersRequest

private DeprecatedMembersRequest $membersRequest

Methods

__construct()

MembersService constructor.

public __construct(string $userId, IL10N $l10n, IUserManager $userManager, ConfigService $configService, DeprecatedCirclesRequest $circlesRequest, DeprecatedMembersRequest $membersRequest, AccountsRequest $accountsRequest, FileSharesRequest $fileSharesRequest, TokensRequest $tokensRequest, EventsService $eventsService, GSUpstreamService $gsUpstreamService, FileSharingBroadcaster $fileSharingBroadcaster, MiscService $miscService) : mixed
Parameters
$userId : string
$l10n : IL10N
$userManager : IUserManager
$configService : ConfigService
$circlesRequest : DeprecatedCirclesRequest
$membersRequest : DeprecatedMembersRequest
$accountsRequest : AccountsRequest
$fileSharesRequest : FileSharesRequest
$tokensRequest : TokensRequest
$eventsService : EventsService
$gsUpstreamService : GSUpstreamService
$fileSharingBroadcaster : FileSharingBroadcaster
$miscService : MiscService
Return values
mixed

addMember()

addMember();

public addMember(string $circleUniqueId,  $ident, int $type, string $instance[, bool $force = false ]) : array<string|int, mixed>

add a new member to a circle.

Parameters
$circleUniqueId : string
$ident :
$type : int
$instance : string
$force : bool = false
Tags
throws
Exception
Return values
array<string|int, mixed>

clientService()

public clientService() : IClientService
Return values
IClientService

getMember()

getMember();

public getMember( $circleId,  $userId,  $type[, bool $forceAll = false ]) : DeprecatedMember

Will return any data of a user related to a circle (as a Member). User can be a 'non-member' Viewer needs to be at least Member of the Circle

Parameters
$circleId :
$userId :
$type :
$forceAll : bool = false
Tags
throws
CircleDoesNotExistException
throws
ConfigNoCircleAvailableException
throws
MemberDoesNotExistException
Return values
DeprecatedMember

getUserDisplayName()

public getUserDisplayName(string $ident[, bool $fresh = false ]) : string
Parameters
$ident : string
$fresh : bool = false
Tags
throws
GSStatusException
Return values
string

levelMember()

public levelMember(string $circleUniqueId, string $name, int $type, string $instance, int $level[, bool $force = false ]) : array<string|int, mixed>
Parameters
$circleUniqueId : string
$name : string
$type : int
$instance : string
$level : int
$force : bool = false
Tags
throws
CircleDoesNotExistException
throws
CircleTypeNotValidException
throws
ConfigNoCircleAvailableException
throws
MemberDoesNotExistException
throws
Exception
Return values
array<string|int, mixed>

onUserRemoved()

When a user is removed, remove him from all Circles

public onUserRemoved(string $userId) : mixed
Parameters
$userId : string
Tags
throws
Exception
Return values
mixed

removeMember()

public removeMember(string $circleUniqueId, string $name, int $type, string $instance[, bool $force = false ]) : array<string|int, DeprecatedMember>
Parameters
$circleUniqueId : string
$name : string
$type : int
$instance : string
$force : bool = false
Tags
throws
CircleDoesNotExistException
throws
ConfigNoCircleAvailableException
throws
MemberDoesNotExistException
throws
MemberIsNotModeratorException
throws
Exception
Return values
array<string|int, DeprecatedMember>

setMaxDownloadSize()

public setMaxDownloadSize(int $size) : mixed
Parameters
$size : int
Return values
mixed

typeOf()

public typeOf(string $key, array<string|int, mixed> $arr[, bool $root = true ]) : string
Parameters
$key : string
$arr : array<string|int, mixed>
$root : bool = true
Tags
throws
ItemNotFoundException
throws
UnknownTypeException
Return values
string

validKey()

public validKey(string $k, array<string|int, mixed> $arr) : bool
Parameters
$k : string
$arr : array<string|int, mixed>
Return values
bool

verifyIdentBasedOnItsType()

// TODO - check this on GS setup Verify the availability of an ident, based on its type.

public verifyIdentBasedOnItsType(string &$ident, int $type[, string $instance = '' ]) : mixed
Parameters
$ident : string
$type : int
$instance : string = ''
Tags
throws
EmailAccountInvalidFormatException
throws
NoUserException
Return values
mixed

cleanArray()

protected cleanArray(array<string|int, mixed> &$arr) : mixed
Parameters
$arr : array<string|int, mixed>
Return values
mixed

extractArray()

protected extractArray(string $k, string $value, array<string|int, mixed> $list) : mixed
Parameters
$k : string
$value : string
$list : array<string|int, mixed>
Tags
throws
ArrayNotFoundException
Return values
mixed

get()

protected get(string $k, array<string|int, mixed> $arr[, string $default = '' ]) : string
Parameters
$k : string
$arr : array<string|int, mixed>
$default : string = ''
Return values
string

getArray()

protected getArray(string $k, array<string|int, mixed> $arr[, array<string|int, mixed> $default = [] ]) : array<string|int, mixed>
Parameters
$k : string
$arr : array<string|int, mixed>
$default : array<string|int, mixed> = []
Return values
array<string|int, mixed>

getBool()

protected getBool(string $k, array<string|int, mixed> $arr[, bool $default = false ]) : bool
Parameters
$k : string
$arr : array<string|int, mixed>
$default : bool = false
Return values
bool

getFloat()

protected getFloat(string $k, array<string|int, mixed> $arr, float $default) : float
Parameters
$k : string
$arr : array<string|int, mixed>
$default : float
Return values
float

getInt()

protected getInt(string $k, array<string|int, mixed> $arr, int $default) : int
Parameters
$k : string
$arr : array<string|int, mixed>
$default : int
Return values
int

getList()

protected getList(string $k, array<string|int, mixed> $arr, array<string|int, mixed> $import[, array<string|int, mixed> $default = [] ]) : array<string|int, mixed>
Parameters
$k : string
$arr : array<string|int, mixed>
$import : array<string|int, mixed>
$default : array<string|int, mixed> = []
Return values
array<string|int, mixed>

getObj()

protected getObj(string $k, array<string|int, mixed> $arr[, JsonSerializable|null $default = null ]) : mixed
Parameters
$k : string
$arr : array<string|int, mixed>
$default : JsonSerializable|null = null
Return values
mixed

mustContains()

protected mustContains(array<string|int, mixed> $keys, array<string|int, mixed> $arr) : mixed
Parameters
$keys : array<string|int, mixed>
$arr : array<string|int, mixed>
Tags
throws
MalformedArrayException
Return values
mixed

generationClientOptions()

private generationClientOptions(NCRequest $request) : mixed
Parameters
$request : NCRequest
Return values
mixed

getGlobalScaleUserDisplayName()

private getGlobalScaleUserDisplayName(string $ident) : string
Parameters
$ident : string
Tags
throws
GSStatusException
Return values
string

useClient()

private useClient(NCRequest $request) : IResponse
Parameters
$request : NCRequest
Tags
throws
Exception
Return values
IResponse

verifyIdentContact()

Verify if a contact exist in current user address books.

private verifyIdentContact( &$ident,  $type) : mixed
Parameters
$ident :
$type :
Tags
throws
NoUserException
throws
EmailAccountInvalidFormatException
Return values
mixed

verifyIdentEmailAddress()

Verify if a mail have a valid format.

private verifyIdentEmailAddress(string $ident, int $type) : mixed
Parameters
$ident : string
$type : int
Tags
throws
EmailAccountInvalidFormatException
Return values
mixed

verifyIdentLocalMember()

Verify if a local account is valid.

private verifyIdentLocalMember( &$ident,  $type[, string $instance = '' ]) : mixed
Parameters
$ident :
$type :
$instance : string = ''
Tags
throws
NoUserException
Return values
mixed

Search results