pub struct ElectrsD {
pub client: RawClient<ElectrumPlaintextStream>,
pub electrum_url: String,
pub esplora_url: Option<String>,
/* private fields */
}
Expand description
Struct representing the bitcoind process with related information
Fields§
§client: RawClient<ElectrumPlaintextStream>
Electrum client connected to the electrs process
electrum_url: String
Url to connect to the electrum protocol (tcp)
esplora_url: Option<String>
Url to connect to esplora protocol (http)
Implementations§
source§impl ElectrsD
impl ElectrsD
sourcepub fn new<S: AsRef<OsStr>>(
exe: S,
bitcoind: &BitcoinD
) -> Result<ElectrsD, Error>
pub fn new<S: AsRef<OsStr>>(
exe: S,
bitcoind: &BitcoinD
) -> Result<ElectrsD, Error>
Create a new electrs process connected with the given bitcoind and default args.
sourcepub fn with_conf<S: AsRef<OsStr>>(
exe: S,
bitcoind: &BitcoinD,
conf: &Conf<'_>
) -> Result<ElectrsD, Error>
pub fn with_conf<S: AsRef<OsStr>>(
exe: S,
bitcoind: &BitcoinD,
conf: &Conf<'_>
) -> Result<ElectrsD, Error>
Create a new electrs process using given Conf connected with the given bitcoind