Package-level declarations

Types

Link copied to clipboard
@Serializable
data class Attribute(val id: Identifier, val value: Pattern, val type: String = "Attribute")

An attribute - a named variant of a message or term.

Link copied to clipboard
@Serializable
data class CallArguments(val positional: List<InlineExpression> = emptyList(), val named: List<NamedArgument> = emptyList(), val type: String = "CallArguments")

Arguments passed to a function call or term reference.

Link copied to clipboard
@Serializable
data class DocComment(val description: String = "", val variables: List<VariableDoc> = emptyList())

A documentation comment associated with a message or term.

Link copied to clipboard
@Serializable
sealed class Entry

Represents a single top-level element in an FTL resource.

Link copied to clipboard
@Serializable
sealed class Expression

An expression in a pattern or placeable.

Link copied to clipboard
@Serializable
data class Identifier(val name: String, val type: String = "Identifier")

Represents an identifier (name) in Fluent.

Link copied to clipboard
@Serializable
sealed class InlineExpression

An inline expression - a simple value that can appear in patterns.

Link copied to clipboard
@Serializable
data class NamedArgument(val name: Identifier, val value: InlineExpression, val type: String = "NamedArgument")

A named argument (key-value pair) in a function call.

Link copied to clipboard
@Serializable
data class Pattern(val elements: List<PatternElement>, val type: String = "Pattern")

A pattern - the content of a message or term value.

Link copied to clipboard
@Serializable
sealed class PatternElement

An element within a Pattern.

Link copied to clipboard
@Serializable
data class Resource(val body: List<Entry>, val type: String = "Resource")

Root AST node representing a complete Fluent Translation List (FTL) resource.

Link copied to clipboard
@Serializable
data class VariableDoc(val name: String, val type: String = "", val description: String = "", val defaultValue: String = "")

Documentation for a single variable in a message or term.

Link copied to clipboard
@Serializable
data class Variant(val key: VariantKey, val value: Pattern, val default: Boolean, val type: String = "Variant")

A variant in a select expression.

Link copied to clipboard
@Serializable
sealed class VariantKey

The key for a variant in a select expression.