TokenIssueRequest implements ArrayCopyable, Arrayable, Jsonable Uses ArrayTrait, JsonTrait
Request to Authlete's /api/auth/token/issue API.
Interfaces, Classes and Traits
- ArrayCopyable
- Interface to declare instances can be converted into/from arrays.
- Arrayable
- Interface to declare that instances can be converted into an array.
- Jsonable
- Interface to declare that instances can be converted into JSON strings.
Table of Contents
- copyFromArray() : mixed
- Copy the content of the given array into this object.
- copyToArray() : mixed
- Copy the content of this object into the given array.
- fromArray() : static
- Convert an array into an instance of this class.
- fromJson() : static
- Convert a JSON string into an instance of this class.
- getProperties() : array<string|int, Property>
- Get properties that are associated with a newly created access token.
- getSubject() : string
- Get the subject (= unique identifier) of the authenticated end-user.
- getTicket() : string
- Get the ticket issued by Authlete's /api/auth/token API.
- setProperties() : TokenIssueRequest
- Set properties that are associated with a newly created access token.
- setSubject() : TokenIssueRequest
- Set the subject (= unique identifier) of the authenticated end-user.
- setTicket() : TokenIssueRequest
- Set the ticket issued by Authlete's /api/auth/token API.
- toArray() : array<string|int, mixed>
- Convert this object into an array.
- toJson() : string
- Convert this object into a JSON string.
Methods
copyFromArray()
Copy the content of the given array into this object.
public
copyFromArray(array<string|int, mixed> &$array) : mixed
Parameters
- $array : array<string|int, mixed>
Return values
mixed —copyToArray()
Copy the content of this object into the given array.
public
copyToArray(array<string|int, mixed> &$array) : mixed
Parameters
- $array : array<string|int, mixed>
Return values
mixed —fromArray()
Convert an array into an instance of this class.
public
static fromArray([array<string|int, mixed> $array = null ]) : static
This static function returns a new instance of this class.
If $array
is null
, null
is returned.
Parameters
- $array : array<string|int, mixed> = null
-
An array
Return values
static —An instance of this class.
fromJson()
Convert a JSON string into an instance of this class.
public
static fromJson(string $json) : static
This static function returns a new instance of this class.
If $json
is null
or the type of $json
is not string
,
null
is returned.
Parameters
- $json : string
-
A JSON string.
Return values
static —An instance of this class.
getProperties()
Get properties that are associated with a newly created access token.
public
getProperties() : array<string|int, Property>
Return values
array<string|int, Property> —Properties associated with the access token.
getSubject()
Get the subject (= unique identifier) of the authenticated end-user.
public
getSubject() : string
Return values
string —The subject of the end-user.
getTicket()
Get the ticket issued by Authlete's /api/auth/token API.
public
getTicket() : string
Return values
string —The ticket issued by Authlete's /api/auth/token API.
setProperties()
Set properties that are associated with a newly created access token.
public
setProperties([array<string|int, Property> $properties = null ]) : TokenIssueRequest
Parameters
- $properties : array<string|int, Property> = null
-
Properties associated with the access token.
Return values
TokenIssueRequest —$this
object.
setSubject()
Set the subject (= unique identifier) of the authenticated end-user.
public
setSubject(string $subject) : TokenIssueRequest
Parameters
- $subject : string
-
The subject of the end-user.
Return values
TokenIssueRequest —$this
object.
setTicket()
Set the ticket issued by Authlete's /api/auth/token API.
public
setTicket(string $ticket) : TokenIssueRequest
Parameters
- $ticket : string
-
The ticket issued by Authlete's /api/auth/token API.
Return values
TokenIssueRequest —$this
object.
toArray()
Convert this object into an array.
public
toArray() : array<string|int, mixed>
Return values
array<string|int, mixed> —An array.
toJson()
Convert this object into a JSON string.
public
toJson(int $options) : string
Parameters
- $options : int
-
Options passed to
json_encode()
. This parameter is optional and its default value is 0.
Return values
string —A JSON string.