Class ModalViewCommandResponse
java.lang.Object
com.hubspot.slack.client.models.response.views.ModalViewCommandResponse
- All Implemented Interfaces:
SlackResponse,ModalViewCommandResponseIF
@Generated(from="ModalViewCommandResponseIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ModalViewCommandResponse
extends Object
implements ModalViewCommandResponseIF
Immutable implementation of
ModalViewCommandResponseIF.
Use the builder to create immutable instances:
ModalViewCommandResponse.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeModalViewCommandResponse. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forModalViewCommandResponse.static ModalViewCommandResponsecopyOf(ModalViewCommandResponseIF instance) Creates an immutable copy of aModalViewCommandResponseIFvalue.booleanThis instance is equal to all instances ofModalViewCommandResponsethat have equal attribute values.getView()inthashCode()Computes a hash code from attributes:ok,responseMetadata,view.booleanisOk()toString()Prints the immutable valueModalViewCommandResponsewith attribute values.final ModalViewCommandResponsewithOk(boolean value) Copy the current immutable object by setting a value for theokattribute.final ModalViewCommandResponseCopy the current immutable object by setting a present value for the optionalresponseMetadataattribute.final ModalViewCommandResponsewithResponseMetadata(Optional<? extends ResponseMetadata> optional) Copy the current immutable object by setting an optional value for theresponseMetadataattribute.final ModalViewCommandResponsewithView(ModalViewResponse value) Copy the current immutable object by setting a value for theviewattribute.
-
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
-
getView
- Specified by:
getViewin interfaceModalViewCommandResponseIF- Returns:
- The value of the
viewattribute
-
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
public final ModalViewCommandResponse withResponseMetadata(Optional<? extends ResponseMetadata> optional) 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
-
withView
Copy the current immutable object by setting a value for theviewattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for view- Returns:
- A modified copy or the
thisobject
-
equals
This instance is equal to all instances ofModalViewCommandResponsethat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:ok,responseMetadata,view. -
toString
Prints the immutable valueModalViewCommandResponsewith attribute values. -
copyOf
Creates an immutable copy of aModalViewCommandResponseIFvalue. 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 ModalViewCommandResponse instance
-
builder
Creates a builder forModalViewCommandResponse.ModalViewCommandResponse.builder() .setOk(boolean) // requiredok.setResponseMetadata(Optional<ResponseMetadata>) // optionalresponseMetadata.setView(com.hubspot.slack.client.models.response.views.ModalViewResponse) // requiredview.build();- Returns:
- A new ModalViewCommandResponse builder
-