MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / read_loss_note

Method read_loss_note

atomic-core/src/operation/codec.rs:1325–1339  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

1323 }
1324
1325 fn read_loss_note(&mut self) -> Result<OperationLossNote, OperationCodecError> {
1326 let code = self.read_string("loss-note code")?;
1327 let message = self.read_string("loss-note message")?;
1328 let count = self.read_count("loss-note evidence")?;
1329 let mut evidence = Vec::with_capacity(count);
1330 for _ in 0..count {
1331 evidence.push(self.read_hash()?);
1332 }
1333 ensure_strictly_sorted(&evidence, "loss-note evidence")?;
1334 Ok(OperationLossNote {
1335 code,
1336 message,
1337 evidence,
1338 })
1339 }
1340
1341 fn read_effect_plan(&mut self) -> Result<EffectPlan, OperationCodecError> {
1342 Ok(EffectPlan {

Callers 1

decode_operationFunction · 0.80

Calls 5

ensure_strictly_sortedFunction · 0.85
read_countMethod · 0.80
read_hashMethod · 0.80
read_stringMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected