Class GroupsListResponse
java.lang.Object
com.hubspot.slack.client.models.response.group.GroupsListResponse
- All Implemented Interfaces:
GroupsListResponseIF,SlackResponse
@Generated(from="GroupsListResponseIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class GroupsListResponse
extends Object
implements GroupsListResponseIF
Immutable implementation of
GroupsListResponseIF.
Use the builder to create immutable instances:
GroupsListResponse.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic GroupsListResponse.Builderbuilder()Creates a builder forGroupsListResponse.static GroupsListResponsecopyOf(GroupsListResponseIF instance) Creates an immutable copy of aGroupsListResponseIFvalue.booleanThis instance is equal to all instances ofGroupsListResponsethat have equal attribute values.inthashCode()Computes a hash code from attributes:ok,responseMetadata,groups.booleanisOk()toString()Prints the immutable valueGroupsListResponsewith attribute values.final GroupsListResponsewithGroups(SlackGroup... elements) Copy the current immutable object with elements that replace the content ofgroups.final GroupsListResponsewithGroups(Iterable<? extends SlackGroup> elements) Copy the current immutable object with elements that replace the content ofgroups.final GroupsListResponsewithOk(boolean value) Copy the current immutable object by setting a value for theokattribute.final GroupsListResponseCopy the current immutable object by setting a present value for the optionalresponseMetadataattribute.final GroupsListResponsewithResponseMetadata(Optional<? extends ResponseMetadata> optional) Copy the current immutable object by setting an optional value for theresponseMetadataattribute.
-
Method Details
-
isOk
public boolean isOk()- Specified by:
isOkin interfaceSlackResponse- Returns:
- The value of the
okattribute
-
getResponseMetadata
- Specified by:
getResponseMetadatain interfaceSlackResponse- Returns:
- The value of the
responseMetadataattribute
-
getGroups
- Specified by:
getGroupsin interfaceGroupsListResponseIF- Returns:
- The value of the
groupsattribute
-
withOk
Copy the current immutable object by setting a value for theokattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for ok- Returns:
- A modified copy or the
thisobject
-
withResponseMetadata
Copy the current immutable object by setting a present value for the optionalresponseMetadataattribute.- Parameters:
value- The value for responseMetadata,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withResponseMetadata
Copy the current immutable object by setting an optional value for theresponseMetadataattribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for responseMetadata- Returns:
- A modified copy or
thisif not changed
-
withGroups
Copy the current immutable object with elements that replace the content ofgroups.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withGroups
Copy the current immutable object with elements that replace the content ofgroups. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of groups elements to set- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofGroupsListResponsethat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:ok,responseMetadata,groups. -
toString
Prints the immutable valueGroupsListResponsewith attribute values. -
copyOf
Creates an immutable copy of aGroupsListResponseIFvalue. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance- The instance to copy- Returns:
- A copied immutable GroupsListResponse instance
-
builder
Creates a builder forGroupsListResponse.GroupsListResponse.builder() .setOk(boolean) // requiredok.setResponseMetadata(Optional<ResponseMetadata>) // optionalresponseMetadata.addGroups|addAllGroups(com.hubspot.slack.client.models.group.SlackGroup) //groupselements .build();- Returns:
- A new GroupsListResponse builder
-