| 1 |
<?php |
| 2 |
/*! |
| 3 |
* Hybridauth |
| 4 |
* https://hybridauth.github.io | https://github.com/hybridauth/hybridauth |
| 5 |
* (c) 2017 Hybridauth authors | https://hybridauth.github.io/license.html |
| 6 |
*/ |
| 7 |
|
| 8 |
namespace Hybridauth\User; |
| 9 |
|
| 10 |
use Hybridauth\Exception\UnexpectedValueException; |
| 11 |
|
| 12 |
/** |
| 13 |
* Hybridauth\User\Contact |
| 14 |
*/ |
| 15 |
final class Contact |
| 16 |
{ |
| 17 |
/** |
| 18 |
* The Unique contact user ID |
| 19 |
* |
| 20 |
* @var string |
| 21 |
*/ |
| 22 |
public $identifier = null; |
| 23 |
|
| 24 |
/** |
| 25 |
* User website, blog, web page |
| 26 |
* |
| 27 |
* @var string |
| 28 |
*/ |
| 29 |
public $webSiteURL = null; |
| 30 |
|
| 31 |
/** |
| 32 |
* URL link to profile page on the IDp web site |
| 33 |
* |
| 34 |
* @var string |
| 35 |
*/ |
| 36 |
public $profileURL = null; |
| 37 |
|
| 38 |
/** |
| 39 |
* URL link to user photo or avatar |
| 40 |
* |
| 41 |
* @var string |
| 42 |
*/ |
| 43 |
public $photoURL = null; |
| 44 |
|
| 45 |
/** |
| 46 |
* User displayName provided by the IDp or a concatenation of first and last name |
| 47 |
* |
| 48 |
* @var string |
| 49 |
*/ |
| 50 |
public $displayName = null; |
| 51 |
|
| 52 |
/** |
| 53 |
* A short about_me |
| 54 |
* |
| 55 |
* @var string |
| 56 |
*/ |
| 57 |
public $description = null; |
| 58 |
|
| 59 |
/** |
| 60 |
* User email. Not all of IDp grant access to the user email |
| 61 |
* |
| 62 |
* @var string |
| 63 |
*/ |
| 64 |
public $email = null; |
| 65 |
|
| 66 |
/** |
| 67 |
* Prevent the providers adapters from adding new fields. |
| 68 |
* |
| 69 |
* @param string $name |
| 70 |
* @param mixed $value |
| 71 |
* |
| 72 |
* @throws UnexpectedValueException |
| 73 |
*/ |
| 74 |
public function __set($name, $value) |
| 75 |
{ |
| 76 |
throw new UnexpectedValueException(sprintf('Adding new property "%s" to %s is not allowed.', $name, __CLASS__)); |
| 77 |
} |
| 78 |
} |
| 79 |
|