bitcoin_rpc_midas/transport/syncwithvalidationinterfacequeue.rs
1//! This file is auto-generated. Do not edit manually.
2//! Generated from Bitcoin Core v30
3
4/// Waits for the validation interface queue to catch up on everything that was there when we entered this function.
5/// # Example: High-Level Client Usage (Recommended)
6/// ```rust
7/// use bitcoin_rpc_midas::*;
8///
9/// async fn example() -> Result<(), Box<dyn std::error::Error>> {
10/// let client = BitcoinTestClient::new().await?;
11/// let result = client.syncwithvalidationinterfacequeue().await?;
12/// # Ok(())
13/// # }
14/// ```
15/// # Example: Advanced - Direct Transport Function Usage
16/// This approach is for advanced users who need direct control over the transport layer.
17/// Most users should prefer the high-level client approach above.
18/// ```rust
19/// use bitcoin_rpc_midas::transport::syncwithvalidationinterfacequeue;
20/// use bitcoin_rpc_midas::transport::{TransportTrait, DefaultTransport};
21///
22/// async fn example() -> Result<(), Box<dyn std::error::Error>> {
23/// let transport = DefaultTransport::new(
24/// "http://127.0.0.1:18443".to_string(),
25/// Some(("rpcuser".to_string(), "rpcpassword".to_string()))
26/// );
27/// let result = syncwithvalidationinterfacequeue(&transport).await?;
28/// # Ok(())
29/// # }
30/// ```
31#[allow(unused_imports)]
32use serde_json::Value;
33
34use crate::transport::{TransportError, TransportTrait};
35
36/// Calls the `syncwithvalidationinterfacequeue` RPC method.
37///
38/// Generated transport wrapper for JSON-RPC.
39pub async fn syncwithvalidationinterfacequeue(
40 transport: &dyn TransportTrait,
41) -> Result<Value, TransportError> {
42 let params = Vec::<Value>::new();
43 let raw = transport.send_request("syncwithvalidationinterfacequeue", ¶ms).await?;
44 Ok(raw)
45}