Class Icon
java.lang.Object
com.hubspot.slack.client.methods.params.chat.workobject.entity.Icon
- All Implemented Interfaces:
IconIF
@Generated(from="IconIF",
generator="Immutables")
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class Icon
extends Object
implements IconIF
Immutable implementation of
IconIF.
Use the builder to create immutable instances:
Icon.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic Icon.Builderbuilder()Creates a builder forIcon.static IconCreates an immutable copy of aIconIFvalue.booleanThis instance is equal to all instances ofIconthat have equal attribute values.getUrl()inthashCode()Computes a hash code from attributes:url,altText.toString()Prints the immutable valueIconwith attribute values.final IconwithAltText(String value) Copy the current immutable object by setting a value for thealtTextattribute.final IconCopy the current immutable object by setting a value for theurlattribute.
-
Method Details
-
getUrl
-
getAltText
- Specified by:
getAltTextin interfaceIconIF- Returns:
- The value of the
altTextattribute
-
withUrl
Copy the current immutable object by setting a value for theurlattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for url- Returns:
- A modified copy or the
thisobject
-
withAltText
Copy the current immutable object by setting a value for thealtTextattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for altText- Returns:
- A modified copy or the
thisobject
-
equals
This instance is equal to all instances ofIconthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:url,altText. -
toString
Prints the immutable valueIconwith attribute values. -
copyOf
Creates an immutable copy of aIconIFvalue. 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 Icon instance
-
builder
Creates a builder forIcon.Icon.builder() .setUrl(String) // requiredurl.setAltText(String) // requiredaltText.build();- Returns:
- A new Icon builder
-