Interface UncheckedMapProof

All Known Implementing Classes:
UncheckedFlatMapProof

public interface UncheckedMapProof
An unchecked map proof. It's used to get a checked map proof. Example usage:

 byte[] key = "The key for which I want a proved value".getBytes();
 HashCode expectedIndexHash = // get a known index hash from block proof //
 UncheckedMapProof proof = requestProofForKey(key);
 // Convert to checked
 CheckedMapProof checkedProof = proof.check();
 // Check the index hash
 if (checkedProof.getIndexHash().equals(expectedIndexHash)) {
   // Get and use the value(s)
   byte[] value = checked.get(key);
 }
 
  • Method Summary

    Modifier and Type Method Description
    CheckedMapProof check()
    Checks that a proof has either correct or incorrect structure and returns a CheckedMapProof.
  • Method Details

    • check

      Checks that a proof has either correct or incorrect structure and returns a CheckedMapProof.