traits.rs 200 B

12345678
  1. use gate::Gate;
  2. pub trait Backend {
  3. fn apply_gate(&mut self, gate: Gate, target: u8);
  4. fn apply_controlled_gate(&mut self, gate: Gate, control: u8, target: u8);
  5. fn measure(&self) -> u8;
  6. }