File tree Expand file tree Collapse file tree 14 files changed +65
-2
lines changed Expand file tree Collapse file tree 14 files changed +65
-2
lines changed Original file line number Diff line number Diff line change @@ -130,6 +130,7 @@ crate::impl_client_v17__backupwallet!();
130
130
crate :: impl_client_v17__encryptwallet!( ) ;
131
131
crate :: impl_client_v17__importaddress!( ) ;
132
132
crate :: impl_client_v17__importprivkey!( ) ;
133
+ crate :: impl_client_v17__importprunedfunds!( ) ;
133
134
134
135
/// Argument to the `Client::get_new_address_with_type` function.
135
136
///
Original file line number Diff line number Diff line change @@ -573,3 +573,26 @@ macro_rules! impl_client_v17__importaddress {
573
573
}
574
574
} ;
575
575
}
576
+
577
+ /// Implements Bitcoin Core JSON-RPC API method `importprunedfunds`
578
+ #[ macro_export]
579
+ macro_rules! impl_client_v17__importprunedfunds {
580
+ ( ) => {
581
+ impl Client {
582
+ pub fn import_pruned_funds(
583
+ & self ,
584
+ raw_transaction: & str ,
585
+ txout_proof: & str ,
586
+ ) -> Result <( ) > {
587
+ match self . call( "importprunedfunds" , & [ raw_transaction. into( ) , txout_proof. into( ) ] ) {
588
+ Ok ( serde_json:: Value :: Null ) => Ok ( ( ) ) ,
589
+ Ok ( ref val) if val. is_null( ) => Ok ( ( ) ) ,
590
+ Ok ( other) => Err ( crate :: client_sync:: Error :: Returned ( format!(
591
+ "importprunedfunds expected null, got: {}" , other
592
+ ) ) ) ,
593
+ Err ( e) => Err ( e. into( ) ) ,
594
+ }
595
+ }
596
+ }
597
+ } ;
598
+ }
Original file line number Diff line number Diff line change @@ -123,3 +123,4 @@ crate::impl_client_v17__backupwallet!();
123
123
crate :: impl_client_v17__encryptwallet!( ) ;
124
124
crate :: impl_client_v17__importaddress!( ) ;
125
125
crate :: impl_client_v17__importprivkey!( ) ;
126
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -125,3 +125,4 @@ crate::impl_client_v17__backupwallet!();
125
125
crate :: impl_client_v17__encryptwallet!( ) ;
126
126
crate :: impl_client_v17__importaddress!( ) ;
127
127
crate :: impl_client_v17__importprivkey!( ) ;
128
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -124,3 +124,4 @@ crate::impl_client_v17__backupwallet!();
124
124
crate :: impl_client_v20__encryptwallet!( ) ;
125
125
crate :: impl_client_v17__importaddress!( ) ;
126
126
crate :: impl_client_v17__importprivkey!( ) ;
127
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -124,3 +124,4 @@ crate::impl_client_v17__backupwallet!();
124
124
crate :: impl_client_v20__encryptwallet!( ) ;
125
125
crate :: impl_client_v17__importaddress!( ) ;
126
126
crate :: impl_client_v17__importprivkey!( ) ;
127
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -125,3 +125,4 @@ crate::impl_client_v17__backupwallet!();
125
125
crate :: impl_client_v20__encryptwallet!( ) ;
126
126
crate :: impl_client_v17__importaddress!( ) ;
127
127
crate :: impl_client_v17__importprivkey!( ) ;
128
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -126,6 +126,7 @@ crate::impl_client_v17__backupwallet!();
126
126
crate :: impl_client_v20__encryptwallet!( ) ;
127
127
crate :: impl_client_v17__importaddress!( ) ;
128
128
crate :: impl_client_v17__importprivkey!( ) ;
129
+ crate :: impl_client_v17__importprunedfunds!( ) ;
129
130
130
131
/// Argument to the `Client::get_new_address_with_type` function.
131
132
///
Original file line number Diff line number Diff line change @@ -122,3 +122,4 @@ crate::impl_client_v17__backupwallet!();
122
122
crate :: impl_client_v20__encryptwallet!( ) ;
123
123
crate :: impl_client_v17__importaddress!( ) ;
124
124
crate :: impl_client_v17__importprivkey!( ) ;
125
+ crate :: impl_client_v17__importprunedfunds!( ) ;
Original file line number Diff line number Diff line change @@ -122,3 +122,4 @@ crate::impl_client_v17__backupwallet!();
122
122
crate :: impl_client_v20__encryptwallet!( ) ;
123
123
crate :: impl_client_v17__importaddress!( ) ;
124
124
crate :: impl_client_v17__importprivkey!( ) ;
125
+ crate :: impl_client_v17__importprunedfunds!( ) ;
You can’t perform that action at this time.
0 commit comments