pub struct Transition {
pub ffv: Ffv,
pub contract_id: ContractId,
pub transition_type: u16,
pub metadata: Confined<Vec<u8>, amplify::::collection::confinement::SmallBlob::{constant#0}, amplify::::collection::confinement::SmallBlob::{constant#1}>,
pub globals: GlobalState,
pub inputs: Inputs,
pub assignments: Assignments<BlindSeal<TxPtr>>,
pub valencies: Valencies,
}
Fields§
§ffv: Ffv
§contract_id: ContractId
§transition_type: u16
§metadata: Confined<Vec<u8>, amplify::::collection::confinement::SmallBlob::{constant#0}, amplify::::collection::confinement::SmallBlob::{constant#1}>
§globals: GlobalState
§inputs: Inputs
§assignments: Assignments<BlindSeal<TxPtr>>
§valencies: Valencies
Implementations§
Source§impl Transition
impl Transition
Sourcepub fn prev_state(&self) -> &Inputs
pub fn prev_state(&self) -> &Inputs
Returns reference to information about the owned rights in form of
Inputs
wrapper structure which this operation updates with
state transition (“parent owned rights”).
Trait Implementations§
Source§impl Clone for Transition
impl Clone for Transition
Source§fn clone(&self) -> Transition
fn clone(&self) -> Transition
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 CommitEncode for Transition
impl CommitEncode for Transition
Source§fn commit_encode(&self, e: &mut impl Write)
fn commit_encode(&self, e: &mut impl Write)
Encodes the data for the commitment by writing them directly into a
io::Write
writer instanceSource§impl CommitmentId for Transition
impl CommitmentId for Transition
Source§impl Conceal for Transition
impl Conceal for Transition
Source§type Concealed = Transition
type Concealed = Transition
The resulting confidential type concealing original data.
Source§impl Debug for Transition
impl Debug for Transition
Source§impl<'de> Deserialize<'de> for Transition
impl<'de> Deserialize<'de> for Transition
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Transition, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Transition, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<'op> From<&'op Transition> for OpRef<'op>
impl<'op> From<&'op Transition> for OpRef<'op>
Source§fn from(v: &'op Transition) -> OpRef<'op>
fn from(v: &'op Transition) -> OpRef<'op>
Converts to this type from the input type.
Source§impl Hash for Transition
impl Hash for Transition
Source§impl MergeReveal for Transition
impl MergeReveal for Transition
fn merge_reveal(self, other: Self) -> Result<Self, MergeRevealError>
Source§impl Operation for Transition
impl Operation for Transition
Source§fn op_type(&self) -> OpType
fn op_type(&self) -> OpType
Returns type of the operation (see
OpType
). Unfortunately, this
can’t be just a const, since it will break our ability to convert
concrete Node
types into &dyn Node
(entities implementing traits
with const definitions can’t be made into objects)Source§fn full_type(&self) -> OpFullType
fn full_type(&self) -> OpFullType
Returns full contract operation type information
Source§fn contract_id(&self) -> ContractId
fn contract_id(&self) -> ContractId
Returns
ContractId
this operation belongs to.Source§fn transition_type(&self) -> Option<u16>
fn transition_type(&self) -> Option<u16>
Returns
Option::Some
(
TransitionType
)
for transitions or
Option::None
for genesis and extension operation typesSource§fn extension_type(&self) -> Option<u16>
fn extension_type(&self) -> Option<u16>
Returns
Option::Some
(
ExtensionType
)
for extension nodes or
Option::None
for genesis and state transitionsSource§fn metadata(
&self,
) -> &Confined<Vec<u8>, amplify::::collection::confinement::SmallBlob::{constant#0}, amplify::::collection::confinement::SmallBlob::{constant#1}> ⓘ
fn metadata( &self, ) -> &Confined<Vec<u8>, amplify::::collection::confinement::SmallBlob::{constant#0}, amplify::::collection::confinement::SmallBlob::{constant#1}> ⓘ
Returns metadata associated with the operation, if any.
Source§fn globals(&self) -> &GlobalState
fn globals(&self) -> &GlobalState
Returns reference to a full set of metadata (in form of
GlobalState
wrapper structure) for the contract operation.fn valencies(&self) -> &Valencies
fn assignments(&self) -> AssignmentsRef<'_>
fn assignments_by_type(&self, t: u16) -> Option<TypedAssigns<BlindSeal<TxPtr>>>
Source§impl Ord for Transition
impl Ord for Transition
Source§fn cmp(&self, other: &Transition) -> Ordering
fn cmp(&self, other: &Transition) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for Transition
impl PartialEq for Transition
Source§impl PartialOrd for Transition
impl PartialOrd for Transition
Source§impl Serialize for Transition
impl Serialize for Transition
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl StrictDecode for Transition
impl StrictDecode for Transition
fn strict_decode(reader: &mut impl TypedRead) -> Result<Transition, DecodeError>
fn strict_read(lim: usize, reader: impl Read) -> Result<Self, DecodeError>
Source§impl StrictDeserialize for Transition
impl StrictDeserialize for Transition
fn from_strict_serialized<const MAX: usize>( ast_data: Confined<Vec<u8>, 0, MAX>, ) -> Result<Self, DeserializeError>
fn strict_deserialize_from_file<const MAX: usize>( path: impl AsRef<Path>, ) -> Result<Self, DeserializeError>
Source§impl StrictDumb for Transition
impl StrictDumb for Transition
fn strict_dumb() -> Transition
Source§impl StrictEncode for Transition
impl StrictEncode for Transition
fn strict_encode<W>(&self, writer: W) -> Result<W, Error>where
W: TypedWrite,
fn strict_write(&self, lim: usize, writer: impl Write) -> Result<usize, Error>
Source§impl StrictSerialize for Transition
impl StrictSerialize for Transition
fn strict_serialized_len(&self) -> Result<usize, Error>
fn to_strict_serialized<const MAX: usize>( &self, ) -> Result<Confined<Vec<u8>, 0, MAX>, SerializeError>
fn strict_serialize_to_file<const MAX: usize>( &self, path: impl AsRef<Path>, ) -> Result<(), SerializeError>
Source§impl StrictStruct for Transition
impl StrictStruct for Transition
const ALL_FIELDS: &'static [&'static str]
fn strict_check_fields()
fn strict_type_info() -> TypeInfo<Self>
Source§impl StrictType for Transition
impl StrictType for Transition
const STRICT_LIB_NAME: &'static str = LIB_NAME_RGB
fn strict_name() -> Option<TypeName>
impl Eq for Transition
impl StrictProduct for Transition
impl StructuralPartialEq for Transition
Auto Trait Implementations§
impl Freeze for Transition
impl RefUnwindSafe for Transition
impl Send for Transition
impl Sync for Transition
impl Unpin for Transition
impl UnwindSafe for Transition
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§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.