Struct solana_sdk::transaction::VersionedTransaction
source · [−]pub struct VersionedTransaction {
pub signatures: Vec<Signature>,
pub message: VersionedMessage,
}
Expand description
An atomic transaction
Fields
signatures: Vec<Signature>
List of signatures
message: VersionedMessage
Message to sign.
Implementations
sourceimpl VersionedTransaction
impl VersionedTransaction
sourcepub fn try_new<T: Signers>(
message: VersionedMessage,
keypairs: &T
) -> Result<Self, SignerError>
pub fn try_new<T: Signers>(
message: VersionedMessage,
keypairs: &T
) -> Result<Self, SignerError>
Signs a versioned message and if successful, returns a signed transaction.
sourcepub fn version(&self) -> TransactionVersion
pub fn version(&self) -> TransactionVersion
Returns the version of the transaction
sourcepub fn into_legacy_transaction(self) -> Option<Transaction>
pub fn into_legacy_transaction(self) -> Option<Transaction>
Returns a legacy transaction if the transaction message is legacy.
sourcepub fn verify_and_hash_message(&self) -> Result<Hash>
pub fn verify_and_hash_message(&self) -> Result<Hash>
Verify the transaction and hash its message
Trait Implementations
sourceimpl AbiExample for VersionedTransaction
impl AbiExample for VersionedTransaction
sourceimpl Clone for VersionedTransaction
impl Clone for VersionedTransaction
sourcefn clone(&self) -> VersionedTransaction
fn clone(&self) -> VersionedTransaction
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for VersionedTransaction
impl Debug for VersionedTransaction
sourceimpl Default for VersionedTransaction
impl Default for VersionedTransaction
sourcefn default() -> VersionedTransaction
fn default() -> VersionedTransaction
Returns the “default value” for a type. Read more
sourceimpl<'de> Deserialize<'de> for VersionedTransaction
impl<'de> Deserialize<'de> for VersionedTransaction
sourcefn 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
sourceimpl From<Transaction> for VersionedTransaction
impl From<Transaction> for VersionedTransaction
sourcefn from(transaction: Transaction) -> Self
fn from(transaction: Transaction) -> Self
Converts to this type from the input type.
sourceimpl PartialEq<VersionedTransaction> for VersionedTransaction
impl PartialEq<VersionedTransaction> for VersionedTransaction
sourcefn eq(&self, other: &VersionedTransaction) -> bool
fn eq(&self, other: &VersionedTransaction) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &VersionedTransaction) -> bool
fn ne(&self, other: &VersionedTransaction) -> bool
This method tests for !=
.
sourceimpl Sanitize for VersionedTransaction
impl Sanitize for VersionedTransaction
fn sanitize(&self) -> Result<(), SanitizeError>
sourceimpl Serialize for VersionedTransaction
impl Serialize for VersionedTransaction
impl Eq for VersionedTransaction
impl StructuralEq for VersionedTransaction
impl StructuralPartialEq for VersionedTransaction
Auto Trait Implementations
impl RefUnwindSafe for VersionedTransaction
impl Send for VersionedTransaction
impl Sync for VersionedTransaction
impl Unpin for VersionedTransaction
impl UnwindSafe for VersionedTransaction
Blanket Implementations
sourceimpl<T> AbiEnumVisitor for T where
T: Serialize + ?Sized,
impl<T> AbiEnumVisitor for T where
T: Serialize + ?Sized,
default fn visit_for_abi(
&self,
_digester: &mut AbiDigester
) -> Result<AbiDigester, DigestError>
sourceimpl<T> AbiEnumVisitor for T where
T: Serialize + AbiExample + ?Sized,
impl<T> AbiEnumVisitor for T where
T: Serialize + AbiExample + ?Sized,
default fn visit_for_abi(
&self,
digester: &mut AbiDigester
) -> Result<AbiDigester, DigestError>
sourceimpl<T> AbiExample for T
impl<T> AbiExample for T
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more