9 releases (1 stable)
| 1.0.0 | Mar 31, 2020 |
|---|---|
| 1.0.0-rc.3 | Mar 25, 2020 |
| 1.0.0-rc.1 | Feb 7, 2020 |
| 0.13.0-rc.2 | Dec 4, 2019 |
| 0.10.0 | Dec 14, 2018 |
#1038 in #protobuf
247 downloads per month
Used in 17 crates
(15 directly)
74KB
1.5K
SLoC
Procedural macros for Exonum
This crate provides several procedural macros for Exonum core and Exonum services.
Overview of presented macros:
BinaryValue: derive macro forBinaryValuetrait of MerkleDB. Depending on codec, the implementation may useProtobufConverttrait as base (default), orserdetraits usingbincode.ObjectHash: derive macro forObjectHashtrait of MerkleDB. It can be used for any type that implementsBinaryValuetrait.FromAccess: derive macro forFromAccesstrait for schemas of MerkleDB indexes.ServiceDispatcher: derive macro for generating dispatching mechanisms of Rust Exonum services.ServiceFactory: derive macro for generating factory mechanisms of Rust Exonum services.exonum_interface: attribute macro for transforming trait into interface of Rust Exonum service.ExecutionFail: derive macro similar tofailure::Fail, implementingExecutionFailtrait for an enum.RequireArtifact: derive macro forRequireArtifacttrait.
Consult the crate docs for more details.
Usage
Include exonum-derive as a dependency in your Cargo.toml:
[dependencies]
exonum-derive = "1.0.0"
License
exonum-derive is licensed under the Apache License (Version 2.0).
See LICENSE for details.
Dependencies
~2MB
~52K SLoC