Query the contents of a CID from the IPLD store.
(&self, cid: &Cid, height: FvmQueryHeight)
| 32 | pub trait QueryClient: Sync { |
| 33 | /// Query the contents of a CID from the IPLD store. |
| 34 | async fn ipld(&self, cid: &Cid, height: FvmQueryHeight) -> anyhow::Result<Option<Vec<u8>>> { |
| 35 | let res = self |
| 36 | .perform(FvmQuery::Ipld(*cid), height) |
| 37 | .await |
| 38 | .context("ipld query failed")?; |
| 39 | extract_opt(res, |res| Ok(res.value)) |
| 40 | } |
| 41 | |
| 42 | /// Query the the state of an actor. |
| 43 | async fn actor_state( |