Struct silk::transaction::Transaction
[−]
[src]
pub struct Transaction<T> { pub from: PublicKey, pub to: PublicKey, pub if_all: Vec<Condition>, pub unless_any: Vec<Condition>, pub asset: T, pub last_id: Hash, pub sig: Signature, }
Fields
from: PublicKey
to: PublicKey
if_all: Vec<Condition>
unless_any: Vec<Condition>
asset: T
last_id: Hash
sig: Signature
Methods
impl<T: Serialize> Transaction<T>
[src]
pub fn new(
from_keypair: &KeyPair,
to: PublicKey,
asset: T,
last_id: Hash
) -> Self
[src]
from_keypair: &KeyPair,
to: PublicKey,
asset: T,
last_id: Hash
) -> Self
pub fn new_on_date(
from_keypair: &KeyPair,
to: PublicKey,
dt: DateTime<Utc>,
asset: T,
last_id: Hash
) -> Self
[src]
from_keypair: &KeyPair,
to: PublicKey,
dt: DateTime<Utc>,
asset: T,
last_id: Hash
) -> Self
pub fn sign(&mut self, keypair: &KeyPair)
[src]
pub fn verify(&self) -> bool
[src]
Trait Implementations
impl<T: Debug> Debug for Transaction<T>
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl<T: PartialEq> PartialEq for Transaction<T>
[src]
fn eq(&self, __arg_0: &Transaction<T>) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Transaction<T>) -> bool
[src]
This method tests for !=
.
impl<T: Eq> Eq for Transaction<T>
[src]
impl<T: Clone> Clone for Transaction<T>
[src]
fn clone(&self) -> Transaction<T>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<T> Send for Transaction<T> where
T: Send,
T: Send,
impl<T> Sync for Transaction<T> where
T: Sync,
T: Sync,