google.iam.admin.v1.ServiceAccount
*/
class ServiceAccount extends \Google\Protobuf\Internal\Message
{
/**
* The resource name of the service account in the following format:
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
* Requests using `-` as a wildcard for the `PROJECT_ID` will infer the
* project from the `account` and the `ACCOUNT` value can be the `email`
* address or the `unique_id` of the service account.
* In responses the resource name will always be in the format
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
*
* Generated from protobuf field string name = 1;
*/
private $name = '';
/**
* @OutputOnly The id of the project that owns the service account.
*
* Generated from protobuf field string project_id = 2;
*/
private $project_id = '';
/**
* @OutputOnly The unique and stable id of the service account.
*
* Generated from protobuf field string unique_id = 4;
*/
private $unique_id = '';
/**
* @OutputOnly The email address of the service account.
*
* Generated from protobuf field string email = 5;
*/
private $email = '';
/**
* Optional. A user-specified name for the service account.
* Must be less than or equal to 100 UTF-8 bytes.
*
* Generated from protobuf field string display_name = 6;
*/
private $display_name = '';
/**
* Optional. Note: `etag` is an inoperable legacy field that is only returned
* for backwards compatibility.
*
* Generated from protobuf field bytes etag = 7;
*/
private $etag = '';
/**
* @OutputOnly. The OAuth2 client id for the service account.
* This is used in conjunction with the OAuth2 clientconfig API to make
* three legged OAuth2 (3LO) flows to access the data of Google users.
*
* Generated from protobuf field string oauth2_client_id = 9;
*/
private $oauth2_client_id = '';
/**
* Constructor.
*
* @param array $data {
* Optional. Data for populating the Message object.
*
* @type string $name
* The resource name of the service account in the following format:
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
* Requests using `-` as a wildcard for the `PROJECT_ID` will infer the
* project from the `account` and the `ACCOUNT` value can be the `email`
* address or the `unique_id` of the service account.
* In responses the resource name will always be in the format
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
* @type string $project_id
* @OutputOnly The id of the project that owns the service account.
* @type string $unique_id
* @OutputOnly The unique and stable id of the service account.
* @type string $email
* @OutputOnly The email address of the service account.
* @type string $display_name
* Optional. A user-specified name for the service account.
* Must be less than or equal to 100 UTF-8 bytes.
* @type string $etag
* Optional. Note: `etag` is an inoperable legacy field that is only returned
* for backwards compatibility.
* @type string $oauth2_client_id
* @OutputOnly. The OAuth2 client id for the service account.
* This is used in conjunction with the OAuth2 clientconfig API to make
* three legged OAuth2 (3LO) flows to access the data of Google users.
* }
*/
public function __construct($data = NULL) {
\GPBMetadata\Google\Iam\Admin\V1\Iam::initOnce();
parent::__construct($data);
}
/**
* The resource name of the service account in the following format:
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
* Requests using `-` as a wildcard for the `PROJECT_ID` will infer the
* project from the `account` and the `ACCOUNT` value can be the `email`
* address or the `unique_id` of the service account.
* In responses the resource name will always be in the format
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
*
* Generated from protobuf field string name = 1;
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* The resource name of the service account in the following format:
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
* Requests using `-` as a wildcard for the `PROJECT_ID` will infer the
* project from the `account` and the `ACCOUNT` value can be the `email`
* address or the `unique_id` of the service account.
* In responses the resource name will always be in the format
* `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
*
* Generated from protobuf field string name = 1;
* @param string $var
* @return $this
*/
public function setName($var)
{
GPBUtil::checkString($var, True);
$this->name = $var;
return $this;
}
/**
* @OutputOnly The id of the project that owns the service account.
*
* Generated from protobuf field string project_id = 2;
* @return string
*/
public function getProjectId()
{
return $this->project_id;
}
/**
* @OutputOnly The id of the project that owns the service account.
*
* Generated from protobuf field string project_id = 2;
* @param string $var
* @return $this
*/
public function setProjectId($var)
{
GPBUtil::checkString($var, True);
$this->project_id = $var;
return $this;
}
/**
* @OutputOnly The unique and stable id of the service account.
*
* Generated from protobuf field string unique_id = 4;
* @return string
*/
public function getUniqueId()
{
return $this->unique_id;
}
/**
* @OutputOnly The unique and stable id of the service account.
*
* Generated from protobuf field string unique_id = 4;
* @param string $var
* @return $this
*/
public function setUniqueId($var)
{
GPBUtil::checkString($var, True);
$this->unique_id = $var;
return $this;
}
/**
* @OutputOnly The email address of the service account.
*
* Generated from protobuf field string email = 5;
* @return string
*/
public function getEmail()
{
return $this->email;
}
/**
* @OutputOnly The email address of the service account.
*
* Generated from protobuf field string email = 5;
* @param string $var
* @return $this
*/
public function setEmail($var)
{
GPBUtil::checkString($var, True);
$this->email = $var;
return $this;
}
/**
* Optional. A user-specified name for the service account.
* Must be less than or equal to 100 UTF-8 bytes.
*
* Generated from protobuf field string display_name = 6;
* @return string
*/
public function getDisplayName()
{
return $this->display_name;
}
/**
* Optional. A user-specified name for the service account.
* Must be less than or equal to 100 UTF-8 bytes.
*
* Generated from protobuf field string display_name = 6;
* @param string $var
* @return $this
*/
public function setDisplayName($var)
{
GPBUtil::checkString($var, True);
$this->display_name = $var;
return $this;
}
/**
* Optional. Note: `etag` is an inoperable legacy field that is only returned
* for backwards compatibility.
*
* Generated from protobuf field bytes etag = 7;
* @return string
*/
public function getEtag()
{
return $this->etag;
}
/**
* Optional. Note: `etag` is an inoperable legacy field that is only returned
* for backwards compatibility.
*
* Generated from protobuf field bytes etag = 7;
* @param string $var
* @return $this
*/
public function setEtag($var)
{
GPBUtil::checkString($var, False);
$this->etag = $var;
return $this;
}
/**
* @OutputOnly. The OAuth2 client id for the service account.
* This is used in conjunction with the OAuth2 clientconfig API to make
* three legged OAuth2 (3LO) flows to access the data of Google users.
*
* Generated from protobuf field string oauth2_client_id = 9;
* @return string
*/
public function getOauth2ClientId()
{
return $this->oauth2_client_id;
}
/**
* @OutputOnly. The OAuth2 client id for the service account.
* This is used in conjunction with the OAuth2 clientconfig API to make
* three legged OAuth2 (3LO) flows to access the data of Google users.
*
* Generated from protobuf field string oauth2_client_id = 9;
* @param string $var
* @return $this
*/
public function setOauth2ClientId($var)
{
GPBUtil::checkString($var, True);
$this->oauth2_client_id = $var;
return $this;
}
}