Class PushCredentialsRequest.OAuthToken.Builder (0.81.0)

public static final class PushCredentialsRequest.OAuthToken.Builder extends GeneratedMessage.Builder<PushCredentialsRequest.OAuthToken.Builder> implements PushCredentialsRequest.OAuthTokenOrBuilder

OAuth token.

Protobuf type google.cloud.workstations.v1beta.PushCredentialsRequest.OAuthToken

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public PushCredentialsRequest.OAuthToken build()
Returns
Type Description
PushCredentialsRequest.OAuthToken

buildPartial()

public PushCredentialsRequest.OAuthToken buildPartial()
Returns
Type Description
PushCredentialsRequest.OAuthToken

clear()

public PushCredentialsRequest.OAuthToken.Builder clear()
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder
Overrides

clearAccessToken()

public PushCredentialsRequest.OAuthToken.Builder clearAccessToken()

Required. The OAuth token.

string access_token = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

clearEmail()

public PushCredentialsRequest.OAuthToken.Builder clearEmail()

Optional. The email address encapsulated in the OAuth token.

string email = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

clearExpireTime()

public PushCredentialsRequest.OAuthToken.Builder clearExpireTime()

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

clearScopes()

public PushCredentialsRequest.OAuthToken.Builder clearScopes()

Optional. The scopes encapsulated in the OAuth token. See https://developers.google.com/identity/protocols/oauth2/scopes for more information.

string scopes = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

getAccessToken()

public String getAccessToken()

Required. The OAuth token.

string access_token = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The accessToken.

getAccessTokenBytes()

public ByteString getAccessTokenBytes()

Required. The OAuth token.

string access_token = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for accessToken.

getDefaultInstanceForType()

public PushCredentialsRequest.OAuthToken getDefaultInstanceForType()
Returns
Type Description
PushCredentialsRequest.OAuthToken

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getEmail()

public String getEmail()

Optional. The email address encapsulated in the OAuth token.

string email = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The email.

getEmailBytes()

public ByteString getEmailBytes()

Optional. The email address encapsulated in the OAuth token.

string email = 1 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for email.

getExpireTime()

public Timestamp getExpireTime()

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Timestamp

The expireTime.

getExpireTimeBuilder()

public Timestamp.Builder getExpireTimeBuilder()

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Builder

getExpireTimeOrBuilder()

public TimestampOrBuilder getExpireTimeOrBuilder()

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
TimestampOrBuilder

getScopes()

public String getScopes()

Optional. The scopes encapsulated in the OAuth token. See https://developers.google.com/identity/protocols/oauth2/scopes for more information.

string scopes = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The scopes.

getScopesBytes()

public ByteString getScopesBytes()

Optional. The scopes encapsulated in the OAuth token. See https://developers.google.com/identity/protocols/oauth2/scopes for more information.

string scopes = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for scopes.

hasExpireTime()

public boolean hasExpireTime()

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the expireTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeExpireTime(Timestamp value)

public PushCredentialsRequest.OAuthToken.Builder mergeExpireTime(Timestamp value)

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Timestamp
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

mergeFrom(PushCredentialsRequest.OAuthToken other)

public PushCredentialsRequest.OAuthToken.Builder mergeFrom(PushCredentialsRequest.OAuthToken other)
Parameter
Name Description
other PushCredentialsRequest.OAuthToken
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public PushCredentialsRequest.OAuthToken.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public PushCredentialsRequest.OAuthToken.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder
Overrides

setAccessToken(String value)

public PushCredentialsRequest.OAuthToken.Builder setAccessToken(String value)

Required. The OAuth token.

string access_token = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The accessToken to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

setAccessTokenBytes(ByteString value)

public PushCredentialsRequest.OAuthToken.Builder setAccessTokenBytes(ByteString value)

Required. The OAuth token.

string access_token = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for accessToken to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

setEmail(String value)

public PushCredentialsRequest.OAuthToken.Builder setEmail(String value)

Optional. The email address encapsulated in the OAuth token.

string email = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The email to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

setEmailBytes(ByteString value)

public PushCredentialsRequest.OAuthToken.Builder setEmailBytes(ByteString value)

Optional. The email address encapsulated in the OAuth token.

string email = 1 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for email to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

setExpireTime(Timestamp value)

public PushCredentialsRequest.OAuthToken.Builder setExpireTime(Timestamp value)

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value Timestamp
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

setExpireTime(Timestamp.Builder builderForValue)

public PushCredentialsRequest.OAuthToken.Builder setExpireTime(Timestamp.Builder builderForValue)

Optional. The time the OAuth access token will expire. This should be the time the access token was generated plus the expires_in offset returned from the Access Token Response.

.google.protobuf.Timestamp expire_time = 4 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

setScopes(String value)

public PushCredentialsRequest.OAuthToken.Builder setScopes(String value)

Optional. The scopes encapsulated in the OAuth token. See https://developers.google.com/identity/protocols/oauth2/scopes for more information.

string scopes = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The scopes to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.

setScopesBytes(ByteString value)

public PushCredentialsRequest.OAuthToken.Builder setScopesBytes(ByteString value)

Optional. The scopes encapsulated in the OAuth token. See https://developers.google.com/identity/protocols/oauth2/scopes for more information.

string scopes = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for scopes to set.

Returns
Type Description
PushCredentialsRequest.OAuthToken.Builder

This builder for chaining.