SYMBOL INDEX (253 symbols across 29 files) FILE: benches/erc_4626.rs function simulate_swap (line 6) | fn simulate_swap(c: &mut Criterion) { FILE: benches/uniswap_v2.rs function simulate_swap (line 6) | fn simulate_swap(c: &mut Criterion) { FILE: benches/uniswap_v3.rs function simulate_swap (line 15) | fn simulate_swap(c: &mut Criterion) { FILE: build.rs constant TARGET_CONTRACTS (line 10) | const TARGET_CONTRACTS: &[&str] = &[ function main (line 24) | fn main() -> Result<(), Box> { function hash (line 73) | fn hash(value: &str) -> u64 { FILE: examples/filters.rs function main (line 17) | async fn main() -> eyre::Result<()> { FILE: examples/simulate_swap.rs function main (line 13) | async fn main() -> eyre::Result<()> { FILE: examples/state_space_builder.rs function main (line 19) | async fn main() -> eyre::Result<()> { FILE: examples/subscribe.rs function main (line 12) | async fn main() -> eyre::Result<()> { FILE: examples/swap_calldata.rs function main (line 12) | async fn main() -> eyre::Result<()> { FILE: examples/sync_macro.rs function main (line 22) | async fn main() -> eyre::Result<()> { FILE: src/amms/amm.rs type AutomatedMarketMaker (line 17) | pub trait AutomatedMarketMaker { method address (line 19) | fn address(&self) -> Address; method sync_events (line 22) | fn sync_events(&self) -> Vec; method sync (line 25) | fn sync(&mut self, log: &Log) -> Result<(), AMMError>; method tokens (line 28) | fn tokens(&self) -> Vec
; method calculate_price (line 31) | fn calculate_price(&self, base_token: Address, quote_token: Address) -... method simulate_swap (line 35) | fn simulate_swap( method simulate_swap_mut (line 44) | fn simulate_swap_mut( method init (line 52) | async fn init(self, block_number: BlockId, provider: P) -> Resul... FILE: src/amms/balancer/bmath.rs function btoi (line 7) | pub fn btoi(a: U256) -> U256 { function badd (line 12) | pub fn badd(a: U256, b: U256) -> Result { function bpowi (line 21) | pub fn bpowi(a: U256, n: U256) -> Result { function bpow (line 37) | pub fn bpow(base: U256, exp: U256) -> Result { function bpow_approx (line 50) | pub fn bpow_approx(base: U256, exp: U256, precision: U256) -> Result U256 { function bdiv (line 84) | pub fn bdiv(a: U256, b: U256) -> Result { function bsub (line 102) | pub fn bsub(a: U256, b: U256) -> Result { function bsub_sign (line 113) | pub fn bsub_sign(a: U256, b: U256) -> (U256, bool) { function bmul (line 124) | pub fn bmul(a: U256, b: U256) -> Result { function calculate_price (line 145) | pub fn calculate_price( function calculate_out_given_in (line 169) | pub fn calculate_out_given_in( FILE: src/amms/balancer/mod.rs type BalancerError (line 86) | pub enum BalancerError { type BalancerPool (line 106) | pub struct BalancerPool { method new (line 356) | pub fn new(address: Address) -> BalancerPool { type TokenPoolState (line 115) | pub struct TokenPoolState { method address (line 123) | fn address(&self) -> Address { method sync_events (line 127) | fn sync_events(&self) -> Vec { method sync (line 135) | fn sync(&mut self, log: &Log) -> Result<(), AMMError> { method tokens (line 190) | fn tokens(&self) -> Vec
{ method calculate_price (line 204) | fn calculate_price(&self, base_token: Address, quote_token: Address) -> ... method simulate_swap (line 249) | fn simulate_swap( method simulate_swap_mut (line 280) | fn simulate_swap_mut( method init (line 311) | async fn init(mut self, block_number: BlockId, provider: P) -> Res... type BalancerFactory (line 365) | pub struct BalancerFactory { method new (line 437) | pub fn new(address: Address, creation_block: u64) -> BalancerFactory { method get_all_pools (line 444) | pub async fn get_all_pools( method sync_all_pools (line 489) | pub async fn sync_all_pools( type PoolVariant (line 372) | type PoolVariant = BalancerPool; method address (line 375) | fn address(&self) -> Address { method create_pool (line 380) | fn create_pool(&self, log: Log) -> Result { method creation_block (line 389) | fn creation_block(&self) -> u64 { method pool_creation_event (line 394) | fn pool_creation_event(&self) -> B256 { method discover (line 400) | fn discover( method sync (line 417) | fn sync( function test_populate_data (line 598) | pub async fn test_populate_data() -> eyre::Result<()> { function test_calculate_price (line 646) | pub async fn test_calculate_price() -> eyre::Result<()> { function test_simulate_swap (line 668) | pub async fn test_simulate_swap() -> eyre::Result<()> { FILE: src/amms/consts.rs constant U256_10E_10 (line 4) | pub const U256_10E_10: U256 = U256::from_limbs([10000000000, 0, 0, 0]); constant U256_0X100000000 (line 5) | pub const U256_0X100000000: U256 = U256::from_limbs([4294967296, 0, 0, 0]); constant U256_0X10000 (line 6) | pub const U256_0X10000: U256 = U256::from_limbs([65536, 0, 0, 0]); constant U256_0X100 (line 7) | pub const U256_0X100: U256 = U256::from_limbs([256, 0, 0, 0]); constant U256_1000 (line 8) | pub const U256_1000: U256 = U256::from_limbs([1000, 0, 0, 0]); constant U256_10000 (line 9) | pub const U256_10000: U256 = U256::from_limbs([10000, 0, 0, 0]); constant U256_100000 (line 10) | pub const U256_100000: U256 = U256::from_limbs([100000, 0, 0, 0]); constant U256_255 (line 11) | pub const U256_255: U256 = U256::from_limbs([255, 0, 0, 0]); constant U256_192 (line 12) | pub const U256_192: U256 = U256::from_limbs([192, 0, 0, 0]); constant U256_191 (line 13) | pub const U256_191: U256 = U256::from_limbs([191, 0, 0, 0]); constant U256_128 (line 14) | pub const U256_128: U256 = U256::from_limbs([128, 0, 0, 0]); constant U256_64 (line 15) | pub const U256_64: U256 = U256::from_limbs([64, 0, 0, 0]); constant U256_32 (line 16) | pub const U256_32: U256 = U256::from_limbs([32, 0, 0, 0]); constant U256_16 (line 17) | pub const U256_16: U256 = U256::from_limbs([16, 0, 0, 0]); constant U256_10 (line 18) | pub const U256_10: U256 = U256::from_limbs([10, 0, 0, 0]); constant U256_8 (line 19) | pub const U256_8: U256 = U256::from_limbs([8, 0, 0, 0]); constant U256_4 (line 20) | pub const U256_4: U256 = U256::from_limbs([4, 0, 0, 0]); constant U256_2 (line 21) | pub const U256_2: U256 = U256::from_limbs([2, 0, 0, 0]); constant U256_1 (line 22) | pub const U256_1: U256 = U256::from_limbs([1, 0, 0, 0]); constant POPULATE_TICK_DATA_STEP (line 25) | pub const POPULATE_TICK_DATA_STEP: u64 = 100000; constant Q128 (line 26) | pub const Q128: U256 = U256::from_limbs([0, 0, 1, 0]); constant Q224 (line 27) | pub const Q224: U256 = U256::from_limbs([0, 0, 0, 4294967296]); constant BONE (line 30) | pub const BONE: U256 = U256::from_limbs([0xDE0B6B3A7640000, 0, 0, 0]); constant U128_0X10000000000000000 (line 33) | pub const U128_0X10000000000000000: u128 = 18446744073709551616; constant U256_0XFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF (line 34) | pub const U256_0XFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF: U256 ... constant U256_0XFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF (line 40) | pub const U256_0XFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF: U256 = constant DECIMAL_RADIX (line 43) | pub const DECIMAL_RADIX: i32 = 10; constant MPFR_T_PRECISION (line 44) | pub const MPFR_T_PRECISION: u32 = 70; FILE: src/amms/erc_4626/mod.rs type ERC4626VaultError (line 42) | pub enum ERC4626VaultError { type ERC4626Vault (line 52) | pub struct ERC4626Vault { method new (line 249) | pub fn new(address: Address) -> Self { method get_amount_out (line 256) | pub fn get_amount_out( method calculate_price_64_x_64 (line 283) | pub fn calculate_price_64_x_64(&self, base_token: Address) -> Result( method address (line 70) | fn address(&self) -> Address { method sync_events (line 74) | fn sync_events(&self) -> Vec { method sync (line 81) | fn sync(&mut self, log: &Log) -> Result<(), AMMError> { method tokens (line 120) | fn tokens(&self) -> Vec
{ method calculate_price (line 124) | fn calculate_price(&self, base_token: Address, _quote_token: Address) ->... method simulate_swap (line 128) | fn simulate_swap( method simulate_swap_mut (line 141) | fn simulate_swap_mut( method init (line 167) | async fn init(mut self, block_number: BlockId, provider: P) -> Res... FILE: src/amms/error.rs type AMMError (line 9) | pub enum AMMError { type BatchContractError (line 37) | pub enum BatchContractError { FILE: src/amms/factory.rs type DiscoverySync (line 21) | pub trait DiscoverySync { method discover (line 22) | fn discover( method sync (line 31) | fn sync( type AutomatedMarketMakerFactory (line 42) | pub trait AutomatedMarketMakerFactory: DiscoverySync { method address (line 46) | fn address(&self) -> Address; method create_pool (line 49) | fn create_pool(&self, log: Log) -> Result; method creation_block (line 52) | fn creation_block(&self) -> u64; method pool_creation_event (line 55) | fn pool_creation_event(&self) -> B256; method pool_events (line 58) | fn pool_events(&self) -> Vec { method pool_variant (line 62) | fn pool_variant(&self) -> Self::PoolVariant { type NoopAMM (line 162) | pub struct NoopAMM; method address (line 164) | fn address(&self) -> Address { method sync_events (line 168) | fn sync_events(&self) -> Vec { method sync (line 172) | fn sync(&mut self, _log: &Log) -> Result<(), AMMError> { method simulate_swap (line 176) | fn simulate_swap( method simulate_swap_mut (line 185) | fn simulate_swap_mut( method calculate_price (line 193) | fn calculate_price( method tokens (line 201) | fn tokens(&self) -> Vec
{ method init (line 205) | async fn init(self, _block_number: BlockId, _provider: P) -> Resul... FILE: src/amms/float.rs function q64_to_float (line 9) | pub fn q64_to_float(num: u128) -> Result { function u128_to_float (line 15) | pub fn u128_to_float(num: u128) -> Result { function u256_to_float (line 21) | pub fn u256_to_float(num: U256) -> Result { FILE: src/amms/mod.rs type Token (line 35) | pub struct Token { method new (line 42) | pub async fn new(address: Address, provider: P) -> Result Self { method address (line 56) | pub const fn address(&self) -> &Address { method decimals (line 60) | pub const fn decimals(&self) -> u8 { method from (line 66) | fn from(address: Address) -> Self { method hash (line 75) | fn hash(&self, state: &mut H) { function get_token_decimals (line 84) | pub async fn get_token_decimals( FILE: src/amms/uniswap_v2/mod.rs type UniswapV2Error (line 71) | pub enum UniswapV2Error { type UniswapV2Pool (line 79) | pub struct UniswapV2Pool { method new (line 216) | pub fn new(address: Address, fee: usize) -> Self { method get_amount_out (line 225) | pub fn get_amount_out(&self, amount_in: U256, reserve_in: U256, reserv... method calculate_price_64_x_64 (line 240) | pub fn calculate_price_64_x_64(&self, base_token: Address) -> Result Address { method sync_events (line 93) | fn sync_events(&self) -> Vec { method sync (line 97) | fn sync(&mut self, log: &Log) -> Result<(), AMMError> { method simulate_swap (line 116) | fn simulate_swap( method simulate_swap_mut (line 137) | fn simulate_swap_mut( method tokens (line 168) | fn tokens(&self) -> Vec
{ method calculate_price (line 172) | fn calculate_price(&self, base_token: Address, _quote_token: Address) ->... method init (line 177) | async fn init(mut self, block_number: BlockId, provider: P) -> Res... function u128_to_float (line 207) | pub fn u128_to_float(num: u128) -> Result { function div_uu (line 287) | pub fn div_uu(x: U256, y: U256) -> Result { type UniswapV2Factory (line 369) | pub struct UniswapV2Factory { method new (line 376) | pub fn new(address: Address, fee: usize, creation_block: u64) -> Self { method get_all_pairs (line 384) | pub async fn get_all_pairs( method sync_all_pools (line 434) | pub async fn sync_all_pools( type PoolVariant (line 515) | type PoolVariant = UniswapV2Pool; method address (line 517) | fn address(&self) -> Address { method pool_creation_event (line 521) | fn pool_creation_event(&self) -> B256 { method create_pool (line 525) | fn create_pool(&self, log: Log) -> Result { method creation_block (line 537) | fn creation_block(&self) -> u64 { method discover (line 543) | fn discover( method sync (line 579) | fn sync( function test_get_amount_out (line 607) | fn test_get_amount_out() { function test_calculate_price_edge_case (line 625) | fn test_calculate_price_edge_case() { function test_calculate_price (line 648) | async fn test_calculate_price() { function test_calculate_price_64_x_64 (line 678) | async fn test_calculate_price_64_x_64() { FILE: src/amms/uniswap_v3/mod.rs type UniswapV3Error (line 120) | pub enum UniswapV3Error { type UniswapV3Pool (line 128) | pub struct UniswapV3Pool { method new (line 613) | pub fn new(address: Address) -> Self { method modify_position (line 621) | pub fn modify_position( method update_position (line 645) | pub fn update_position( method update_tick (line 678) | pub fn update_tick( method flip_tick (line 713) | pub fn flip_tick(&mut self, tick: i32, tick_spacing: i32) { method swap_calldata (line 724) | pub fn swap_calldata( type Info (line 142) | pub struct Info { method new (line 149) | pub fn new(liquidity_gross: u128, liquidity_net: i128, initialized: bo... type CurrentState (line 158) | pub struct CurrentState { type StepComputations (line 167) | pub struct StepComputations { type Tick (line 177) | pub struct Tick { method address (line 189) | fn address(&self) -> Address { method sync_events (line 193) | fn sync_events(&self) -> Vec { method sync (line 201) | fn sync(&mut self, log: &Log) -> Result<(), AMMError> { method simulate_swap (line 264) | fn simulate_swap( method simulate_swap_mut (line 408) | fn simulate_swap_mut( method tokens (line 560) | fn tokens(&self) -> Vec
{ method calculate_price (line 564) | fn calculate_price(&self, base_token: Address, _quote_token: Address) ->... method init (line 582) | async fn init(mut self, block_number: BlockId, provider: P) -> Res... type UniswapV3Factory (line 745) | pub struct UniswapV3Factory { method new (line 751) | pub fn new(address: Address, creation_block: u64) -> Self { method get_all_pools (line 758) | pub async fn get_all_pools( method sync_all_pools (line 803) | pub async fn sync_all_pools( method sync_token_decimals (line 833) | async fn sync_token_decimals( method sync_slot_0 (line 868) | async fn sync_slot_0( method sync_tick_bitmaps (line 916) | async fn sync_tick_bitmaps( method sync_tick_data (line 1025) | async fn sync_tick_data( function tick_to_word (line 1162) | fn tick_to_word(tick: i32, tick_spacing: i32) -> i32 { type PoolVariant (line 1172) | type PoolVariant = UniswapV3Pool; method address (line 1174) | fn address(&self) -> Address { method pool_creation_event (line 1178) | fn pool_creation_event(&self) -> B256 { method create_pool (line 1182) | fn create_pool(&self, log: Log) -> Result { method creation_block (line 1196) | fn creation_block(&self) -> u64 { method discover (line 1202) | fn discover( method sync (line 1220) | fn sync( function test_simulate_swap_usdc_weth (line 1262) | async fn test_simulate_swap_usdc_weth() -> eyre::Result<()> { function test_simulate_swap_link_weth (line 1429) | async fn test_simulate_swap_link_weth() -> eyre::Result<()> { function test_calculate_price (line 1593) | async fn test_calculate_price() -> eyre::Result<()> { FILE: src/state_space/cache.rs type StateChangeCache (line 8) | pub struct StateChangeCache { method default (line 14) | fn default() -> Self { function new (line 20) | pub fn new() -> Self { function is_empty (line 27) | pub fn is_empty(&self) -> bool { function push (line 31) | pub fn push(&mut self, state_change: StateChange) { function unwind_state_changes (line 45) | pub fn unwind_state_changes(&mut self, block_to_unwind: u64) -> Vec { function flatten_state_changes (line 73) | fn flatten_state_changes(&self, state_changes: Vec) -> Vec<... type StateChange (line 91) | pub struct StateChange { method new (line 97) | pub fn new(state_change: Vec, block_number: u64) -> Self { FILE: src/state_space/discovery.rs type DiscoveryManager (line 10) | pub struct DiscoveryManager { method new (line 17) | pub fn new(factories: Vec) -> Self { method with_pool_filters (line 31) | pub fn with_pool_filters(self, pool_filters: Vec) -> Self { method disc_events (line 38) | pub fn disc_events(&self) -> HashSet> { FILE: src/state_space/error.rs type StateSpaceError (line 7) | pub enum StateSpaceError { FILE: src/state_space/filters/blacklist.rs type BlacklistFilter (line 12) | pub struct BlacklistFilter { method new (line 18) | pub fn new(blacklist: Vec
) -> Self { method filter (line 26) | async fn filter(&self, amms: Vec) -> Result, AMMError> { method stage (line 38) | fn stage(&self) -> FilterStage { FILE: src/state_space/filters/mod.rs type AMMFilter (line 11) | pub trait AMMFilter { method filter (line 12) | async fn filter(&self, amms: Vec) -> Result, AMMError>; method stage (line 13) | fn stage(&self) -> FilterStage; type FilterStage (line 17) | pub enum FilterStage { FILE: src/state_space/filters/value.rs type ValueFilter (line 24) | pub struct ValueFilter function new (line 42) | pub fn new( function get_weth_value_in_pools (line 59) | pub async fn get_weth_value_in_pools( method filter (line 87) | async fn filter(&self, amms: Vec) -> Result, AMMError> { method stage (line 133) | fn stage(&self) -> FilterStage { FILE: src/state_space/filters/whitelist.rs type PoolWhitelistFilter (line 12) | pub struct PoolWhitelistFilter { method new (line 17) | pub fn new(pools: Vec
) -> Self { method filter (line 25) | async fn filter(&self, amms: Vec) -> Result, AMMError> { method stage (line 32) | fn stage(&self) -> FilterStage { type TokenWhitelistFilter (line 38) | pub struct TokenWhitelistFilter { method new (line 43) | pub fn new(tokens: Vec
) -> Self { method filter (line 51) | async fn filter(&self, amms: Vec) -> Result, AMMError> { method stage (line 58) | fn stage(&self) -> FilterStage { FILE: src/state_space/mod.rs constant CACHE_SIZE (line 38) | pub const CACHE_SIZE: usize = 30; type StateSpaceManager (line 41) | pub struct StateSpaceManager { function subscribe (line 52) | pub async fn subscribe( type StateSpaceBuilder (line 90) | pub struct StateSpaceBuilder { function new (line 105) | pub fn new(provider: P) -> StateSpaceBuilder { function block (line 117) | pub fn block(self, latest_block: u64) -> StateSpaceBuilder { function with_factories (line 124) | pub fn with_factories(self, factories: Vec) -> StateSpaceBuilde... function with_amms (line 128) | pub fn with_amms(self, amms: Vec) -> StateSpaceBuilder { function with_filters (line 132) | pub fn with_filters(self, filters: Vec) -> StateSpaceBuilder... function sync (line 136) | pub async fn sync(self) -> Result, AMMError> { type StateSpace (line 246) | pub struct StateSpace { method get (line 253) | pub fn get(&self, address: &Address) -> Option<&AMM> { method get_mut (line 257) | pub fn get_mut(&mut self, address: &Address) -> Option<&mut AMM> { method sync (line 261) | pub fn sync(&mut self, logs: &[Log]) -> Result, StateSpac...