All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.11.0 - 2024-12-09
- Ktor integration to automatically validate received payloads. (#43)
- Public constructors for
ConstraintViolationSet
andConstraintViolation
.
0.10.0 - 2024-09-24
- kotlinx-datetime integration to validate multiplatform date and time. (#42)
- New
akkurate-test
artifact to test custom constraints. - New constraints to validate types of the kotlin.time package.
- Add a
or equal to zero
suffix to the default message forisNegativeOrZero
andisPositiveOrZero
constraints.
0.9.1 - 2024-09-12
- Fix name clashes when generating validatable accessors from the common code.
0.9.0 - 2024-08-30
- The
ConstraintViolationSet.equals
method is now symmetric and matches what's in the specification.
- Support Kotlin Multiplatform and all its targets (#33)
- The default violation message of the
isInstanceOf
andisNotInstanceOf
constraints now display the simple name of the type, instead of the qualified one. - The
Validate
annotation has been moved from theakkurate-ksp-plugin
artifact to theakkurate-core
one.
- Support transforming a value before validating it (#26)
- New constraint to ensure a collection doesn't contain duplicated elements (#28)
- New constraints to check if a value is an instance of some type (#27)
- New accessors to easily validate a specific index of a collection (#29)
- Scope control has been implemented for Akkurate's DSL (#25)
- Accessors for mutable properties are no longer improperly cast. (#22)
0.6.0 - 2023-12-12
- Arrow integration to convert Akkurate validation results to typed errors (#20)
0.5.0 - 2023-11-28
- New configuration option to fail on the first constraint violation (#19)
0.4.0 - 2023-10-30
- The
Configuration
class is now instantiated through a builder DSL (#13) - Mark the API of the KSP plugin as experimental (#13)
- Remove unused
MutablePath
type alias
- Support iterating over nullable iterables, like
Validatable<Iterable<*>?>
. (#16) - Add constraints to validate additional JVM types:
LocalDate
,Duration
andPeriod
(#7)
0.3.0 - 2023-10-16
- Validation accessors are generated only for public properties. (#11 #15)
- Accessors are now generated for the properties of the implemented interface when possible, not for the implementation. (#11)
- Provide built-in accessors for
kotlin
andkotlin.collections
packages (#11) - Support generating accessors for generic types (#10)
- A KDoc is provided for each validatable accessor (#6)
- Validatable accessors are no longer generated for extension properties
- Skip the generation of accessors in the
kotlin
package, avoiding compilation failures.
- Propagate the
@Validate
annotation to the nested classes (#11)
0.2.0 - 2023-09-26
- Change visibility of
ValidateAnnotationProcessor.validatableOfFunction
to private. (#12) - Change visibility of
ValidateAnnotationProcessor.validatableClass
to private. (#12)
- Add new constraints (#3):
CharSequence
hasLengthEqualTo
/hasLengthNotEqualTo
isBlank
/isNotBlank
isMatching
/isNotMatching
kotlin.collections
hasSizeNotEqualTo
isEmpty
/isNotEmpty
isContaining
/isNotContaining
Map
isContainingKey
/isNotContainingKey
isContainingValue
/isNotContainingValue
- Enable Explicit API Mode for the KSP plugin. (#12)
0.1.1 - 2023-09-21
- The target version of generated JVM bytecode is now 1.8 instead of 11. (#5)
- Suppress the warning about useless casts in generated accessors. (#8)
0.1.0 - 2023-09-12
First release