Class Principal.Builder (0.35.0)

public static final class Principal.Builder extends GeneratedMessageV3.Builder<Principal.Builder> implements PrincipalOrBuilder

Principal identifier of a user or a group.

Protobuf type google.cloud.discoveryengine.v1alpha.Principal

Implements

PrincipalOrBuilder

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public Principal.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Principal.Builder
Overrides

build()

public Principal build()
Returns
TypeDescription
Principal

buildPartial()

public Principal buildPartial()
Returns
TypeDescription
Principal

clear()

public Principal.Builder clear()
Returns
TypeDescription
Principal.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public Principal.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
Principal.Builder
Overrides

clearGroupId()

public Principal.Builder clearGroupId()

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Returns
TypeDescription
Principal.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public Principal.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
Principal.Builder
Overrides

clearPrincipal()

public Principal.Builder clearPrincipal()
Returns
TypeDescription
Principal.Builder

clearUserId()

public Principal.Builder clearUserId()

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Returns
TypeDescription
Principal.Builder

This builder for chaining.

clone()

public Principal.Builder clone()
Returns
TypeDescription
Principal.Builder
Overrides

getDefaultInstanceForType()

public Principal getDefaultInstanceForType()
Returns
TypeDescription
Principal

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getGroupId()

public String getGroupId()

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Returns
TypeDescription
String

The groupId.

getGroupIdBytes()

public ByteString getGroupIdBytes()

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Returns
TypeDescription
ByteString

The bytes for groupId.

getPrincipalCase()

public Principal.PrincipalCase getPrincipalCase()
Returns
TypeDescription
Principal.PrincipalCase

getUserId()

public String getUserId()

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Returns
TypeDescription
String

The userId.

getUserIdBytes()

public ByteString getUserIdBytes()

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Returns
TypeDescription
ByteString

The bytes for userId.

hasGroupId()

public boolean hasGroupId()

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Returns
TypeDescription
boolean

Whether the groupId field is set.

hasUserId()

public boolean hasUserId()

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Returns
TypeDescription
boolean

Whether the userId field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(Principal other)

public Principal.Builder mergeFrom(Principal other)
Parameter
NameDescription
otherPrincipal
Returns
TypeDescription
Principal.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public Principal.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Principal.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public Principal.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
Principal.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final Principal.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Principal.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public Principal.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
Principal.Builder
Overrides

setGroupId(String value)

public Principal.Builder setGroupId(String value)

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Parameter
NameDescription
valueString

The groupId to set.

Returns
TypeDescription
Principal.Builder

This builder for chaining.

setGroupIdBytes(ByteString value)

public Principal.Builder setGroupIdBytes(ByteString value)

Group identifier. For Google Workspace user account, group_id should be the google workspace group email. For non-google identity provider user account, group_id is the mapped group identifier configured during the workforcepool config.

string group_id = 2;

Parameter
NameDescription
valueByteString

The bytes for groupId to set.

Returns
TypeDescription
Principal.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public Principal.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
Principal.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final Principal.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
Principal.Builder
Overrides

setUserId(String value)

public Principal.Builder setUserId(String value)

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Parameter
NameDescription
valueString

The userId to set.

Returns
TypeDescription
Principal.Builder

This builder for chaining.

setUserIdBytes(ByteString value)

public Principal.Builder setUserIdBytes(ByteString value)

User identifier. For Google Workspace user account, user_id should be the google workspace user email. For non-google identity provider user account, user_id is the mapped user identifier configured during the workforcepool config.

string user_id = 1;

Parameter
NameDescription
valueByteString

The bytes for userId to set.

Returns
TypeDescription
Principal.Builder

This builder for chaining.