LTI Integration Library 4.10.3
PHP class library for building LTI integrations
 
Loading...
Searching...
No Matches
OAuthToken.php
1<?php
2
3namespace ceLTIc\LTI\OAuth;
4
13{
14 // Access tokens and request tokens
15
21 public $key;
22
28 public $secret;
29
37 {
38 $this->key = $key;
39 $this->secret = $secret;
40 }
41
48 function to_string()
49 {
50 return 'oauth_token=' .
52 '&oauth_token_secret=' .
53 OAuthUtil::urlencode_rfc3986($this->secret);
54 }
55
61 function __toString()
62 {
63 return $this->to_string();
64 }
65
66}
Class to represent an OAuth token.
__construct($key, $secret)
Class constructor.
__toString()
Convert object to a string.
to_string()
Generates the basic string serialization of a token that a server would respond to request_token and ...
static urlencode_rfc3986($input)
URL encode.
Definition OAuthUtil.php:22