This document records API-visible changes of the library.
Note that what you see below is not "Common Changelog".
0.1.0-alpha.6 - 2025-10-28
- Added a check in
ObjectSchemaBuilderwhich will throw an exception when trying to specify a property with its type different from the one specified in the type argument.- This is not a breaking change because this is a guard against the misuse of the API, that can cause failure in decoding.
- Fixed the issue where object schema always return missing property error results with
property.Nameas property name.
0.1.0-alpha.5 - 2025-10-25
- Added inverse operator for
DataResultthat determines whether the result indicates failure. - Added implicit conversion operator for the following conversions:
OpResulttoDataResultDataResultwith arbitrary type toDataResult<object>
- Added
Resultsstatic class which contains shared instances and factory methods for common results of operation. - Added extension methods for encoders, decoders and schemas that accepts
DataResultas input and will return the error if there is any.
- Changed how value presence and absence state in
DataResultworks.- Now whether the value of a result is present is determined by the
HasValueproperty. - Added new constructor
DataResult(bool, TValue)that indicates whether the value is present and specifies the value. - Added new constructor
DataResult(string)that indicates an error state. DataResult(TValue, string)is now deprecated.- For callers, this only affects users using manual
Result == nullcheck;RequireNonEmptyhas been updated to adapt to this change.
- Now whether the value of a result is present is determined by the
- Deprecated factory methods in
OpResultandDataResultin favour ofResultsclass. - Deprecated
CausedBy(OpResult)inDataResultin favour of the implicit conversion. - Deprecated
Success(TValue)inDataResultin favour of the implicit conversion.
0.1.0-alpha.4 - 2025-10-17
- Breaking: Added
EnumerateObjectmethod toIReadOnlyObjectLike. (#3)
- Improved the error message returned by
OneOfValueSchemain cases where none of the schemas were successful. (#2)
0.1.0-alpha.3 - 2025-10-16
- Added a value schema for encoding and decoding
Guidin a string format. - Added a schema for encoding a decoding collections.
- Breaking: Changed
OneOfValueSchemato acceptIValueSchema<TValue, TElement>instead of the classValueSchema<TValue, TElement>.
0.1.0-alpha.2 - 2025-10-14
- Added a strongly typed schema interface.
- Added a value schema for
Uri. - Added support for optional value and reference type properties in
ObjectSchema. - Added support for constants in
ObjectSchema. - Added support for using a value predicate to filter properties not to encode.
- Added
RequireNonEmptyand a few other utility methods toDataResult. - Added
OpResultthat represents an operational result that does not contain a value.
- Breaking: Moved most property addition helper methods for the builder to extensions.
- Breaking:
ObjectSchemais now immutable. - Breaking: Element types can now be named. Due to this,
elementNameparameter is added to theIValueEncoderinterface. - Breaking:
Encodemethod in schemas now returnDataResult. ObjectSchemawill now throw an exception for attempting to decode on a read-only value type. (#1)- This is supported and would cause the resulting structure to be effectively
defaultanyway.
- This is supported and would cause the resulting structure to be effectively
Initial release.