toml API GitHub

toml

toml is a TOML 1.1 parser and writer for Java 21 or later, with no dependency besides gaia-core. Every class is documented in the API documentation.

Artifacts

Artifact Module What it does
toml be.imgn.toml Parses, writes and binds documents
toml-processor be.imgn.toml.processor Generates the code that binds documents to records

Setting up

<dependency>
  <groupId>be.imgn.toml</groupId>
  <artifactId>toml</artifactId>
  <version>${toml.version}</version>
</dependency>

On the module path, require the module: requires be.imgn.toml;. It requires be.imgn.gaia.core transitively, as gaia's sources and sinks are part of its API.

Nulls

Every package of toml is annotated with JSpecify's @NullMarked: a parameter or a return value is never null unless it is annotated @Nullable. A method given null where it doesn't accept it throws NullPointerException, naming the parameter.