#rdf #solid #web #decentralization #server

gdp_rs

A library for implementing Ghosts-of-departed-proofs pattern in rust

5 releases

0.1.1 Sep 28, 2023
0.1.0 Sep 28, 2023
0.0.3 Nov 28, 2022
0.0.2 Nov 28, 2022
0.0.1 Nov 18, 2022

#25 in #solid

Download history 72/week @ 2024-12-09 26/week @ 2024-12-16 18/week @ 2024-12-23 10/week @ 2024-12-30 16/week @ 2025-01-06 8/week @ 2025-01-13 21/week @ 2025-01-20 31/week @ 2025-02-10 25/week @ 2025-02-17 11/week @ 2025-02-24 4/week @ 2025-03-03 40/week @ 2025-03-10 21/week @ 2025-03-17 4/week @ 2025-03-24

70 downloads per month
Used in 19 crates (12 directly)

MIT/Apache

33KB
879 lines

gdp_rs

This crate provides utilities to employ Ghosts-of-Departed-Proofs pattern in rust projects. This enables type drive development following Parse, don't validate principle.

The idea is that, instead of checking or validating the values of a Type for satisfying certain properties, one create a wrapper refined new type that can only constructed from the values satisfying desired predicates. Thus, one can centralize the validation mechanism, and use typesystem to enforce right invariant.

This crate provides a type Proven, which is generic over the predicate type. It can be instantiated only from valid subject values of a type, satisfying the predicate function.

The crate also provides combinatrics over multiple predicates, so that one compose a compound predicate type from list of other predicate type.

License: MIT OR Apache-2.0

Dependencies

~0.4–1MB
~20K SLoC