Class OAuthCredential (3.16.0)

public final class OAuthCredential extends GeneratedMessageV3 implements OAuthCredentialOrBuilder

Represents an OAuth token of the account that authorized the Connection, and associated metadata.

Protobuf type google.devtools.cloudbuild.v2.OAuthCredential

Static Fields

OAUTH_TOKEN_SECRET_VERSION_FIELD_NUMBER

public static final int OAUTH_TOKEN_SECRET_VERSION_FIELD_NUMBER
Field Value
TypeDescription
int

USERNAME_FIELD_NUMBER

public static final int USERNAME_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static OAuthCredential getDefaultInstance()
Returns
TypeDescription
OAuthCredential

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static OAuthCredential.Builder newBuilder()
Returns
TypeDescription
OAuthCredential.Builder

newBuilder(OAuthCredential prototype)

public static OAuthCredential.Builder newBuilder(OAuthCredential prototype)
Parameter
NameDescription
prototypeOAuthCredential
Returns
TypeDescription
OAuthCredential.Builder

parseDelimitedFrom(InputStream input)

public static OAuthCredential parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static OAuthCredential parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static OAuthCredential parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static OAuthCredential parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static OAuthCredential parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static OAuthCredential parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static OAuthCredential parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
OAuthCredential
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<OAuthCredential> parser()
Returns
TypeDescription
Parser<OAuthCredential>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDefaultInstanceForType()

public OAuthCredential getDefaultInstanceForType()
Returns
TypeDescription
OAuthCredential

getOauthTokenSecretVersion()

public String getOauthTokenSecretVersion()

A SecretManager resource containing the OAuth token that authorizes the Cloud Build connection. Format: projects/*/secrets/*/versions/*.

string oauth_token_secret_version = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
String

The oauthTokenSecretVersion.

getOauthTokenSecretVersionBytes()

public ByteString getOauthTokenSecretVersionBytes()

A SecretManager resource containing the OAuth token that authorizes the Cloud Build connection. Format: projects/*/secrets/*/versions/*.

string oauth_token_secret_version = 1 [(.google.api.resource_reference) = { ... }

Returns
TypeDescription
ByteString

The bytes for oauthTokenSecretVersion.

getParserForType()

public Parser<OAuthCredential> getParserForType()
Returns
TypeDescription
Parser<OAuthCredential>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getUnknownFields()

public final UnknownFieldSet getUnknownFields()
Returns
TypeDescription
UnknownFieldSet
Overrides

getUsername()

public String getUsername()

Output only. The username associated to this token.

string username = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
String

The username.

getUsernameBytes()

public ByteString getUsernameBytes()

Output only. The username associated to this token.

string username = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
TypeDescription
ByteString

The bytes for username.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public OAuthCredential.Builder newBuilderForType()
Returns
TypeDescription
OAuthCredential.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected OAuthCredential.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
OAuthCredential.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public OAuthCredential.Builder toBuilder()
Returns
TypeDescription
OAuthCredential.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException