File tree Expand file tree Collapse file tree 25 files changed +109
-21
lines changed Expand file tree Collapse file tree 25 files changed +109
-21
lines changed Original file line number Diff line number Diff line change 5
5
//! We ignore option arguments unless they effect the shape of the returned JSON data.
6
6
7
7
pub mod control;
8
+ pub mod network;
8
9
pub mod raw_transactions;
9
10
10
11
use std:: collections:: BTreeMap ;
@@ -74,6 +75,7 @@ crate::impl_client_v17__submitblock!();
74
75
crate :: impl_client_v17__getaddednodeinfo!( ) ;
75
76
crate :: impl_client_v17__getnettotals!( ) ;
76
77
crate :: impl_client_v17__getnetworkinfo!( ) ;
78
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
77
79
crate :: impl_client_v17__getpeerinfo!( ) ;
78
80
79
81
// == Rawtransactions ==
Original file line number Diff line number Diff line change
1
+ // SPDX-License-Identifier: CC0-1.0
2
+
3
+ //! Macros for implementing JSON-RPC methods on a client.
4
+ //!
5
+ //! Requires `Client` to be in scope.
6
+ //!
7
+ //! Specifically this is methods found under the `== Network ==` section of the
8
+ //! API docs of Bitcoin Core `v0.18`.
9
+ //!
10
+ //! See, or use the `define_jsonrpc_minreq_client!` macro to define a `Client`.
11
+
12
+ /// Implements Bitcoin Core JSON-RPC API method `getnodeaddresses`
13
+ #[ macro_export]
14
+ macro_rules! impl_client_v18__getnodeaddresses {
15
+ ( ) => {
16
+ impl Client {
17
+ pub fn get_node_addresses( & self ) -> Result <GetNodeAddresses > {
18
+ self . call( "getnodeaddresses" , & [ ] )
19
+ }
20
+ }
21
+ } ;
22
+ }
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ crate::impl_client_v17__submitblock!();
73
73
crate :: impl_client_v17__getaddednodeinfo!( ) ;
74
74
crate :: impl_client_v17__getnettotals!( ) ;
75
75
crate :: impl_client_v17__getnetworkinfo!( ) ;
76
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
76
77
crate :: impl_client_v17__getpeerinfo!( ) ;
77
78
78
79
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -70,6 +70,7 @@ crate::impl_client_v17__submitblock!();
70
70
crate :: impl_client_v17__getaddednodeinfo!( ) ;
71
71
crate :: impl_client_v17__getnettotals!( ) ;
72
72
crate :: impl_client_v17__getnetworkinfo!( ) ;
73
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
73
74
crate :: impl_client_v17__getpeerinfo!( ) ;
74
75
75
76
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -72,6 +72,7 @@ crate::impl_client_v17__submitblock!();
72
72
crate :: impl_client_v17__getaddednodeinfo!( ) ;
73
73
crate :: impl_client_v17__getnettotals!( ) ;
74
74
crate :: impl_client_v17__getnetworkinfo!( ) ;
75
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
75
76
crate :: impl_client_v17__getpeerinfo!( ) ;
76
77
77
78
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -73,6 +73,7 @@ crate::impl_client_v17__submitblock!();
73
73
crate :: impl_client_v17__getaddednodeinfo!( ) ;
74
74
crate :: impl_client_v17__getnettotals!( ) ;
75
75
crate :: impl_client_v17__getnetworkinfo!( ) ;
76
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
76
77
crate :: impl_client_v17__getpeerinfo!( ) ;
77
78
78
79
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -74,6 +74,7 @@ crate::impl_client_v17__submitblock!();
74
74
crate :: impl_client_v17__getaddednodeinfo!( ) ;
75
75
crate :: impl_client_v17__getnettotals!( ) ;
76
76
crate :: impl_client_v17__getnetworkinfo!( ) ;
77
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
77
78
crate :: impl_client_v17__getpeerinfo!( ) ;
78
79
79
80
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ crate::impl_client_v17__submitblock!();
71
71
crate :: impl_client_v17__getaddednodeinfo!( ) ;
72
72
crate :: impl_client_v17__getnettotals!( ) ;
73
73
crate :: impl_client_v17__getnetworkinfo!( ) ;
74
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
74
75
crate :: impl_client_v17__getpeerinfo!( ) ;
75
76
76
77
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ crate::impl_client_v17__submitblock!();
71
71
crate :: impl_client_v17__getaddednodeinfo!( ) ;
72
72
crate :: impl_client_v17__getnettotals!( ) ;
73
73
crate :: impl_client_v17__getnetworkinfo!( ) ;
74
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
74
75
crate :: impl_client_v17__getpeerinfo!( ) ;
75
76
76
77
// == Rawtransactions ==
Original file line number Diff line number Diff line change @@ -76,6 +76,7 @@ crate::impl_client_v17__submitblock!();
76
76
crate :: impl_client_v17__getaddednodeinfo!( ) ;
77
77
crate :: impl_client_v17__getnettotals!( ) ;
78
78
crate :: impl_client_v17__getnetworkinfo!( ) ;
79
+ crate :: impl_client_v18__getnodeaddresses!( ) ;
79
80
crate :: impl_client_v17__getpeerinfo!( ) ;
80
81
81
82
// == Rawtransactions ==
You can’t perform that action at this time.
0 commit comments