Class FindGroupChatsRequest.Builder (0.57.0)

public static final class FindGroupChatsRequest.Builder extends GeneratedMessage.Builder<FindGroupChatsRequest.Builder> implements FindGroupChatsRequestOrBuilder

A request to get group chat spaces based on user resources.

Protobuf type google.chat.v1.FindGroupChatsRequest

Static Methods

getDescriptor()

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

Methods

addAllUsers(Iterable<String> values)

public FindGroupChatsRequest.Builder addAllUsers(Iterable<String> values)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Iterable<String>

The users to add.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

addUsers(String value)

public FindGroupChatsRequest.Builder addUsers(String value)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The users to add.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

addUsersBytes(ByteString value)

public FindGroupChatsRequest.Builder addUsersBytes(ByteString value)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes of the users to add.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

build()

public FindGroupChatsRequest build()
Returns
Type Description
FindGroupChatsRequest

buildPartial()

public FindGroupChatsRequest buildPartial()
Returns
Type Description
FindGroupChatsRequest

clear()

public FindGroupChatsRequest.Builder clear()
Returns
Type Description
FindGroupChatsRequest.Builder
Overrides

clearPageSize()

public FindGroupChatsRequest.Builder clearPageSize()

Optional. The maximum number of spaces to return. The service might return fewer than this value.

If unspecified, at most 10 spaces are returned.

The maximum value is 30. If you use a value more than 30, it's automatically changed to 30.

Negative values return an INVALID_ARGUMENT error.

int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

clearPageToken()

public FindGroupChatsRequest.Builder clearPageToken()

Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page.

When paginating, all other parameters provided should match the call that provided the token. Passing different values may lead to unexpected results.

string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

clearSpaceView()

public FindGroupChatsRequest.Builder clearSpaceView()

Requested space view type. If unset, defaults to SPACE_VIEW_RESOURCE_NAME_ONLY. Requests that specify SPACE_VIEW_EXPANDED must include scopes that allow reading space data, for example, https://www.googleapis.com/auth/chat.spaces or https://www.googleapis.com/auth/chat.spaces.readonly.

.google.chat.v1.SpaceView space_view = 4;

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

clearUsers()

public FindGroupChatsRequest.Builder clearUsers()

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

getDefaultInstanceForType()

public FindGroupChatsRequest getDefaultInstanceForType()
Returns
Type Description
FindGroupChatsRequest

getDescriptorForType()

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

getPageSize()

public int getPageSize()

Optional. The maximum number of spaces to return. The service might return fewer than this value.

If unspecified, at most 10 spaces are returned.

The maximum value is 30. If you use a value more than 30, it's automatically changed to 30.

Negative values return an INVALID_ARGUMENT error.

int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The pageSize.

getPageToken()

public String getPageToken()

Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page.

When paginating, all other parameters provided should match the call that provided the token. Passing different values may lead to unexpected results.

string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The pageToken.

getPageTokenBytes()

public ByteString getPageTokenBytes()

Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page.

When paginating, all other parameters provided should match the call that provided the token. Passing different values may lead to unexpected results.

string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for pageToken.

getSpaceView()

public SpaceView getSpaceView()

Requested space view type. If unset, defaults to SPACE_VIEW_RESOURCE_NAME_ONLY. Requests that specify SPACE_VIEW_EXPANDED must include scopes that allow reading space data, for example, https://www.googleapis.com/auth/chat.spaces or https://www.googleapis.com/auth/chat.spaces.readonly.

.google.chat.v1.SpaceView space_view = 4;

Returns
Type Description
SpaceView

The spaceView.

getSpaceViewValue()

public int getSpaceViewValue()

Requested space view type. If unset, defaults to SPACE_VIEW_RESOURCE_NAME_ONLY. Requests that specify SPACE_VIEW_EXPANDED must include scopes that allow reading space data, for example, https://www.googleapis.com/auth/chat.spaces or https://www.googleapis.com/auth/chat.spaces.readonly.

.google.chat.v1.SpaceView space_view = 4;

Returns
Type Description
int

The enum numeric value on the wire for spaceView.

getUsers(int index)

public String getUsers(int index)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int

The index of the element to return.

Returns
Type Description
String

The users at the given index.

getUsersBytes(int index)

public ByteString getUsersBytes(int index)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
index int

The index of the value to return.

Returns
Type Description
ByteString

The bytes of the users at the given index.

getUsersCount()

public int getUsersCount()

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

The count of users.

getUsersList()

public ProtocolStringList getUsersList()

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ProtocolStringList

A list containing the users.

internalGetFieldAccessorTable()

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

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(FindGroupChatsRequest other)

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

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

setPageSize(int value)

public FindGroupChatsRequest.Builder setPageSize(int value)

Optional. The maximum number of spaces to return. The service might return fewer than this value.

If unspecified, at most 10 spaces are returned.

The maximum value is 30. If you use a value more than 30, it's automatically changed to 30.

Negative values return an INVALID_ARGUMENT error.

int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value int

The pageSize to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

setPageToken(String value)

public FindGroupChatsRequest.Builder setPageToken(String value)

Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page.

When paginating, all other parameters provided should match the call that provided the token. Passing different values may lead to unexpected results.

string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The pageToken to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

setPageTokenBytes(ByteString value)

public FindGroupChatsRequest.Builder setPageTokenBytes(ByteString value)

Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page.

When paginating, all other parameters provided should match the call that provided the token. Passing different values may lead to unexpected results.

string page_token = 3 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for pageToken to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

setSpaceView(SpaceView value)

public FindGroupChatsRequest.Builder setSpaceView(SpaceView value)

Requested space view type. If unset, defaults to SPACE_VIEW_RESOURCE_NAME_ONLY. Requests that specify SPACE_VIEW_EXPANDED must include scopes that allow reading space data, for example, https://www.googleapis.com/auth/chat.spaces or https://www.googleapis.com/auth/chat.spaces.readonly.

.google.chat.v1.SpaceView space_view = 4;

Parameter
Name Description
value SpaceView

The spaceView to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

setSpaceViewValue(int value)

public FindGroupChatsRequest.Builder setSpaceViewValue(int value)

Requested space view type. If unset, defaults to SPACE_VIEW_RESOURCE_NAME_ONLY. Requests that specify SPACE_VIEW_EXPANDED must include scopes that allow reading space data, for example, https://www.googleapis.com/auth/chat.spaces or https://www.googleapis.com/auth/chat.spaces.readonly.

.google.chat.v1.SpaceView space_view = 4;

Parameter
Name Description
value int

The enum numeric value on the wire for spaceView to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.

setUsers(int index, String value)

public FindGroupChatsRequest.Builder setUsers(int index, String value)

Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request.

The maximum number of users that can be specified in a single request is 49.

Format: users/{user}, where {user} is either the id for the person from the People API, or the id for the user in the Directory API. For example, to find all group chats with the calling user and two other users, with People API profile IDs 123456789 and 987654321, you can use users/123456789 and users/987654321. You can also use the email as an alias for {user}. For example, users/example@gmail.com where example@gmail.com is the email of the Google Chat user.

repeated string users = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
index int

The index to set the value at.

value String

The users to set.

Returns
Type Description
FindGroupChatsRequest.Builder

This builder for chaining.