Package-level declarations

Types

Link copied to clipboard

Represents a condition with a defined boundary for semantic version constraints. This interface extends the behavior of OperatorCondition by adding comparability.

Link copied to clipboard
interface Condition

Represents a condition that can evaluate whether a given Version satisfies certain criteria.

Link copied to clipboard

Interface that provides a framework for formatting constraints represented by a list of conditions.

Link copied to clipboard
interface ConditionParser

Interface for parsing conditional expressions into Condition instances.

Link copied to clipboard
@Serializable(with = ConstraintSerializer::class)
class Constraint

This class describes a semantic version constraint. It provides ability to verify whether a version satisfies one or more conditions within a constraint.

Link copied to clipboard

Constraint throws this exception when the constraint parsing fails due to an invalid format.

Link copied to clipboard
object ConstraintSerializer : KSerializer<Constraint>

Built-in kotlinx.serialization serializer that encodes and decodes a Constraint as its string representation.

Link copied to clipboard

The default formatter used to format Constraint instances.

Link copied to clipboard

Represents a condition that checks for equality or inequality of a version using the specified equality operator.

Link copied to clipboard

Defines equality comparison operators that can be used to evaluate version constraints.

Link copied to clipboard

Represents a condition that checks if a version is greater than or equal to a specified version.

Link copied to clipboard

Enum representing lower-bound comparison operators used in version constraints.

Link copied to clipboard
object MavenConstraintSerializer : KSerializer<Constraint>

Built-in kotlinx.serialization serializer that encodes and decodes a Constraint in Maven-style string representation.

Link copied to clipboard

A formatter for Maven-style version constraints. This class transforms conditions into a string representation that adheres to the Maven format for version ranges.

Link copied to clipboard

A parser that converts Maven-style version range expressions into Condition objects.

Link copied to clipboard
interface Negatable<T : Condition>

Represents an entity that can be negated to form its logical opposite.

Link copied to clipboard

Represents a non-intersecting range condition where bounds are pointing in opposite directions.

Link copied to clipboard
interface Operator

Represents a comparison operator for version constraints.

Link copied to clipboard

Represents a condition that compares a specific semantic version against a constraint defined by an operator and a target version.

Link copied to clipboard

An interface extending ConditionParser, designed for parsing and preprocessing constraints in conditional expressions.

Link copied to clipboard

Represents a composite condition that evaluates whether a Version falls within a specific range defined by a LowerBoundCondition and an UpperBoundCondition.

Link copied to clipboard

Represents a condition that checks if a version is less than or equal to a specified version.

Link copied to clipboard

Represents the upper-bound comparison operator for version constraints.

Functions

Link copied to clipboard
infix fun Constraint.satisfiedBy(version: Version): Boolean

Determines whether the Constraint is satisfied by a Version.

Link copied to clipboard

Determines whether the Constraint is satisfied by each Version in a collection.

Link copied to clipboard

Determines whether the Constraint is satisfied by at least one Version in a collection.

Link copied to clipboard

Parses the string as a Constraint and returns the result or throws a ConstraintFormatException if the string is not a valid representation of a constraint.

Link copied to clipboard

Parses the string as a Constraint and returns the result or null if the string is not a valid representation of a constraint.

Link copied to clipboard

Parses a maven range string as a Constraint and returns the result or throws a ConstraintFormatException if the string is not a valid representation of a constraint.

Link copied to clipboard

Parses a maven range string as a Constraint and returns the result or null if the string is not a valid representation of a constraint.

Link copied to clipboard

Converts the current Constraint instance into a Maven-compatible string representation.