129 {
132 ("id", arg.id.str())
133 ("number", arg.number )
134 ("previous_id", arg.previous_id.str())
135 ("status", irreversible ? "irreversible" : "pending" )
136 ("timestamp", to_iso8601_datetime(arg.timestamp))
137 ("producer", arg.producer.to_string());}, trace);
138 if (std::holds_alternative<block_trace_v0> (trace)){
139 auto& block_trace = std::get<block_trace_v0>(trace);
141 (std::move(common_mvo))
142 ("transactions", process_transactions<transaction_trace_v0>(block_trace.transactions, data_handler, yield ));
143 }else if(std::holds_alternative<block_trace_v1>(trace)){
144 auto& block_trace = std::get<block_trace_v1>(trace);
146 (std::move(common_mvo))
147 ("transaction_mroot", block_trace.transaction_mroot)
148 ("action_mroot", block_trace.action_mroot)
149 ("schedule_version", block_trace.schedule_version)
150 ("transactions", process_transactions<transaction_trace_v1>( block_trace.transactions_v1, data_handler, yield )) ;
151 }else if(std::holds_alternative<block_trace_v2>(trace)){
152 auto& block_trace = std::get<block_trace_v2>(trace);
153 auto transactions = std::visit([&](auto&& arg){
154 return process_transactions(arg, data_handler, yield);
155 }, block_trace.transactions);
157 (std::move(common_mvo))
158 ("transaction_mroot", block_trace.transaction_mroot)
159 ("action_mroot", block_trace.action_mroot)
160 ("schedule_version", block_trace.schedule_version)
161 ("transactions", transactions) ;
162 }else{
164 }
165 }
An order-preserving dictionary of variants.