Struct redgold_schema::structs::TransactionInfo
source · pub struct TransactionInfo {
pub transaction: Option<Transaction>,
pub observation_proofs: Vec<ObservationProof>,
pub valid_utxo_index: Vec<i32>,
pub used_outputs: Vec<UsedOutputs>,
pub accepted: bool,
pub rejection_reason: Option<ErrorInfo>,
pub queried_output_index_valid: Option<bool>,
pub state: i32,
}Fields§
§transaction: Option<Transaction>§observation_proofs: Vec<ObservationProof>§valid_utxo_index: Vec<i32>Which output indexes are still considered valid.
used_outputs: Vec<UsedOutputs>In order to calculate this quantity, we need another index to determine if something has been used.
accepted: bool§rejection_reason: Option<ErrorInfo>§queried_output_index_valid: Option<bool>Move this outside to the class / request that requires it for resolving.
state: i32Implementations§
source§impl TransactionInfo
impl TransactionInfo
sourcepub fn queried_output_index_valid(&self) -> bool
pub fn queried_output_index_valid(&self) -> bool
Returns the value of queried_output_index_valid, or the default value if queried_output_index_valid is unset.
sourcepub fn state(&self) -> TransactionState
pub fn state(&self) -> TransactionState
Returns the enum value of state, or the default if the field is set to an invalid enum value.
sourcepub fn set_state(&mut self, value: TransactionState)
pub fn set_state(&mut self, value: TransactionState)
Sets state to the provided enum value.
Trait Implementations§
source§impl Clone for TransactionInfo
impl Clone for TransactionInfo
source§fn clone(&self) -> TransactionInfo
fn clone(&self) -> TransactionInfo
Returns a copy 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 Debug for TransactionInfo
impl Debug for TransactionInfo
source§impl Default for TransactionInfo
impl Default for TransactionInfo
source§impl<'de> Deserialize<'de> for TransactionInfo
impl<'de> Deserialize<'de> for TransactionInfo
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Hash for TransactionInfo
impl Hash for TransactionInfo
source§impl Message for TransactionInfo
impl Message for TransactionInfo
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<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, 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<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, 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<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
Decodes an instance of the message from a buffer. Read more
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
Decodes a length-delimited instance of the message from the buffer.
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.source§impl PartialEq for TransactionInfo
impl PartialEq for TransactionInfo
source§fn eq(&self, other: &TransactionInfo) -> bool
fn eq(&self, other: &TransactionInfo) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl Serialize for TransactionInfo
impl Serialize for TransactionInfo
impl Eq for TransactionInfo
impl StructuralEq for TransactionInfo
impl StructuralPartialEq for TransactionInfo
Auto Trait Implementations§
impl RefUnwindSafe for TransactionInfo
impl Send for TransactionInfo
impl Sync for TransactionInfo
impl Unpin for TransactionInfo
impl UnwindSafe for TransactionInfo
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