Maestro 0.2.11
Unified interface for quantum circuit simulation
Loading...
Searching...
No Matches
qasm::QoperationStatement Struct Reference

#include <SimpleOps.h>

Inheritance diagram for qasm::QoperationStatement:
Collaboration diagram for qasm::QoperationStatement:

Public Types

enum class  OperationType {
  Comment ,
  Declaration ,
  Barrier ,
  Measurement ,
  Reset ,
  OpaqueDecl ,
  GateDecl ,
  Uop ,
  CondUop
}

Public Member Functions

virtual double Eval () const
virtual double Eval (const std::unordered_map< std::string, double > &variables) const

Public Attributes

std::vector< int > cbits
std::string comment
int condValue = 0
IndexedId declaration
std::vector< UopTypedeclOps
Circuits::QuantumGateType gateType = Circuits::QuantumGateType::kNone
OperationType opType = OperationType::Comment
std::vector< double > parameters
std::vector< std::string > paramsDecl
std::vector< int > qubits
std::vector< std::string > qubitsDecl

Detailed Description

Definition at line 72 of file SimpleOps.h.

Member Enumeration Documentation

◆ OperationType

Enumerator
Comment 
Declaration 
Barrier 
Measurement 
Reset 
OpaqueDecl 
GateDecl 
Uop 
CondUop 

Definition at line 73 of file SimpleOps.h.

Member Function Documentation

◆ Eval() [1/2]

virtual double qasm::AbstractSyntaxTree::Eval ( ) const
inlinevirtualinherited

◆ Eval() [2/2]

virtual double qasm::AbstractSyntaxTree::Eval ( const std::unordered_map< std::string, double > & variables) const
inlinevirtualinherited

Member Data Documentation

◆ cbits

std::vector<int> qasm::QoperationStatement::cbits

◆ comment

std::string qasm::QoperationStatement::comment

◆ condValue

int qasm::QoperationStatement::condValue = 0

Definition at line 100 of file SimpleOps.h.

Referenced by qasm::Program::AddToCircuit(), and qasm::AddCondQopExpr::operator()().

◆ declaration

IndexedId qasm::QoperationStatement::declaration

Definition at line 90 of file SimpleOps.h.

Referenced by qasm::AddDeclarationExpr::operator()().

◆ declOps

std::vector<UopType> qasm::QoperationStatement::declOps

Definition at line 101 of file SimpleOps.h.

Referenced by qasm::Program::AddToCircuit(), and qasm::AddGateDeclExpr::operator()().

◆ gateType

Circuits::QuantumGateType qasm::QoperationStatement::gateType = Circuits::QuantumGateType::kNone

Definition at line 86 of file SimpleOps.h.

Referenced by qasm::Program::AddToCircuit().

◆ opType

◆ parameters

std::vector<double> qasm::QoperationStatement::parameters

Definition at line 95 of file SimpleOps.h.

Referenced by qasm::Program::AddToCircuit().

◆ paramsDecl

std::vector<std::string> qasm::QoperationStatement::paramsDecl

◆ qubits

std::vector<int> qasm::QoperationStatement::qubits

◆ qubitsDecl

std::vector<std::string> qasm::QoperationStatement::qubitsDecl

The documentation for this struct was generated from the following file: