Package io.keikai.axyra.sheets


package io.keikai.axyra.sheets
Public Java API for the Axyra Sheets engine.

Entry points: Workbook (create, open, save, render), Sheet, Range (bulk reads and writes) and Cell. The subpackages hold the option, style and content types these take and return:

All classes in this package are part of the public API and follow SemVer compatibility guarantees. Anything under io.keikai.axyra.sheets.internal is implementation detail and may change at any time.

Naming conventions

The API uses record-style accessors, not JavaBean getX():

  • Property read: the bare property name — sheet.name(), font.bold(). Stored boolean properties are bare too (style.bold(), validation.allowBlank()).
  • Derived predicates and state queries use isX() / hasX() — color.isRgb(), sheet.isProtected(), sheet.isRowHidden(int). The distinction: bare names mirror a stored field; isX answers a question that is computed or takes arguments.
  • Mutation: void setX(...) — setters do not chain.
  • Coordinates are 0-based, always ordered (row, col). A1-style references go through A1.
  • Collections are returned as java.util.List snapshots; mutating the returned list does not affect the workbook.

Thread safety

A Workbook and every object obtained from it (sheets, ranges, cells, views) may be used by one thread at a time. Different Workbook instances run in parallel on different threads; a long-running export on one workbook does not delay calls on another.

If two threads call into the same workbook at the same time, the engine refuses the second call: it throws AxyraException with the message "workbook is already in use". It does not wait. This refusal protects the engine's memory; it is not a lock to rely on, because the Java side keeps per-workbook state that is not synchronized. A cross-workbook call such as Workbook.copySheetFrom uses both workbooks and is refused the same way when either is busy. Synchronize externally when several threads share one workbook. Methods that make several engine calls, and read-modify-write sequences, are not atomic.

A user-defined function (Workbook.registerFunction) runs inside the recalculation of its workbook. A call from the function back into that workbook fails the same way.

The license state (License) is shared by every workbook in the process and is safe to read and set from any thread.

Exceptions

Some engine checks surface as AxyraException rather than IndexOutOfBoundsException; each method's @throws names the exception it throws.