MCPcopy Index your code
hub / github.com/SLiCAP/SLiCAP_python / checkCircuit

Method checkCircuit

SLiCAP/SLiCAPinstruction.py:1663–1678  ·  view source on GitHub ↗

Checks if the circuit for this instruction is a :class:`SLiCAPprotos.circuit()` object. Called by **instruction.execute()**.

(self)

Source from the content-addressed store, hash-verified

1661 return
1662
1663 def checkCircuit(self):
1664 """
1665 Checks if the circuit for this instruction is a :class:`SLiCAPprotos.circuit()` object.
1666
1667 Called by **instruction.execute()**.
1668 """
1669 if self.circuit == None:
1670 self.errors += 1
1671 print("Error: missing circuit definition.")
1672 elif type(self.circuit.params) == dict:
1673 self.errors += 1
1674 print("Error: empty circuit object for this instruction.")
1675 elif type(self.circuit) != type(circuit()):
1676 self.errors += 1
1677 print("Error: not SLiCAP a circuit object for this instruction.")
1678 return
1679
1680 def _checkNumeric(self):
1681 """

Callers 1

checkMethod · 0.95

Calls 1

circuitClass · 0.90

Tested by

no test coverage detected