edb_engine/utils/mod.rs
1// EDB - Ethereum Debugger
2// Copyright (C) 2024 Zhuo Zhang and Wuqi Zhang
3//
4// This program is free software: you can redistribute it and/or modify
5// it under the terms of the GNU Affero General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU Affero General Public License for more details.
13//
14// You should have received a copy of the GNU Affero General Public License
15// along with this program. If not, see <https://www.gnu.org/licenses/>.
16
17//! Utility functions and helpers for the EDB engine.
18//!
19//! This module provides a collection of utility functions and helper modules that support
20//! various aspects of the EDB debugging engine. These utilities handle common tasks across
21//! contract analysis, compilation, source code processing, and external service integration.
22//!
23//! # Core Utility Modules
24//!
25//! ## Contract and Artifact Management
26//! - [`artifact`] - Contract artifact handling and metadata management
27//! - [`compilation`] - Solidity compilation utilities and configuration
28//! - [`abi`] - ABI processing and type conversion utilities
29//!
30//! ## Source Code Processing
31//! - [`source`] - Source code analysis and manipulation utilities
32//! - [`ast_prune`] - AST pruning and optimization for instrumentation
33//!
34//! ## Bytecode Analysis
35//! - [`disasm`] - EVM bytecode disassembly and analysis utilities
36//!
37//! ## External Service Integration
38//! - [`etherscan`] - Etherscan API integration and data fetching utilities
39//!
40//! # Design Philosophy
41//!
42//! The utilities in this module are designed to be:
43//! - **Reusable**: Common functionality shared across multiple engine components
44//! - **Efficient**: Optimized for performance in debugging scenarios
45//! - **Reliable**: Robust error handling and edge case management
46//! - **Modular**: Independent modules that can be used separately
47//!
48//! Each utility module focuses on a specific domain while providing clean interfaces
49//! for integration with the broader EDB engine ecosystem.
50
51mod artifact;
52pub use artifact::*;
53
54mod ast_prune;
55pub use ast_prune::*;
56
57pub mod disasm;
58pub use disasm::*;
59
60mod etherscan;
61pub use etherscan::*;
62
63mod compilation;
64pub use compilation::*;
65
66mod source;
67pub use source::*;
68
69mod abi;
70pub use abi::*;