Maestro 0.2.5
Unified interface for quantum circuit simulation
Loading...
Searching...
No Matches
qasm::Constant Class Reference

#include <Expr.h>

+ Inheritance diagram for qasm::Constant:
+ Collaboration diagram for qasm::Constant:

Public Member Functions

 Constant (double value=0)
 
 Constant (int value)
 
double Eval () const override
 
double Eval (const std::unordered_map< std::string, double > &variables) const override
 
Constantoperator= (double value)
 
Constantoperator= (int value)
 

Detailed Description

Definition at line 68 of file Expr.h.

Constructor & Destructor Documentation

◆ Constant() [1/2]

qasm::Constant::Constant ( double  value = 0)
inline

Definition at line 70 of file Expr.h.

◆ Constant() [2/2]

qasm::Constant::Constant ( int  value)
inline

Definition at line 71 of file Expr.h.

Member Function Documentation

◆ Eval() [1/2]

double qasm::Constant::Eval ( ) const
inlineoverridevirtual

Reimplemented from qasm::AbstractSyntaxTree.

Definition at line 82 of file Expr.h.

◆ Eval() [2/2]

double qasm::Constant::Eval ( const std::unordered_map< std::string, double > &  variables) const
inlineoverridevirtual

Reimplemented from qasm::AbstractSyntaxTree.

Definition at line 83 of file Expr.h.

◆ operator=() [1/2]

Constant & qasm::Constant::operator= ( double  value)
inline

Definition at line 77 of file Expr.h.

◆ operator=() [2/2]

Constant & qasm::Constant::operator= ( int  value)
inline

Definition at line 73 of file Expr.h.


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