#[repr(C)]pub struct TransactionGeneric<T: ?Sized> {
pub sender: Digest,
pub receiver: HashMap<Digest, f64>,
pub amount: f64,
pub time: i64,
pub body: T,
}Fields§
§sender: Digest§receiver: HashMap<Digest, f64>§amount: f64§time: i64§body: TImplementations§
Source§impl TransactionGeneric<()>
impl TransactionGeneric<()>
pub fn form(&self) -> Transaction
Source§impl TransactionGeneric<TransactionRestricts>
impl TransactionGeneric<TransactionRestricts>
pub fn new(body: &TransactionHeader) -> Transaction
Trait Implementations§
Source§impl Borrow<TransactionGeneric<()>> for Transaction
impl Borrow<TransactionGeneric<()>> for Transaction
Source§fn borrow<'a>(&'a self) -> &'a TransactionHeader
fn borrow<'a>(&'a self) -> &'a TransactionHeader
Immutably borrows from an owned value. Read more
Source§impl BorrowMut<TransactionGeneric<()>> for Transaction
impl BorrowMut<TransactionGeneric<()>> for Transaction
Source§fn borrow_mut<'a>(&'a mut self) -> &'a mut TransactionHeader
fn borrow_mut<'a>(&'a mut self) -> &'a mut TransactionHeader
Mutably borrows from an owned value. Read more
Source§impl<T: Clone + ?Sized> Clone for TransactionGeneric<T>
impl<T: Clone + ?Sized> Clone for TransactionGeneric<T>
Source§fn clone(&self) -> TransactionGeneric<T>
fn clone(&self) -> TransactionGeneric<T>
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<'de, T> Deserialize<'de> for TransactionGeneric<T>where
T: Deserialize<'de> + ?Sized,
impl<'de, T> Deserialize<'de> for TransactionGeneric<T>where
T: Deserialize<'de> + ?Sized,
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
Auto Trait Implementations§
impl<T> Freeze for TransactionGeneric<T>
impl<T> RefUnwindSafe for TransactionGeneric<T>where
T: RefUnwindSafe + ?Sized,
impl<T> Send for TransactionGeneric<T>
impl<T> Sync for TransactionGeneric<T>
impl<T> Unpin for TransactionGeneric<T>
impl<T> UnwindSafe for TransactionGeneric<T>where
T: UnwindSafe + ?Sized,
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