pub struct RawTransactionReader<'r>(/* private fields */);
Implementations§
Source§impl<'r> RawTransactionReader<'r>
impl<'r> RawTransactionReader<'r>
Sourcepub fn calc_tx_hash(&self) -> Byte32
pub fn calc_tx_hash(&self) -> Byte32
Calculates the hash for self.as_slice() as the transaction hash.
Source§impl<'r> RawTransactionReader<'r>
impl<'r> RawTransactionReader<'r>
pub const FIELD_COUNT: usize = 6usize
pub fn total_size(&self) -> usize
pub fn field_count(&self) -> usize
pub fn count_extra_fields(&self) -> usize
pub fn has_extra_fields(&self) -> bool
pub fn version(&self) -> Uint32Reader<'r>
pub fn cell_deps(&self) -> CellDepVecReader<'r>
pub fn header_deps(&self) -> Byte32VecReader<'r>
pub fn inputs(&self) -> CellInputVecReader<'r>
pub fn outputs(&self) -> CellOutputVecReader<'r>
pub fn outputs_data(&self) -> BytesVecReader<'r>
Trait Implementations§
Source§impl<'r> Clone for RawTransactionReader<'r>
impl<'r> Clone for RawTransactionReader<'r>
Source§fn clone(&self) -> RawTransactionReader<'r>
fn clone(&self) -> RawTransactionReader<'r>
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<'r> Debug for RawTransactionReader<'r>
impl<'r> Debug for RawTransactionReader<'r>
Source§impl<'r> Display for RawTransactionReader<'r>
impl<'r> Display for RawTransactionReader<'r>
Source§impl<'r> LowerHex for RawTransactionReader<'r>
impl<'r> LowerHex for RawTransactionReader<'r>
Source§impl<'r> Reader<'r> for RawTransactionReader<'r>
impl<'r> Reader<'r> for RawTransactionReader<'r>
const NAME: &'static str = "RawTransactionReader"
type Entity = RawTransaction
fn to_entity(&self) -> <RawTransactionReader<'r> as Reader<'r>>::Entity
fn new_unchecked(slice: &'r [u8]) -> RawTransactionReader<'r>
fn as_slice(&self) -> &'r [u8] ⓘ
fn verify(slice: &[u8], compatible: bool) -> Result<(), VerificationError>
fn from_slice(slice: &'r [u8]) -> Result<Self, VerificationError>
fn from_compatible_slice(slice: &'r [u8]) -> Result<Self, VerificationError>
impl<'r> Copy for RawTransactionReader<'r>
Auto Trait Implementations§
impl<'r> Freeze for RawTransactionReader<'r>
impl<'r> RefUnwindSafe for RawTransactionReader<'r>
impl<'r> Send for RawTransactionReader<'r>
impl<'r> Sync for RawTransactionReader<'r>
impl<'r> Unpin for RawTransactionReader<'r>
impl<'r> UnwindSafe for RawTransactionReader<'r>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<'r, R> FromSliceShouldBeOk<'r> for Rwhere
R: Reader<'r>,
impl<'r, R> FromSliceShouldBeOk<'r> for Rwhere
R: Reader<'r>,
Source§fn from_slice_should_be_ok(slice: &'r [u8]) -> R
fn from_slice_should_be_ok(slice: &'r [u8]) -> R
Unwraps the result of
from_slice(..)
with confidence and we assume that it’s impossible to fail.Source§fn from_compatible_slice_should_be_ok(slice: &'r [u8]) -> R
fn from_compatible_slice_should_be_ok(slice: &'r [u8]) -> R
Unwraps the result of
from_compatible_slice(..)
with confidence and we assume that it’s impossible to fail.