pub struct CardanoSignTransactionRequest {
pub network: i32,
pub inputs: Vec<Input>,
pub outputs: Vec<Output>,
pub fee: u64,
pub ttl: u64,
pub certificates: Vec<Certificate>,
pub withdrawals: Vec<Withdrawal>,
pub validity_interval_start: u64,
pub allow_zero_ttl: bool,
pub tag_cbor_sets: bool,
}
Expand description
Max allowed transaction size is 16384 bytes according to https://github.com/cardano-foundation/CIPs/blob/master/CIP-0009/CIP-0009.md. Unlike with BTC, we can fit the whole request in RAM and don’t need to stream.
Fields§
§network: i32
§inputs: Vec<Input>
§outputs: Vec<Output>
§fee: u64
§ttl: u64
§certificates: Vec<Certificate>
§withdrawals: Vec<Withdrawal>
§validity_interval_start: u64
§allow_zero_ttl: bool
include ttl even if it is zero
tag_cbor_sets: bool
Tag arrays in the transaction serialization with the 258 tag. See https://github.com/IntersectMBO/cardano-ledger/blob/6e2d37cc0f47bd02e89b4ce9f78b59c35c958e96/eras/conway/impl/cddl-files/extra.cddl#L5
Implementations§
Source§impl CardanoSignTransactionRequest
impl CardanoSignTransactionRequest
Sourcepub fn network(&self) -> CardanoNetwork
pub fn network(&self) -> CardanoNetwork
Returns the enum value of network
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_network(&mut self, value: CardanoNetwork)
pub fn set_network(&mut self, value: CardanoNetwork)
Sets network
to the provided enum value.
Trait Implementations§
Source§impl Clone for CardanoSignTransactionRequest
impl Clone for CardanoSignTransactionRequest
Source§fn clone(&self) -> CardanoSignTransactionRequest
fn clone(&self) -> CardanoSignTransactionRequest
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Message for CardanoSignTransactionRequest
impl Message for CardanoSignTransactionRequest
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self
. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self
.Source§impl PartialEq for CardanoSignTransactionRequest
impl PartialEq for CardanoSignTransactionRequest
Source§fn eq(&self, other: &CardanoSignTransactionRequest) -> bool
fn eq(&self, other: &CardanoSignTransactionRequest) -> bool
Tests for
self
and other
values to be equal, and is used by ==
.impl StructuralPartialEq for CardanoSignTransactionRequest
Auto Trait Implementations§
impl Freeze for CardanoSignTransactionRequest
impl RefUnwindSafe for CardanoSignTransactionRequest
impl Send for CardanoSignTransactionRequest
impl Sync for CardanoSignTransactionRequest
impl Unpin for CardanoSignTransactionRequest
impl UnwindSafe for CardanoSignTransactionRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more