Skip to content
This repository was archived by the owner on Nov 26, 2024. It is now read-only.

Commit 9491250

Browse files
committed
f Drop serde stuff from model
1 parent 7041357 commit 9491250

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

json/src/model/raw_transactions.rs

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -8,33 +8,29 @@
88
use std::collections::HashMap;
99

1010
use bitcoin::{Amount, FeeRate, Txid, Wtxid};
11-
use serde::{Deserialize, Serialize};
1211

1312
/// Models the result of JSON-RPC method `sendrawtransaction`.
14-
#[derive(Clone, Debug, PartialEq, Deserialize, Serialize)]
13+
#[derive(Clone, Debug, PartialEq)]
1514
pub struct SendRawTransaction(pub Txid);
1615

17-
#[derive(Clone, Debug, PartialEq, Deserialize, Serialize)]
16+
#[derive(Clone, Debug, PartialEq)]
1817
pub struct SubmitPackage {
1918
/// The transaction package result message. "success" indicates all transactions were accepted into or are already in the mempool.
2019
pub package_msg: String,
2120
/// Transaction results keyed by [`Wtxid`].
22-
#[serde(rename = "tx-results")]
2321
pub tx_results: HashMap<Wtxid, SubmitPackageTxResult>,
2422
/// List of txids of replaced transactions.
25-
#[serde(rename = "replaced-transactions")]
2623
pub replaced_transactions: Vec<Txid>,
2724
}
2825

2926
/// Models the per-transaction result included in the JSON-RPC method `submitpackage`.
30-
#[derive(Clone, Debug, PartialEq, Deserialize, Serialize)]
27+
#[derive(Clone, Debug, PartialEq)]
3128
pub struct SubmitPackageTxResult {
3229
/// The transaction id.
3330
pub txid: Txid,
3431
/// The [`Wtxid`] of a different transaction with the same [`Txid`] but different witness found in the mempool.
3532
///
3633
/// If set, this means the submitted transaction was ignored.
37-
#[serde(rename = "other-wtxid")]
3834
pub other_wtxid: Option<Wtxid>,
3935
/// Sigops-adjusted virtual transaction size.
4036
pub vsize: Option<usize>,
@@ -45,20 +41,17 @@ pub struct SubmitPackageTxResult {
4541
}
4642

4743
/// Models the fees included in the per-transaction result of the JSON-RPC method `submitpackage`.
48-
#[derive(Clone, Debug, PartialEq, Deserialize, Serialize)]
44+
#[derive(Clone, Debug, PartialEq)]
4945
pub struct SubmitPackageTxResultFees {
5046
/// Transaction fee.
51-
#[serde(rename = "base")]
5247
pub base_fee: Amount,
5348
/// The effective feerate.
5449
///
5550
/// Will be `None` if the transaction was already in the mempool.
5651
///
5752
/// For example, the package feerate and/or feerate with modified fees from the `prioritisetransaction` JSON-RPC method.
58-
#[serde(rename = "effective-feerate")]
5953
pub effective_feerate: Option<FeeRate>,
6054
/// If [`Self::effective_feerate`] is provided, this holds the [`Wtxid`]s of the transactions
6155
/// whose fees and vsizes are included in effective-feerate.
62-
#[serde(rename = "effective-includes")]
6356
pub effective_includes: Vec<Wtxid>,
6457
}

0 commit comments

Comments
 (0)