Class StreamStyle

java.lang.Object
io.keikai.axyra.sheets.io.StreamStyle

public final class StreamStyle extends Object
A cell style for StreamWorkbook — the small subset that covers report authoring: a number format plus bold / italic.

Deliberately narrower than CellStyle. The full style model resolves against a workbook's style table, which a streaming writer does not have; everything here can be decided the moment a cell is written.

A patch record (design conventions §16, shape 5a): start from defaults() and derive with with… copies. Instances are immutable and value-comparable, so registering the same style repeatedly costs one entry in the file.

  • Method Details

    • defaults

      public static StreamStyle defaults()
      The neutral style: General format, no emphasis.
    • withNumberFormat

      public StreamStyle withNumberFormat(String code)
      This style with an Excel number-format code, e.g. "#,##0.00" or "yyyy-mm-dd". Excel has no date type: a date cell is a serial number plus a date format — see StreamRow.setDate(int, java.time.LocalDate, int). Pass null for General.
    • withBold

      public StreamStyle withBold()
      This style, bold — the usual header row.
    • withBold

      public StreamStyle withBold(boolean value)
      This style with bold set explicitly.
    • withItalic

      public StreamStyle withItalic()
      This style, italic.
    • withItalic

      public StreamStyle withItalic(boolean value)
      This style with italic set explicitly.
    • numberFormat

      public String numberFormat()
      The Excel number-format code, or null for General.
    • bold

      public boolean bold()
    • italic

      public boolean italic()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object