You are here

public function SocialAuthUser::__construct in Social Auth 3.x

Same name and namespace in other branches
  1. 8.2 src/User/SocialAuthUser.php \Drupal\social_auth\User\SocialAuthUser::__construct()

User constructor.

Parameters

string $name: The user's name.

string $email: The user's email address.

string $provider_user_id: The unique ID in provider.

string $token: The access token for making API calls.

string|bool $picture_url: The user's picture.

array|null $additional_data: The additional user data to be stored in database.

File

src/User/SocialAuthUser.php, line 96

Class

SocialAuthUser
User data used for authentication with Drupal.

Namespace

Drupal\social_auth\User

Code

public function __construct($name, $email, $provider_user_id, $token, $picture_url = NULL, $additional_data = NULL) {
  $this->name = $name;
  $this->email = $email;
  $this->providerUserID = $provider_user_id;
  $this->token = $token;
  $this->pictureUrl = $picture_url;
  $this->additionalData = $additional_data;
}