blob: f699d54934a1816b691eaf20513319ec59bfaadb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
use super::{ClassicalRegister, QuantumBit, QuantumCircuit};
#[allow(unused)]
pub struct ExecutationData {
quantum_states: Vec<QuantumBit>,
classical_states: ClassicalRegister,
}
impl ExecutationData {
pub fn new(quantum_states: Vec<QuantumBit>, classical_states: ClassicalRegister) -> Self {
ExecutationData {
quantum_states,
classical_states,
}
}
}
pub trait RuntimeBase {
fn get_circuit(&self) -> &QuantumCircuit;
}
pub trait Runtime<T: RuntimeBase = Self> {
fn new(circuit: QuantumCircuit) -> Self;
fn execute(&self, repeat: usize) -> Vec<ExecutationData>;
}
|