Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/SaitoTech/saito-rust
/ functions
Functions
495 in github.com/SaitoTech/saito-rust
⨍
Functions
495
◇
Types & classes
53
↓ 4 callers
Method
set_is_connected_or_connecting
this setter also will reset the appropriate flags on the peer if the peer becomes disconnected. Once disconnected, we want to also redo the handshake
src/peer.rs:218
↓ 4 callers
Method
set_previous_block_hash
(&mut self, previous_block_hash: SaitoHash)
src/block.rs:412
↓ 4 callers
Method
set_signature
(&mut self, sig: SaitoSignature)
src/transaction.rs:529
↓ 3 callers
Function
bit_pack
(top: u32, bottom: u32)
src/blockchain.rs:31
↓ 3 callers
Function
bit_unpack
(packed: u64)
src/blockchain.rs:34
↓ 3 callers
Method
delete
runs when block is purged for good or staking slip deleted
src/slip.rs:197
↓ 3 callers
Method
generate_blockchain
generate_blockchain can be used to add multiple chains of blocks that are not on the longest-chain, and thus will attempt to create transactions that
src/test_utilities/test_manager.rs:127
↓ 3 callers
Function
generate_keys
()
src/crypto.rs:48
↓ 3 callers
Method
get_blocks_data
(&self)
src/networking/message_types/send_blockchain_message.rs:52
↓ 3 callers
Function
get_configuration
()
src/configuration.rs:29
↓ 3 callers
Method
get_creator
(&self)
src/block.rs:273
↓ 3 callers
Method
get_latest_block_id
(&self)
src/networking/message_types/request_blockchain_message.rs:41
↓ 3 callers
Method
get_message_name_as_string
(&self)
src/networking/api_message.rs:52
↓ 3 callers
Method
get_random
(&self)
src/golden_ticket.rs:124
↓ 3 callers
Method
get_routing_work_for_publickey
(&self, publickey: SaitoPublicKey)
src/transaction.rs:345
↓ 3 callers
Method
get_total_fees
(&self)
src/transaction.rs:406
↓ 3 callers
Method
load
(&mut self)
src/wallet.rs:42
↓ 3 callers
Method
load_wallet
(&mut self, wallet_path: &str, password: Option<&str>)
src/wallet.rs:59
↓ 3 callers
Method
send_response_from_str
Helper function for sending basic OK results.
src/peer.rs:284
↓ 3 callers
Method
serialize_for_net
Serialize a Block for transport or disk. [len of transactions - 4 bytes - u32] [id - 8 bytes - u64] [timestamp - 8 bytes - u64] [previous_block_hash -
src/block.rs:607
↓ 3 callers
Method
set_block_type
(&mut self, block_type: BlockType)
src/block.rs:392
↓ 3 callers
Method
set_broadcast_channel_sender
(&mut self, bcs: broadcast::Sender<SaitoMessage>)
src/network.rs:91
↓ 3 callers
Method
set_creator
(&mut self, creator: SaitoPublicKey)
src/block.rs:418
↓ 3 callers
Method
set_from
(&mut self, from: SaitoPublicKey)
src/hop.rs:62
↓ 3 callers
Method
set_latest_block_hash
(&mut self, latest_block_hash: SaitoHash)
src/test_utilities/test_manager.rs:675
↓ 3 callers
Method
set_publickey
(&mut self, publickey: SaitoPublicKey)
src/slip.rs:170
↓ 3 callers
Method
set_sig
(&mut self, sig: SaitoSignature)
src/hop.rs:70
↓ 3 callers
Method
set_slip_ordinal
(&mut self, slip_ordinal: u8)
src/wallet.rs:512
↓ 3 callers
Method
set_to
(&mut self, to: SaitoPublicKey)
src/hop.rs:66
↓ 3 callers
Method
set_treasury
(&mut self, treasury: u64)
src/block.rs:436
↓ 3 callers
Method
sign
(&self, message_bytes: &[u8])
src/wallet.rs:288
↓ 3 callers
Function
sign_blob
(vbytes: &mut Vec<u8>, privatekey: SaitoPrivateKey)
src/crypto.rs:74
↓ 3 callers
Method
upgrade_block_to_block_type
if the block is not at the proper type, try to upgrade it to have the data that is necessary for blocks of that type if possible. if this is not possi
src/block.rs:473
↓ 3 callers
Method
validate
(&self, utxoset: &UtxoSet)
src/slip.rs:64
↓ 3 callers
Function
with_blockchain
inject blockchain lock
src/networking/filters.rs:77
↓ 2 callers
Method
add_block_failure
(&mut self)
src/blockchain.rs:443
↓ 2 callers
Method
add_block_on_hash
add block on parent hash
src/test_utilities/test_manager.rs:81
↓ 2 callers
Method
add_hop_to_path
( &mut self, wallet_lock: Arc<RwLock<Wallet>>, to_publickey: SaitoPublicKey, )
src/transaction.rs:91
↓ 2 callers
Method
add_pending
(&mut self, slip: Slip)
src/staking.rs:229
↓ 2 callers
Method
add_slip
(&mut self, block: &Block, transaction: &Transaction, slip: &Slip, lc: bool)
src/wallet.rs:148
↓ 2 callers
Method
challenger_pubkey
(&self)
src/networking/message_types/handshake_challenge.rs:100
↓ 2 callers
Method
create_golden_ticket_transaction
( &mut self, golden_ticket: GoldenTicket, )
src/wallet.rs:292
↓ 2 callers
Method
create_staking_deposit_transaction
creates a transaction that will deposit tokens into the staking system in the amount specified, if possible. the transaction will be invalid if there
src/wallet.rs:328
↓ 2 callers
Function
decrypt_with_password
(msg: Vec<u8>, password: &str)
src/crypto.rs:35
↓ 2 callers
Method
do_reqblock
REQBLOCK is a response to both SNDCHAIN and SNDBLKHD. This function simply wraps shared functionality.
src/peer.rs:346
↓ 2 callers
Method
downgrade_block_to_block_type
if the block is not at the proper type, try to downgrade it by removing elements that take up significant amounts of data / memory. if this is possibl
src/block.rs:516
↓ 2 callers
Function
encrypt_with_password
(msg: Vec<u8>, password: &str)
src/crypto.rs:23
↓ 2 callers
Method
find_winning_router
consumes two hashes every time
src/block.rs:1139
↓ 2 callers
Method
find_winning_staker
(&self, random_number: SaitoHash)
src/staking.rs:36
↓ 2 callers
Method
generate_consensus_values
generate hashes and payouts and fee calculations
src/block.rs:802
↓ 2 callers
Method
generate_hash
Compute and memoize hash`
src/block.rs:548
↓ 2 callers
Method
generate_metadata_cumulative_fees
calculate cumulative fee share in block
src/transaction.rs:714
↓ 2 callers
Method
generate_pre_hash
Compute and memoize pre-hash`
src/block.rs:555
↓ 2 callers
Method
get_block_hashes_at_block_id
(&mut self, block_id: u64)
src/blockring.rs:144
↓ 2 callers
Method
get_block_type
(&self)
src/block.rs:297
↓ 2 callers
Method
get_has_completed_handshake
(&self)
src/peer.rs:203
↓ 2 callers
Method
get_latest_block
(&self)
src/blockchain.rs:735
↓ 2 callers
Method
get_latest_block_id
(&self)
src/blockring.rs:223
↓ 2 callers
Method
get_merkle_root
(&self)
src/block.rs:277
↓ 2 callers
Method
get_message_id
(&self)
src/networking/api_message.rs:55
↓ 2 callers
Method
get_password
(&mut self)
src/wallet.rs:208
↓ 2 callers
Method
get_sig
(&self)
src/hop.rs:58
↓ 2 callers
Method
get_source_connection_id
(&self)
src/block.rs:342
↓ 2 callers
Method
get_spent
(&self)
src/wallet.rs:480
↓ 2 callers
Method
get_uuid
(&self)
src/slip.rs:158
↓ 2 callers
Method
hash
(&mut self)
src/merkle.rs:25
↓ 2 callers
Method
is_golden_ticket
(&self)
src/transaction.rs:394
↓ 2 callers
Method
on_chain_reorganization
( &self, utxoset: &mut AHashMap<SaitoUTXOSetKey, u64>, _lc: bool, slip_value:
src/slip.rs:95
↓ 2 callers
Method
opponent_pubkey
(&self)
src/networking/message_types/handshake_challenge.rs:104
↓ 2 callers
Method
print
(&self)
src/blockchain.rs:720
↓ 2 callers
Method
remove_pending
(&mut self, slip: Slip)
src/staking.rs:253
↓ 2 callers
Method
remove_staker
(&mut self, slip: Slip)
src/staking.rs:243
↓ 2 callers
Function
run
( network_lock: Arc<RwLock<Network>>, broadcast_channel_sender: broadcast::Sender<SaitoMessage>, m
src/network.rs:318
↓ 2 callers
Method
send_command_fire_and_forget
sends a command to the peer's socket but doesn't not await the response
src/peer.rs:277
↓ 2 callers
Method
serialize
(&self)
src/networking/message_types/request_block_message.rs:85
↓ 2 callers
Method
serialize_for_net_with_hop
(&self, opt_hop: Option<Hop>)
src/transaction.rs:647
↓ 2 callers
Method
serialize_for_signature
(&self)
src/transaction.rs:554
↓ 2 callers
Method
serialize_with_sig
(&self, privatekey: SaitoPrivateKey)
src/networking/message_types/handshake_challenge.rs:88
↓ 2 callers
Method
set_filename
(&mut self, filename: String)
src/wallet.rs:196
↓ 2 callers
Method
set_has_completed_handshake
(&mut self, has_completed_handshake: bool)
src/peer.rs:200
↓ 2 callers
Method
set_outputs
(&mut self, outputs: Vec<Slip>)
src/transaction.rs:521
↓ 2 callers
Method
set_password
(&mut self, filepass: String)
src/wallet.rs:200
↓ 2 callers
Method
set_path
(&mut self, path: Vec<Hop>)
src/transaction.rs:533
↓ 2 callers
Method
set_source_connection_id
(&mut self, source_connection_id: SaitoHash)
src/block.rs:460
↓ 2 callers
Method
set_spent
(&mut self, spent: bool)
src/wallet.rs:484
↓ 2 callers
Method
set_staking_treasury
(&mut self, staking_treasury: u64)
src/block.rs:442
↓ 2 callers
Method
set_timestamp
(&mut self, timestamp: u64)
src/transaction.rs:509
↓ 2 callers
Method
sign
(&mut self, privatekey: SaitoPrivateKey)
src/transaction.rs:541
↓ 2 callers
Function
socket_handshake_verify
(message_data: &Vec<u8>)
src/peer.rs:641
↓ 2 callers
Method
unwind_chain
( &mut self, new_chain: &Vec<[u8; 32]>, old_chain: &Vec<[u8; 32]>, current_unw
src/blockchain.rs:1123
↓ 2 callers
Method
validate
when new_chain and old_chain are generated the block_hashes are added to their vectors from tip-to-shared-ancestors. if the shared ancestors is at pos
src/blockchain.rs:817
↓ 2 callers
Method
validate_slip_in_pending
(&self, slip: Slip)
src/staking.rs:177
↓ 2 callers
Method
validate_slip_in_stakers
(&self, slip: Slip)
src/staking.rs:168
↓ 2 callers
Method
wind_chain
( &mut self, new_chain: &Vec<[u8; 32]>, old_chain: &Vec<[u8; 32]>, current_win
src/blockchain.rs:901
↓ 2 callers
Function
with_mempool
inject peers db lock
src/networking/filters.rs:71
↓ 2 callers
Function
ws_upgrade_route_filter
websocket upgrade filter.
src/networking/filters.rs:15
↓ 1 callers
Method
add_block_success
(&mut self, block_hash: SaitoHash)
src/blockchain.rs:369
↓ 1 callers
Method
add_transaction
(&mut self, mut transaction: Transaction)
src/mempool.rs:100
↓ 1 callers
Method
add_transaction_if_validates
( &mut self, transaction: Transaction, blockchain_lock: Arc<RwLock<Blockchain>>, )
src/mempool.rs:87
↓ 1 callers
Method
build_last_hop
( &mut self, wallet_lock: Arc<RwLock<Wallet>>, peer_pubkey: SaitoPublicKey, )
src/transaction.rs:112
← previous
next →
101–200 of 495, ranked by callers