Apply the swap operation to the qubits in the register.
| C# | Visual Basic | Visual C++ |
public IQuantumRegister OperationSwap()
Public Function OperationSwap As IQuantumRegister
public: virtual IQuantumRegister^ OperationSwap() sealed
A reference to this register after the operation has been applied.
| Exception | Condition |
|---|---|
| SizeMismatchException | Thrown if the register does not
contain two qubits. |
| DuplicateIndexesException | Thrown if the indexes specified
refer to the same qubit. |