Trait clarity_repl::clarity::database::marf::ClarityBackingStore [−][src]
Required methods
fn put_all(&mut self, items: Vec<(String, String)>)
[src]
put K-V data into the committed datastore
fn get(&mut self, key: &str) -> Option<String>
[src]
fetch K-V out of the committed datastore
fn set_block_hash(&mut self, bhh: StacksBlockId) -> Result<StacksBlockId>
[src]
change the current MARF context to service reads from a different chain_tip used to implement time-shifted evaluation. returns the previous block header hash on success
fn get_block_at_height(&mut self, height: u32) -> Option<StacksBlockId>
[src]
fn get_current_block_height(&mut self) -> u32
[src]
this function returns the current block height, as viewed by this marfed-kv structure, i.e., it changes on time-shifted evaluation. the open_chain_tip functions always return data about the chain tip that is currently open for writing.
fn get_open_chain_tip_height(&mut self) -> u32
[src]
fn get_open_chain_tip(&mut self) -> StacksBlockId
[src]
fn insert_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
This function is used to obtain a committed contract hash, and the block header hash of the block in which the contract was initialized. This data is used to store contract metadata in the side store.
fn get_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>
Provided methods
fn has_entry(&mut self, key: &str) -> bool
[src]
fn make_contract_commitment(
&mut self,
contract_hash: Sha512Trunc256Sum
) -> String
[src]
&mut self,
contract_hash: Sha512Trunc256Sum
) -> String
The contract commitment is the hash of the contract, plus the block height in which the contract was initialized.
Implementors
impl ClarityBackingStore for Datastore
[src]
fn put_all(&mut self, items: Vec<(String, String)>)
[src]
fn get(&mut self, key: &str) -> Option<String>
[src]
fetch K-V out of the committed datastore
fn has_entry(&mut self, key: &str) -> bool
[src]
fn set_block_hash(&mut self, bhh: StacksBlockId) -> Result<StacksBlockId>
[src]
change the current MARF context to service reads from a different chain_tip used to implement time-shifted evaluation. returns the previous block header hash on success
fn get_block_at_height(&mut self, height: u32) -> Option<StacksBlockId>
[src]
fn get_current_block_height(&mut self) -> u32
[src]
this function returns the current block height, as viewed by this marfed-kv structure, i.e., it changes on time-shifted evaluation. the open_chain_tip functions always return data about the chain tip that is currently open for writing.
fn get_open_chain_tip_height(&mut self) -> u32
[src]
fn get_open_chain_tip(&mut self) -> StacksBlockId
[src]
fn make_contract_commitment(
&mut self,
contract_hash: Sha512Trunc256Sum
) -> String
[src]
&mut self,
contract_hash: Sha512Trunc256Sum
) -> String
The contract commitment is the hash of the contract, plus the block height in which the contract was initialized.
fn insert_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
fn get_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>
impl ClarityBackingStore for NullBackingStore
[src]
fn set_block_hash(&mut self, _bhh: StacksBlockId) -> Result<StacksBlockId>
[src]
fn get(&mut self, _key: &str) -> Option<String>
[src]
fn get_block_at_height(&mut self, _height: u32) -> Option<StacksBlockId>
[src]
fn get_open_chain_tip(&mut self) -> StacksBlockId
[src]
fn get_open_chain_tip_height(&mut self) -> u32
[src]
fn get_current_block_height(&mut self) -> u32
[src]
fn put_all(&mut self, _items: Vec<(String, String)>)
[src]
fn insert_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str,
value: &str
)
fn get_metadata(
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>
[src]
&mut self,
contract: &QualifiedContractIdentifier,
key: &str
) -> Result<Option<String>>