pub trait GateComposable: GateOp {
// Required methods
fn compose_with(
&self,
other: &dyn GateOp,
) -> QuantRS2Result<Box<dyn GateOp>>;
fn can_compose_with(&self, other: &dyn GateOp) -> bool;
}
Expand description
Trait for gate composition
Required Methods§
Sourcefn compose_with(&self, other: &dyn GateOp) -> QuantRS2Result<Box<dyn GateOp>>
fn compose_with(&self, other: &dyn GateOp) -> QuantRS2Result<Box<dyn GateOp>>
Compose this gate with another gate
Sourcefn can_compose_with(&self, other: &dyn GateOp) -> bool
fn can_compose_with(&self, other: &dyn GateOp) -> bool
Check if this gate can be composed with another gate