FriendRequestRepositoryInterface
-
mixin
-
Table of Contents
Methods
-
countFriendRequest()
: void
-
countTotalFriendRequest()
: int
-
deleteAllRequestByUserIdAndOwnerId()
: bool
-
deleteRequestById()
: bool
-
deleteRequestByUserIdAndOwnerId()
: bool
-
getRequest()
: Model|FriendRequest|object|null
-
isRequested()
: bool
-
markAllAsRead()
: void
-
sendRequest()
: array<int, mixed>
-
updateRequest()
: array<int, mixed>
-
viewRequests()
: Paginator
countFriendRequest()
public
countFriendRequest(User $context, stdClass $data) : void
Parameters
-
$context
: User
-
-
$data
: stdClass
-
-
throws
-
AuthorizationException
countTotalFriendRequest()
public
countTotalFriendRequest(User $context) : int
Parameters
-
$context
: User
-
-
throws
-
AuthorizationException
deleteAllRequestByUserIdAndOwnerId()
public
deleteAllRequestByUserIdAndOwnerId(int $userId, int $ownerId) : bool
Parameters
-
$userId
: int
-
-
$ownerId
: int
-
deleteRequestById()
public
deleteRequestById(User $context, int $id) : bool
Parameters
-
$context
: User
-
-
$id
: int
-
-
throws
-
AuthorizationException
deleteRequestByUserIdAndOwnerId()
public
deleteRequestByUserIdAndOwnerId(User $context, int $ownerId) : bool
Parameters
-
$context
: User
-
-
$ownerId
: int
-
-
throws
-
AuthorizationException
getRequest()
public
getRequest(int $userId, int $ownerId) : Model|FriendRequest|object|null
Parameters
-
$userId
: int
-
-
$ownerId
: int
-
isRequested()
public
isRequested(int $userId, int $ownerId) : bool
Parameters
-
$userId
: int
-
-
$ownerId
: int
-
markAllAsRead()
public
markAllAsRead(User $owner) : void
Parameters
-
$owner
: User
-
sendRequest()
public
sendRequest(User $user, User $owner) : array<int, mixed>
Parameters
-
$user
: User
-
-
$owner
: User
-
-
throws
-
AuthorizationException
-
throws
-
ValidatorException
Return values
array<int, mixed>
updateRequest()
public
updateRequest(User $user, User $owner, string $action) : array<int, mixed>
Parameters
-
$user
: User
-
-
$owner
: User
-
-
$action
: string
-
-
throws
-
AuthorizationException
-
throws
-
ValidatorException
Return values
array<int, mixed>
viewRequests()
public
viewRequests(User $context, array<string, mixed> $attributes) : Paginator
Parameters
-
$context
: User
-
-
$attributes
: array<string, mixed>
-
-
throws
-
AuthorizationException