Class ElementalTextNode.Builder
- java.lang.Object
-
- com.courier.api.resources.send.types.ElementalTextNode.Builder
-
- All Implemented Interfaces:
ElementalTextNode._FinalStage,ElementalTextNode.AlignStage,ElementalTextNode.ContentStage
- Enclosing class:
- ElementalTextNode
public static final class ElementalTextNode.Builder extends java.lang.Object implements ElementalTextNode.ContentStage, ElementalTextNode.AlignStage, ElementalTextNode._FinalStage
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ElementalTextNode._FinalStagealign(TextAlign align)Text alignment.ElementalTextNode._FinalStagebold(java.lang.String bold)Apply bold to the textElementalTextNode._FinalStagebold(java.util.Optional<java.lang.String> bold)ElementalTextNodebuild()ElementalTextNode._FinalStagechannels(java.util.List<java.lang.String> channels)ElementalTextNode._FinalStagechannels(java.util.Optional<java.util.List<java.lang.String>> channels)ElementalTextNode._FinalStagecolor(java.lang.String color)Specifies the color of text.ElementalTextNode._FinalStagecolor(java.util.Optional<java.lang.String> color)ElementalTextNode.AlignStagecontent(java.lang.String content)The text content displayed in the notification.ElementalTextNode._FinalStageformat(java.lang.String format)ElementalTextNode._FinalStageformat(java.util.Optional<java.lang.String> format)ElementalTextNode.Builderfrom(ElementalTextNode other)ElementalTextNode._FinalStageif_(java.lang.String if_)ElementalTextNode._FinalStageif_(java.util.Optional<java.lang.String> if_)ElementalTextNode._FinalStageitalic(java.lang.String italic)Apply italics to the textElementalTextNode._FinalStageitalic(java.util.Optional<java.lang.String> italic)ElementalTextNode._FinalStagelocales(java.util.Map<java.lang.String,Locale> locales)Region specific content.ElementalTextNode._FinalStagelocales(java.util.Optional<java.util.Map<java.lang.String,Locale>> locales)ElementalTextNode._FinalStageloop(java.lang.String loop)ElementalTextNode._FinalStageloop(java.util.Optional<java.lang.String> loop)ElementalTextNode._FinalStageref(java.lang.String ref)ElementalTextNode._FinalStageref(java.util.Optional<java.lang.String> ref)ElementalTextNode._FinalStagestrikethrough(java.lang.String strikethrough)Apply a strike through the textElementalTextNode._FinalStagestrikethrough(java.util.Optional<java.lang.String> strikethrough)ElementalTextNode._FinalStagetextStyle(TextStyle textStyle)Allows the text to be rendered as a heading level.ElementalTextNode._FinalStagetextStyle(java.util.Optional<TextStyle> textStyle)ElementalTextNode._FinalStageunderline(java.lang.String underline)Apply an underline to the textElementalTextNode._FinalStageunderline(java.util.Optional<java.lang.String> underline)
-
-
-
Method Detail
-
from
public ElementalTextNode.Builder from(ElementalTextNode other)
- Specified by:
fromin interfaceElementalTextNode.ContentStage
-
content
public ElementalTextNode.AlignStage content(java.lang.String content)
The text content displayed in the notification. Either this field must be specified, or the elements field
- Specified by:
contentin interfaceElementalTextNode.ContentStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
align
public ElementalTextNode._FinalStage align(TextAlign align)
Text alignment.
- Specified by:
alignin interfaceElementalTextNode.AlignStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
format
public ElementalTextNode._FinalStage format(java.lang.String format)
- Specified by:
formatin interfaceElementalTextNode._FinalStage
-
format
public ElementalTextNode._FinalStage format(java.util.Optional<java.lang.String> format)
- Specified by:
formatin interfaceElementalTextNode._FinalStage
-
locales
public ElementalTextNode._FinalStage locales(java.util.Map<java.lang.String,Locale> locales)
Region specific content. See locales docs for more details.
- Specified by:
localesin interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
locales
public ElementalTextNode._FinalStage locales(java.util.Optional<java.util.Map<java.lang.String,Locale>> locales)
- Specified by:
localesin interfaceElementalTextNode._FinalStage
-
underline
public ElementalTextNode._FinalStage underline(java.lang.String underline)
Apply an underline to the text
- Specified by:
underlinein interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
underline
public ElementalTextNode._FinalStage underline(java.util.Optional<java.lang.String> underline)
- Specified by:
underlinein interfaceElementalTextNode._FinalStage
-
strikethrough
public ElementalTextNode._FinalStage strikethrough(java.lang.String strikethrough)
Apply a strike through the text
- Specified by:
strikethroughin interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
strikethrough
public ElementalTextNode._FinalStage strikethrough(java.util.Optional<java.lang.String> strikethrough)
- Specified by:
strikethroughin interfaceElementalTextNode._FinalStage
-
italic
public ElementalTextNode._FinalStage italic(java.lang.String italic)
Apply italics to the text
- Specified by:
italicin interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
italic
public ElementalTextNode._FinalStage italic(java.util.Optional<java.lang.String> italic)
- Specified by:
italicin interfaceElementalTextNode._FinalStage
-
bold
public ElementalTextNode._FinalStage bold(java.lang.String bold)
Apply bold to the text
- Specified by:
boldin interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
bold
public ElementalTextNode._FinalStage bold(java.util.Optional<java.lang.String> bold)
- Specified by:
boldin interfaceElementalTextNode._FinalStage
-
color
public ElementalTextNode._FinalStage color(java.lang.String color)
Specifies the color of text. Can be any valid css color value
- Specified by:
colorin interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
color
public ElementalTextNode._FinalStage color(java.util.Optional<java.lang.String> color)
- Specified by:
colorin interfaceElementalTextNode._FinalStage
-
textStyle
public ElementalTextNode._FinalStage textStyle(TextStyle textStyle)
Allows the text to be rendered as a heading level.
- Specified by:
textStylein interfaceElementalTextNode._FinalStage- Returns:
- Reference to
thisso that method calls can be chained together.
-
textStyle
public ElementalTextNode._FinalStage textStyle(java.util.Optional<TextStyle> textStyle)
- Specified by:
textStylein interfaceElementalTextNode._FinalStage
-
loop
public ElementalTextNode._FinalStage loop(java.lang.String loop)
- Specified by:
loopin interfaceElementalTextNode._FinalStage
-
loop
public ElementalTextNode._FinalStage loop(java.util.Optional<java.lang.String> loop)
- Specified by:
loopin interfaceElementalTextNode._FinalStage
-
if_
public ElementalTextNode._FinalStage if_(java.lang.String if_)
- Specified by:
if_in interfaceElementalTextNode._FinalStage
-
if_
public ElementalTextNode._FinalStage if_(java.util.Optional<java.lang.String> if_)
- Specified by:
if_in interfaceElementalTextNode._FinalStage
-
ref
public ElementalTextNode._FinalStage ref(java.lang.String ref)
- Specified by:
refin interfaceElementalTextNode._FinalStage
-
ref
public ElementalTextNode._FinalStage ref(java.util.Optional<java.lang.String> ref)
- Specified by:
refin interfaceElementalTextNode._FinalStage
-
channels
public ElementalTextNode._FinalStage channels(java.util.List<java.lang.String> channels)
- Specified by:
channelsin interfaceElementalTextNode._FinalStage
-
channels
public ElementalTextNode._FinalStage channels(java.util.Optional<java.util.List<java.lang.String>> channels)
- Specified by:
channelsin interfaceElementalTextNode._FinalStage
-
build
public ElementalTextNode build()
- Specified by:
buildin interfaceElementalTextNode._FinalStage
-
-