pub trait CommandTrait<N: Network>:
Clone
+ Parser
+ FromBytes
+ ToBytes {
// Required methods
fn destinations(&self) -> Vec<Register<N>>;
fn branch_to(&self) -> Option<&Identifier<N>>;
fn position(&self) -> Option<&Identifier<N>>;
fn is_call(&self) -> bool;
fn is_cast_to_record(&self) -> bool;
fn is_write(&self) -> bool;
}
Required Methods§
Sourcefn destinations(&self) -> Vec<Register<N>>
fn destinations(&self) -> Vec<Register<N>>
Returns the destination registers of the command.
Sourcefn branch_to(&self) -> Option<&Identifier<N>>
fn branch_to(&self) -> Option<&Identifier<N>>
Returns the branch target, if the command is a branch command.
Sourcefn position(&self) -> Option<&Identifier<N>>
fn position(&self) -> Option<&Identifier<N>>
Returns the position name, if the command is a position command.
Sourcefn is_cast_to_record(&self) -> bool
fn is_cast_to_record(&self) -> bool
Returns true
if the command is a cast to record instruction.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.