miden_node_proto/domain/
mod.rs1pub mod account;
2pub mod block;
3pub mod digest;
4pub mod encryption;
5pub mod merkle;
6pub mod note;
7pub mod nullifier;
8pub mod proof_request;
9pub mod transaction;
10
11use miden_node_tracing::{RecordAttribute, Value};
12
13impl RecordAttribute for crate::generated::rpc::FinalityLevel {
14 const FIELD_NAMES: &'static [&'static str] = &["finality_level"];
15
16 fn record_attribute(&self) -> impl Value + '_ {
17 self.as_str_name()
18 }
19}
20
21pub fn convert<T, From, To>(from: T) -> impl Iterator<Item = To>
25where
26 T: IntoIterator<Item = From>,
27 From: Into<To>,
28{
29 from.into_iter().map(Into::into)
30}
31
32pub fn try_convert<T, E, From, To>(from: T) -> impl Iterator<Item = Result<To, E>>
33where
34 T: IntoIterator<Item = From>,
35 From: TryInto<To, Error = E>,
36{
37 from.into_iter().map(TryInto::try_into)
38}