pub struct RethInstance { /* private fields */ }
Expand description
A Reth instance. Will close the instance when dropped.
Construct this using Reth
.
Implementations§
Source§impl RethInstance
impl RethInstance
Sourcepub const fn p2p_port(&self) -> Option<u16>
pub const fn p2p_port(&self) -> Option<u16>
Returns the p2p port of this instance.
If discovery is disabled, this will be None
.
Sourcepub fn ws_endpoint(&self) -> String
pub fn ws_endpoint(&self) -> String
Returns the Websocket endpoint of this instance.
Sourcepub fn ipc_endpoint(&self) -> String
pub fn ipc_endpoint(&self) -> String
Returns the IPC endpoint of this instance.
Sourcepub fn endpoint_url(&self) -> Url
pub fn endpoint_url(&self) -> Url
Returns the HTTP endpoint url of this instance.
Sourcepub fn ws_endpoint_url(&self) -> Url
pub fn ws_endpoint_url(&self) -> Url
Returns the Websocket endpoint url of this instance.
Sourcepub const fn data_dir(&self) -> Option<&PathBuf>
pub const fn data_dir(&self) -> Option<&PathBuf>
Returns the path to this instances’ data directory.
Sourcepub const fn genesis(&self) -> Option<&Genesis>
pub const fn genesis(&self) -> Option<&Genesis>
Returns the genesis configuration used to configure this instance
Sourcepub fn stdout(&mut self) -> Result<ChildStdout, NodeError>
pub fn stdout(&mut self) -> Result<ChildStdout, NodeError>
Takes the stdout contained in the child process.
This leaves a None
in its place, so calling methods that require a stdout to be present
will fail if called after this.
Trait Implementations§
Source§impl Debug for RethInstance
impl Debug for RethInstance
Auto Trait Implementations§
impl !Freeze for RethInstance
impl RefUnwindSafe for RethInstance
impl Send for RethInstance
impl Sync for RethInstance
impl Unpin for RethInstance
impl UnwindSafe for RethInstance
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more