stellar_xdr/curr/
transaction_conversions.rs1use super::{
2 FeeBumpTransaction, FeeBumpTransactionEnvelope, Transaction, TransactionEnvelope,
3 TransactionV1Envelope, VecM,
4};
5
6impl From<Transaction> for TransactionEnvelope {
7 fn from(tx: Transaction) -> Self {
8 TransactionEnvelope::Tx(TransactionV1Envelope {
9 tx,
10 signatures: VecM::default(),
11 })
12 }
13}
14
15impl From<FeeBumpTransaction> for TransactionEnvelope {
16 fn from(tx: FeeBumpTransaction) -> Self {
17 TransactionEnvelope::TxFeeBump(FeeBumpTransactionEnvelope {
18 tx,
19 signatures: VecM::default(),
20 })
21 }
22}
23
24impl From<&FeeBumpTransaction> for TransactionEnvelope {
25 fn from(tx: &FeeBumpTransaction) -> Self {
26 tx.clone().into()
27 }
28}
29
30impl From<&Transaction> for TransactionEnvelope {
31 fn from(tx: &Transaction) -> Self {
32 tx.clone().into()
33 }
34}