InternalFunctionsTrait
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait
pub trait InternalFunctionsTrait<TContractState, +HasComponent<TContractState>>
Trait functions
initializer
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::initializer
fn initializer(ref self: ComponentState<TContractState>)
allocate_node_index
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::allocate_node_index
fn allocate_node_index(ref self: ComponentState<TContractState>) -> u64
free_node_index
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::free_node_index
fn free_node_index(ref self: ComponentState<TContractState>, index: u64)
read_node
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::read_node
fn read_node(self: @ComponentState<TContractState>, index: u64) -> CMTNodeStorage
write_node
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::write_node
fn write_node(ref self: ComponentState<TContractState>, index: u64, node: CMTNodeStorage)
update_node_hash
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::update_node_hash
fn update_node_hash(ref self: ComponentState<TContractState>, index: u64) -> felt252
insert_node
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::insert_node
fn insert_node(
ref self: ComponentState<TContractState>,
current_index: u64,
new_index: u64,
new_key: felt252,
new_priority: felt252,
) -> u64
restore_heap_property
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::restore_heap_property
fn restore_heap_property(
ref self: ComponentState<TContractState>, node_index: u64, check_left: bool,
) -> u64
right_rotate
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::right_rotate
fn right_rotate(ref self: ComponentState<TContractState>, node_index: u64) -> u64
left_rotate
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::left_rotate
fn left_rotate(ref self: ComponentState<TContractState>, node_index: u64) -> u64
search_node
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::search_node
fn search_node(self: @ComponentState<TContractState>, node_index: u64, key: felt252) -> bool
remove_node
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::remove_node
fn remove_node(
ref self: ComponentState<TContractState>, node_index: u64, key: felt252,
) -> (u64, bool)
rotate_to_leaf_and_remove
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::rotate_to_leaf_and_remove
fn rotate_to_leaf_and_remove(
ref self: ComponentState<TContractState>, node_index: u64, key: felt252,
) -> u64
generate_proof_internal
Fully qualified path: cartesian_merkle_tree::components::cmtree_component::cmtree_component::InternalFunctionsTrait::generate_proof_internal
fn generate_proof_internal(
self: @ComponentState<TContractState>,
node_index: u64,
key: felt252,
ref siblings: Array<felt252>,
ref direction_bits: felt252,
ref siblings_count: u32,
) -> (bool, felt252)