O365ProfileGetDataService
in package
O365ProfileGetDataService service gives basic information about the user.
Table of Contents
- $o365Graph : GraphService
- The o365.graph service.
- __construct() : mixed
- Constructs an O365ProfileGetDataService object.
- getProfileData() : array<string|int, mixed>
- Method gives the basic current logged in user information.
- getUserInitials() : string
- Get the users initials from the profile data.
Properties
$o365Graph
The o365.graph service.
protected
GraphService
$o365Graph
Methods
__construct()
Constructs an O365ProfileGetDataService object.
public
__construct(GraphService $o365_graph) : mixed
Parameters
- $o365_graph : GraphService
-
The o365.graph service.
Return values
mixed —getProfileData()
Method gives the basic current logged in user information.
public
getProfileData([null|int $user_id = NULL ][, string $photoSize = '64x64' ]) : array<string|int, mixed>
Parameters
- $user_id : null|int = NULL
-
The user ID or NULL.
- $photoSize : string = '64x64'
-
The size of the user photo we need to retrieve.
Tags
Return values
array<string|int, mixed> —The list of user data.
getUserInitials()
Get the users initials from the profile data.
public
getUserInitials(array<string|int, mixed> $profileData) : string
Parameters
- $profileData : array<string|int, mixed>
-
The users profile data.
Return values
string —The users initial.