|
Cheetah
|
Public Member Functions | |
| __construct (array $metadata) | |
| getField ($field, $default=null) | |
| getProperty ($field, $default=null) | |
| getChildProperty ($parentField, $field, $default=null) | |
| getErrorProperty ($field, $default=null) | |
| getMetadataProperty ($field, $default=null) | |
| getAppId () | |
| getApplication () | |
| isError () | |
| getErrorCode () | |
| getErrorMessage () | |
| getErrorSubcode () | |
| getExpiresAt () | |
| getIsValid () | |
| getIssuedAt () | |
| getMetadata () | |
| getSso () | |
| getAuthType () | |
| getAuthNonce () | |
| getProfileId () | |
| getScopes () | |
| getUserId () | |
| validateAppId ($appId) | |
| validateUserId ($userId) | |
| validateExpiration () | |
Protected Attributes | |
| $metadata = [] | |
Static Protected Attributes | |
| static | $dateProperties = ['expires_at', 'issued_at'] |
Definition at line 36 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::__construct | ( | array | $metadata | ) |
| array | $metadata |
| FacebookSDKException |
Definition at line 57 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getAppId | ( | ) |
The ID of the application this access token is for.
Definition at line 154 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getApplication | ( | ) |
Name of the application this access token is for.
Definition at line 164 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getAuthNonce | ( | ) |
The 'auth_nonce' child property from the 'metadata' parent property.
Definition at line 281 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getAuthType | ( | ) |
The 'auth_type' child property from the 'metadata' parent property.
Definition at line 271 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getChildProperty | ( | $parentField, | |
| $field, | |||
$default = null |
|||
| ) |
Returns a value from a child property in the metadata.
| string | $parentField | The parent property. |
| string | $field | The property to retrieve. |
| mixed | $default | The default to return if the property doesn't exist. |
Definition at line 110 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getErrorCode | ( | ) |
The error code for the error.
Definition at line 185 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getErrorMessage | ( | ) |
The error message for the error.
Definition at line 195 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getErrorProperty | ( | $field, | |
$default = null |
|||
| ) |
Returns a value from the error metadata.
| string | $field | The property to retrieve. |
| mixed | $default | The default to return if the property doesn't exist. |
Definition at line 131 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getErrorSubcode | ( | ) |
The error subcode for the error.
Definition at line 205 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getExpiresAt | ( | ) |
DateTime when this access token expires.
Definition at line 215 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getField | ( | $field, | |
$default = null |
|||
| ) |
Returns a value from the metadata.
| string | $field | The property to retrieve. |
| mixed | $default | The default to return if the property doesn't exist. |
Definition at line 76 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getIssuedAt | ( | ) |
DateTime when this access token was issued.
Note that the issued_at field is not returned for short-lived access tokens.
Definition at line 240 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getIsValid | ( | ) |
Whether the access token is still valid or not.
Definition at line 225 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getMetadata | ( | ) |
General metadata associated with the access token. Can contain data like 'sso', 'auth_type', 'auth_nonce'.
Definition at line 251 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getMetadataProperty | ( | $field, | |
$default = null |
|||
| ) |
Returns a value from the "metadata" metadata. Brain explodes
| string | $field | The property to retrieve. |
| mixed | $default | The default to return if the property doesn't exist. |
Definition at line 144 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getProfileId | ( | ) |
For impersonated access tokens, the ID of the page this token contains.
Definition at line 292 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getProperty | ( | $field, | |
$default = null |
|||
| ) |
Returns a value from the metadata.
| string | $field | The property to retrieve. |
| mixed | $default | The default to return if the property doesn't exist. |
Definition at line 96 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getScopes | ( | ) |
List of permissions that the user has granted for the app in this access token.
Definition at line 303 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getSso | ( | ) |
The 'sso' child property from the 'metadata' parent property.
Definition at line 261 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::getUserId | ( | ) |
The ID of the user this access token is for.
Definition at line 313 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::isError | ( | ) |
Any error that a request to the graph api would return due to the access token.
Definition at line 175 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::validateAppId | ( | $appId | ) |
Ensures the app ID from the access token metadata is what we expect.
| string | $appId |
| FacebookSDKException |
Definition at line 326 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::validateExpiration | ( | ) |
Ensures the access token has not expired yet.
| FacebookSDKException |
Definition at line 353 of file AccessTokenMetadata.php.
| Facebook\Authentication\AccessTokenMetadata::validateUserId | ( | $userId | ) |
Ensures the user ID from the access token metadata is what we expect.
| string | $userId |
| FacebookSDKException |
Definition at line 341 of file AccessTokenMetadata.php.
|
staticprotected |
Definition at line 50 of file AccessTokenMetadata.php.
|
protected |
Definition at line 43 of file AccessTokenMetadata.php.