Class DividerParagraph

java.lang.Object
io.github.somesourcecode.someguiapi.scene.lore.DividerParagraph
All Implemented Interfaces:
Paragraph

public class DividerParagraph extends Object implements Paragraph
A paragraph that acts as a divider.
Since:
2.0.0
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a new divider paragraph.
    DividerParagraph(int length)
    Constructs a new divider paragraph with the given length.
    DividerParagraph(int length, net.kyori.adventure.text.format.TextColor color)
    Constructs a new divider paragraph with the given length and color.
    DividerParagraph(int length, net.kyori.adventure.text.format.TextColor color, boolean bold)
    Constructs a new divider paragraph with the given length, color and boldness.
  • Method Summary

    Modifier and Type
    Method
    Description
    net.kyori.adventure.text.format.TextColor
    Returns the color of the divider.
    int
    Returns the length of the divider.
    List<net.kyori.adventure.text.Component>
    Returns a list representing the lines of the paragraph.
    boolean
    Returns whether the divider is bold.
    setBold(boolean bold)
    Sets whether the divider is bold.
    setColor(net.kyori.adventure.text.format.TextColor color)
    Sets the color of the divider.
    setLength(int length)
    Sets the length of the divider.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DividerParagraph

      public DividerParagraph()
      Constructs a new divider paragraph.
      Since:
      2.0.0
    • DividerParagraph

      public DividerParagraph(int length)
      Constructs a new divider paragraph with the given length.
      Parameters:
      length - the length of the divider
      Since:
      2.0.0
    • DividerParagraph

      public DividerParagraph(int length, net.kyori.adventure.text.format.TextColor color)
      Constructs a new divider paragraph with the given length and color.
      Parameters:
      length - the length of the divider
      color - the color of the divider
      Since:
      2.0.0
    • DividerParagraph

      public DividerParagraph(int length, net.kyori.adventure.text.format.TextColor color, boolean bold)
      Constructs a new divider paragraph with the given length, color and boldness.
      Parameters:
      length - the length of the divider
      color - the color of the divider
      bold - whether the divider is bold
      Since:
      2.0.0
  • Method Details

    • getLength

      public int getLength()
      Returns the length of the divider.
      Returns:
      the length of the divider
      Since:
      2.0.0
    • setLength

      public DividerParagraph setLength(int length)
      Sets the length of the divider.
      Parameters:
      length - the length of the divider
      Returns:
      the paragraph for method chaining
      Since:
      2.0.0
    • getColor

      public net.kyori.adventure.text.format.TextColor getColor()
      Returns the color of the divider.
      Returns:
      the color of the divider
      Since:
      2.0.0
    • setColor

      public DividerParagraph setColor(net.kyori.adventure.text.format.TextColor color)
      Sets the color of the divider.
      Parameters:
      color - the color of the divider
      Returns:
      the paragraph for method chaining
      Since:
      2.0.0
    • isBold

      public boolean isBold()
      Returns whether the divider is bold.
      Returns:
      whether the divider is bold
      Since:
      2.0.0
    • setBold

      public DividerParagraph setBold(boolean bold)
      Sets whether the divider is bold.
      Parameters:
      bold - whether the divider is bold
      Returns:
      the paragraph for method chaining
      Since:
      2.0.0
    • getLines

      public List<net.kyori.adventure.text.Component> getLines()
      Description copied from interface: Paragraph
      Returns a list representing the lines of the paragraph.
      Specified by:
      getLines in interface Paragraph
      Returns:
      the lines of the paragraph