Struct ledger_mob_apdu::tx::TxHeader
source · pub struct TxHeader {
pub state: TxState,
pub value: u16,
pub digest: Digest,
}
Expand description
Header shared between TX response APDUs
Encoding:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TX_STATE | VALUE |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| |
| TX_DIGEST |
| 32-byte rolling checksum |
| |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Fields§
§state: TxState
Current transaction engine state
value: u16
Value associated with current state (zero otherwise)
digest: Digest
Transaction state digest
Trait Implementations§
source§impl PartialEq<TxHeader> for TxHeader
impl PartialEq<TxHeader> for TxHeader
impl StructuralPartialEq for TxHeader
Auto Trait Implementations§
impl RefUnwindSafe for TxHeader
impl Send for TxHeader
impl Sync for TxHeader
impl Unpin for TxHeader
impl UnwindSafe for TxHeader
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
§impl<'a, T> DecodeExt<'a> for Twhere
T: Decode<'a>,
impl<'a, T> DecodeExt<'a> for Twhere T: Decode<'a>,
§fn decode_iter(buff: &'a [u8]) -> DecodeIter<'a, Self::Output>
fn decode_iter(buff: &'a [u8]) -> DecodeIter<'a, Self::Output>
Helper to iterate over decodable objects in a sized buffer. Read more