LTI Integration Library 5.1.4
PHP class library for building LTI integrations
 
Loading...
Searching...
No Matches
ResourceLinkShareKey Class Reference

Class to represent a platform resource link share key. More...

Public Member Functions

 __construct (ResourceLink $resourceLink, ?string $id=null)
 Class constructor.
 
void initialize ()
 Initialise the resource link share key.
 
void initialise ()
 Initialise the resource link share key.
 
bool save ()
 Save the resource link share key to the database.
 
bool delete ()
 Delete the resource link share key from the database.
 
string getId ()
 Get share key value.
 

Public Attributes

const MAX_SHARE_KEY_LIFE = 168
 Maximum permitted life for a share key value.
 
const DEFAULT_SHARE_KEY_LIFE = 24
 Default life for a share key value.
 
const MIN_SHARE_KEY_LENGTH = 5
 Minimum length for a share key value.
 
const MAX_SHARE_KEY_LENGTH = 32
 Maximum length for a share key value.
 
int $resourceLinkId = null
 ID for resource link being shared.
 
int $length = null
 Length of share key.
 
int $life = null
 Life of share key.
 
bool $autoApprove = false
 Whether the sharing arrangement should be automatically approved when first used.
 
int $expires = null
 Timestamp for when the share key expires.
 

Detailed Description

Class to represent a platform resource link share key.

Author
Stephen P Vickers steph.nosp@m.en@s.nosp@m.pvsof.nosp@m.twar.nosp@m.eprod.nosp@m.ucts.nosp@m..com
Licence: http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public License, version 3

Constructor & Destructor Documentation

◆ __construct()

__construct ( ResourceLink $resourceLink,
?string $id = null )

Class constructor.

Parameters
ResourceLink$resourceLinkResourceLink object
string | null$idValue of share key (optional, default is null)

Member Function Documentation

◆ delete()

bool delete ( )

Delete the resource link share key from the database.

Returns
bool True if the share key was successfully deleted

◆ getId()

string getId ( )

Get share key value.

Returns
string Share key value

Referenced by DataConnector_pgsql\saveAccessToken(), and DataConnector_sql\saveAccessToken().

◆ initialise()

void initialise ( )

Initialise the resource link share key.

Synonym for initialize().

◆ save()

bool save ( )

Save the resource link share key to the database.

Returns
bool True if the share key was successfully saved

References ResourceLinkShareKey\initialize().