Class RichTextDateElement.Style
java.lang.Object
com.hubspot.slack.client.models.blocks.elements.richtextelements.RichTextDateElement.Style
- All Implemented Interfaces:
RichTextDateElementIF.StyleIF
- Enclosing class:
RichTextDateElement
@Generated(from="RichTextDateElementIF.StyleIF",
generator="Immutables")
@Immutable
public static final class RichTextDateElement.Style
extends Object
implements RichTextDateElementIF.StyleIF
Immutable implementation of
RichTextDateElementIF.StyleIF.
Use the builder to create immutable instances:
RichTextDateElement.Style.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forStyle.static RichTextDateElement.StylecopyOf(RichTextDateElementIF.StyleIF instance) Creates an immutable copy of aRichTextDateElementIF.StyleIFvalue.booleanThis instance is equal to all instances ofStylethat have equal attribute values.getBold()inthashCode()Computes a hash code from attributes:bold,italic,strike,highlight,clientHighlight,underline.toString()Prints the immutable valueStylewith attribute values.Copy the current immutable object by setting a present value for the optionalboldattribute.Copy the current immutable object by setting an optional value for theboldattribute.withClientHighlight(Boolean value) Copy the current immutable object by setting a present value for the optionalclientHighlightattribute.withClientHighlight(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for theclientHighlightattribute.withHighlight(Boolean value) Copy the current immutable object by setting a present value for the optionalhighlightattribute.withHighlight(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for thehighlightattribute.withItalic(Boolean value) Copy the current immutable object by setting a present value for the optionalitalicattribute.withItalic(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for theitalicattribute.withStrike(Boolean value) Copy the current immutable object by setting a present value for the optionalstrikeattribute.withStrike(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for thestrikeattribute.withUnderline(Boolean value) Copy the current immutable object by setting a present value for the optionalunderlineattribute.withUnderline(Optional<Boolean> optional) Copy the current immutable object by setting an optional value for theunderlineattribute.
-
Method Details
-
getBold
- Specified by:
getBoldin interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
boldattribute
-
getItalic
- Specified by:
getItalicin interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
italicattribute
-
getStrike
- Specified by:
getStrikein interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
strikeattribute
-
getHighlight
- Specified by:
getHighlightin interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
highlightattribute
-
getClientHighlight
- Specified by:
getClientHighlightin interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
clientHighlightattribute
-
getUnderline
- Specified by:
getUnderlinein interfaceRichTextDateElementIF.StyleIF- Returns:
- The value of the
underlineattribute
-
withBold
Copy the current immutable object by setting a present value for the optionalboldattribute.- Parameters:
value- The value for bold,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withBold
Copy the current immutable object by setting an optional value for theboldattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for bold- Returns:
- A modified copy or
thisif not changed
-
withItalic
Copy the current immutable object by setting a present value for the optionalitalicattribute.- Parameters:
value- The value for italic,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withItalic
Copy the current immutable object by setting an optional value for theitalicattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for italic- Returns:
- A modified copy or
thisif not changed
-
withStrike
Copy the current immutable object by setting a present value for the optionalstrikeattribute.- Parameters:
value- The value for strike,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withStrike
Copy the current immutable object by setting an optional value for thestrikeattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for strike- Returns:
- A modified copy or
thisif not changed
-
withHighlight
Copy the current immutable object by setting a present value for the optionalhighlightattribute.- Parameters:
value- The value for highlight,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withHighlight
Copy the current immutable object by setting an optional value for thehighlightattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for highlight- Returns:
- A modified copy or
thisif not changed
-
withClientHighlight
Copy the current immutable object by setting a present value for the optionalclientHighlightattribute.- Parameters:
value- The value for clientHighlight,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withClientHighlight
Copy the current immutable object by setting an optional value for theclientHighlightattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for clientHighlight- Returns:
- A modified copy or
thisif not changed
-
withUnderline
Copy the current immutable object by setting a present value for the optionalunderlineattribute.- Parameters:
value- The value for underline,nullis accepted asjava.util.Optional.empty()- Returns:
- A modified copy or
thisif not changed
-
withUnderline
Copy the current immutable object by setting an optional value for theunderlineattribute. An equality check is used on inner value to prevent copying of the same value by returningthis.- Parameters:
optional- An optional value for underline- Returns:
- A modified copy or
thisif not changed
-
equals
This instance is equal to all instances ofStylethat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:bold,italic,strike,highlight,clientHighlight,underline. -
toString
Prints the immutable valueStylewith attribute values. -
copyOf
Creates an immutable copy of aRichTextDateElementIF.StyleIFvalue. 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 Style instance
-
builder
Creates a builder forStyle.RichTextDateElement.Style.builder() .setBold(Optional<Boolean>) // optionalbold.setItalic(Optional<Boolean>) // optionalitalic.setStrike(Optional<Boolean>) // optionalstrike.setHighlight(Optional<Boolean>) // optionalhighlight.setClientHighlight(Optional<Boolean>) // optionalclientHighlight.setUnderline(Optional<Boolean>) // optionalunderline.build();- Returns:
- A new Style builder
-