Skip to content

Releases: eav-eav-eav/tomlkt

tomlkt 0.6.1

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 27 Jul 11:24
e04bb7f

Change

  • Fixed a bug when parsing nested array of tables with the same key. (#86 from @Stream29)

tomlkt 0.6.0 (IMPORTANT)

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 25 Jan 06:57
64b3abd

Change

  • Changed root domain to dev.eav
  • Fixed a bug when parsing Long value where Long.MIN_VALUE throws exception. (#81)

tomlkt 0.5.0

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 08 Jul 15:14
0b2f8a7

Change

  • Toml.decodeFromString now works even when no key is specified. (#72)
  • Upgraded Kotlin to 2.2.0, kotlinx.serialization to 1.9.0, kotlinx.datetime to 0.7.0. (#77)

tomlkt 0.4.0

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 16 Jun 12:09
2fe147e

Change

  • Removed all the deprecated declarations.
  • Upgraded Kotlin to 2.0.0, kotlinx.serialization to 1.7.0, kotlinx.datetime to 0.6.0. (#66, #67)

tomlkt 0.3.7

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 16 Oct 16:10
ddeaf63

New

  • Add extensions to (TomlArray|TomlTable).get for easier access to entries.
  • Add TomlArrayBuilder and TomlTableBuilder for dynamic construction.
    • Add buildTomlArray and buildTomlTable as shorthand.
    • Add extensions to (TomlArrayBuilder|TomlTableBuilder).element for easier population.

Change

  • Now a super-table can be defined after a sub-table without causing ConflictEntryException.
  • Fix a bug in TomlElementEncoder where TomlElement family does not bypass the encoding process with encodeTomlElement.
  • Major performance improvement in TomlElementParser (originally TomlFileParser).

tomlkt 0.3.6

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 14 Oct 11:54
9689e08

New

  • Add (TomlArray|TomlTable).annotations for storing metadata (@SerialInfo annotations).
    • Add (TomlArray|TomlTable).(annotated|annotatedAll) extensions for adding metadata manually.
  • Add linuxArm64 target. (#56)

Change

  • Refactor encoding process.
    • Now TomlElementEncoder will transfer @SerialInfo annotations from properties to (TomlArray|TomlTable).annotations.
    • Now all the tables and array of tables will be encoded as non-inline eagerly (as long as it is not annotated with @TomlInline).
    • Now NullInArrayOfTableException and EmptyArrayOfTableInMapException don't exist anymore.
    • Fix a bug in table-like encoding when an empty array of table is after a table-like.
val table = TomlTable(
    "string" to TomlArray(
        TomlTable(
            1 to true
        ),
        TomlTable(
            'c' to Float.POSITIVE_INFINITY
        )
    ),
    "key" to TomlTable(
        false to 114514L
    ),
    1.0 to null
)

Toml.encodeToString(table)
/*
"1.0" = null

[key]
false = 114514

[[string]]
1 = true

[[string]]
c = inf
 */

tomlkt 0.3.5

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 05 Oct 10:51
fbaa95e

New

  • Add TomlInteger.group for grouping digits.
  • Add TomlConfigBuilder.uppercaseInteger for uppercasing letters in integers.
  • Enhance TomlWriter with more functions for better control over encoding.
    • Add AbstractTomlWriter as basic implementation of TomlWriter.

tomlkt 0.3.4

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 02 Oct 12:50
2c36dde

Change

  • Fix a bug in \r decoding. (#51)

tomlkt 0.3.3

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 29 Sep 13:12
68df7fd

New

  • Add TomlReader for sequential parsing.
    • Add TomlStringReader, TomlNativeReader (JVM) as implementation.
    • Add Toml.parseToTomlTable(TomlReader), Toml.decodeFromReader, Toml.decodeFromNativeReader (JVM) for convenience.
  • Add TomlNativeWriter (JVM) and Toml.encodeToNativeWriter (JVM) for better JVM integration.
  • Add TomlContentPolymorphicSerializer for polymorphic serialization without class discriminator.
  • Add TomlConfig.explicitNulls so that during encoding any entry with null value is ignored and during decoding any nullable property without default value is set to null automatically.
  • Add TomlEncoder.toml, TomlDecoder.toml for referring to the Toml instance.
  • Add contracts in various type checks.

Change

  • Fix a bug in TomlLiteral to Double conversion.

tomlkt 0.3.2

Choose a tag to compare

@eav-eav-eav eav-eav-eav released this 14 Sep 05:22
89a7c5c

New

  • Add official JSON format like polymorphism serialization.
    • Add TomlConfigBuilder.classDiscriminator and @TomlClassDiscriminator for changing the key of the class discriminator.
  • Add support for accessing values of a TomlArray by index in TomlTable.get(keys).
  • Add a Toml.decodeFromString overload with keys parameter for only deserializing a certain part of a TOML file.
  • Add TomlArray(values) and TomlTable(entries) overloads to reduce the redundance when creating instances manually.

Change

  • Fix a bug in nested table encoding when the super-table is structured and the sub-table is unstructured.
  • Unify class and object serialization.
  • Major refactor in encoders and decoders.