Description
Implement PositiveInt as a ValueObject in the primitives module.
Spec: i64 > 0
Implementation checklist
Implementation detail
Input / Output
|
Type |
Alias |
| Input |
i64 |
PositiveIntInput |
| Output |
i64 |
PositiveIntOutput |
Normalization
None.
Validation
- Must be strictly positive: value > 0. Zero is rejected.
Extra methods
None beyond the trait.
References
Description
Implement
PositiveIntas aValueObjectin theprimitivesmodule.Spec:
i64 > 0Implementation checklist
src/primitives/positiveint.rsValueObjecttrait#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]src/primitives/mod.rsandprelude# ExampleblockROADMAP.mdfrom ⬜ to ✅Implementation detail
Input / Output
i64PositiveIntInputi64PositiveIntOutputNormalization
None.
Validation
Extra methods
None beyond the trait.
References