Record Class TableStyleInfo

java.lang.Object
java.lang.Record
io.keikai.axyra.sheets.content.TableStyleInfo

public record TableStyleInfo(String styleName, boolean showFirstColumn, boolean showLastColumn, boolean showRowStripes, boolean showColumnStripes) extends Record
A table's style binding (ECMA-376 §18.5.1.20 tableStyleInfo): the built-in style name (e.g. "TableStyleMedium2", "TableStyleLight9", "TableStyleDark3") plus the four banding / emphasis toggles.
  • Constructor Summary

    Constructors
    Constructor
    Description
    TableStyleInfo(String styleName, boolean showFirstColumn, boolean showLastColumn, boolean showRowStripes, boolean showColumnStripes)
    Creates an instance of a TableStyleInfo record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    Excel's default for new tables: TableStyleMedium2, row stripes on.
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    of(String styleName)
    The default banding flags with a different built-in style name.
    boolean
    Returns the value of the showColumnStripes record component.
    boolean
    Returns the value of the showFirstColumn record component.
    boolean
    Returns the value of the showLastColumn record component.
    boolean
    Returns the value of the showRowStripes record component.
    Returns the value of the styleName record component.
    final String
    Returns a string representation of this record class.

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • TableStyleInfo

      public TableStyleInfo(String styleName, boolean showFirstColumn, boolean showLastColumn, boolean showRowStripes, boolean showColumnStripes)
      Creates an instance of a TableStyleInfo record class.
      Parameters:
      styleName - the value for the styleName record component
      showFirstColumn - the value for the showFirstColumn record component
      showLastColumn - the value for the showLastColumn record component
      showRowStripes - the value for the showRowStripes record component
      showColumnStripes - the value for the showColumnStripes record component
  • Method Details

    • defaults

      public static TableStyleInfo defaults()
      Excel's default for new tables: TableStyleMedium2, row stripes on.
    • of

      public static TableStyleInfo of(String styleName)
      The default banding flags with a different built-in style name.
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • styleName

      public String styleName()
      Returns the value of the styleName record component.
      Returns:
      the value of the styleName record component
    • showFirstColumn

      public boolean showFirstColumn()
      Returns the value of the showFirstColumn record component.
      Returns:
      the value of the showFirstColumn record component
    • showLastColumn

      public boolean showLastColumn()
      Returns the value of the showLastColumn record component.
      Returns:
      the value of the showLastColumn record component
    • showRowStripes

      public boolean showRowStripes()
      Returns the value of the showRowStripes record component.
      Returns:
      the value of the showRowStripes record component
    • showColumnStripes

      public boolean showColumnStripes()
      Returns the value of the showColumnStripes record component.
      Returns:
      the value of the showColumnStripes record component