sigil-wallet · config
Source declarations, signatures and documentation for config.
Source: sigil/node/sigil-wallet/src/config.rs. SHA-256: 3269d576e02006f12cce6a496a95bb36376bd08b2bd2145bf81b327b2ea8aaac.
This reference follows declared source modules, retains conditional attributes, and includes public declarations and implementation methods. Private-module re-exports and trait resolution require the compiler; this is a source reference, not a claim that every listed item is a root import. Function bodies and constant values are omitted.
config::NetworkConfig
Network connection settings.
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct NetworkConfig {
/// JSON-RPC endpoint URL.
pub rpc_url: String,
/// Chain identifier.
pub chain_id: String
}Source line: 19.
config::WalletConfig
Wallet identity settings.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
pub struct WalletConfig {
/// The default identity DID to use for transactions.
#[serde(skip_serializing_if = "Option::is_none")]
pub default_identity: Option<String>
}Source line: 37.
config::DisplayConfig
Display preferences.
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct DisplayConfig {
/// Output format: "table" or "json".
pub format: String
}Source line: 45.
config::Config
Top-level wallet configuration.
#[derive(Debug, Clone, Default, Serialize, Deserialize)]
pub struct Config {
/// Network connection settings.
#[serde(default)]
pub network: NetworkConfig,
/// Wallet identity settings.
#[serde(default)]
pub wallet: WalletConfig,
/// Display preferences.
#[serde(default)]
pub display: DisplayConfig
}Source line: 60.
config::Config::base_dir
Returns the base directory for Sigil wallet data (~/.sigil/).
pub fn base_dir() -> WalletResult<PathBuf>;Source line: 74.
config::Config::config_path
Returns the path to the configuration file (~/.sigil/config.toml).
pub fn config_path() -> WalletResult<PathBuf>;Source line: 81.
config::Config::keystore_dir
Returns the path to the keystore directory (~/.sigil/keystore/).
pub fn keystore_dir() -> WalletResult<PathBuf>;Source line: 86.
config::Config::load
Load configuration from the default path. Returns defaults if the file does not exist.
pub fn load() -> WalletResult<Self>;Source line: 92.
config::Config::load_from
Load configuration from a specific path. Returns defaults if the file does not exist.
pub fn load_from(path: &Path) -> WalletResult<Self>;Source line: 99.
config::Config::save
Save configuration to the default path, creating the directory if needed.
pub fn save(&self) -> WalletResult<()>;Source line: 111.
config::Config::save_to
Save configuration to a specific path, creating parent directories if needed.
pub fn save_to(&self, path: &Path) -> WalletResult<()>;Source line: 117.