

Functions | |
| Error | mqss::qrmci::toQrmciError (Error::Kind kind, const mqss::submitter::Error &error) |
| Wrap a submitter failure as a QRM&CI failure of a kind the caller names. | |
| mqss::CircuitFormat | mqss::qrmci::mapProtoCircuitFormat (int format) noexcept |
| Translate a raw circuit-format value received over the wire into a mqss::CircuitFormat. | |
| mqss::BackendType | mqss::qrmci::mapProtoBackendType (int type) noexcept |
| Translate a raw backend-type value received over the wire into a mqss::BackendType, the same way mapProtoCircuitFormat() handles circuit formats: an enumerator this build does not know becomes BACKEND_TYPE_UNSPECIFIED rather than an out-of-range value. | |
| mqss::BackendStatus | mqss::qrmci::mapProtoBackendStatus (int status) noexcept |
| Translate a raw backend-status value received over the wire into a mqss::BackendStatus, the same way mapProtoCircuitFormat() handles circuit formats: an enumerator this build does not know becomes BACKEND_STATUS_UNSPECIFIED – and therefore not online – rather than an out-of-range value. | |
| std::expected< mqss::mqssci::OptLevel, Error > | mqss::qrmci::getCompilerOptimizationLevel (int level) |
| Translate a task's requested optimisation level into the matching mqss-ci compiler optimisation level. | |
| bool | mqss::qrmci::isOnlineBackendStatus (mqss::BackendStatus status) noexcept |
| Check whether a backend status means the backend is able to accept tasks. | |
| std::string | mqss::qrmci::circuitFormatLabel (mqss::CircuitFormat format) |
| Name a circuit format for a log line. | |
| std::string | mqss::qrmci::backendStatusLabel (mqss::BackendStatus status) |
| Name a backend status for a log line. | |
Pure translations between the submitter, mqss protocol and mqss-ci enumerations: status, optimisation level, and wire-format decoding.
The tables themselves are private to src/ConstantsMapping.cpp; these functions are the whole interface. Task/compiler/backend circuit-format admission policy lives in CircuitFormatPolicy.h instead – that is policy, not translation.
No QDMI type appears here. QDMI translation belongs to MQSS-Submitter, behind its Client/Device/Job interface, which is what keeps QDMI out of every QRM&CI public header.
Definition in file ConstantsMapping.h.
|
nodiscard |
Name a backend status for a log line.
| status | The backend status to describe. |
status is not a known enumerator.
|
nodiscard |
Name a circuit format for a log line.
| format | The circuit format to describe. |
format is not a known enumerator – the same case mapProtoCircuitFormat() normalizes away before this ever sees it, kept here only so a raw value logged before normalization still reads clearly.
|
nodiscard |
Translate a task's requested optimisation level into the matching mqss-ci compiler optimisation level.
0 and 1 both select O1 – proto3's implicit zero for an omitted field must not be mistaken for a request to maximize optimisation.
| level | The optimisation level requested on the QuantumTask. |
level if it is outside 0-3.
|
nodiscardnoexcept |
Check whether a backend status means the backend is able to accept tasks.
| status | The backend status to check. |
|
nodiscardnoexcept |
Translate a raw backend-status value received over the wire into a mqss::BackendStatus, the same way mapProtoCircuitFormat() handles circuit formats: an enumerator this build does not know becomes BACKEND_STATUS_UNSPECIFIED – and therefore not online – rather than an out-of-range value.
| status | The raw backend-status value as carried in the message. |
status is not a known enumerator.
|
nodiscardnoexcept |
Translate a raw backend-type value received over the wire into a mqss::BackendType, the same way mapProtoCircuitFormat() handles circuit formats: an enumerator this build does not know becomes BACKEND_TYPE_UNSPECIFIED rather than an out-of-range value.
| type | The raw backend-type value as carried in the message. |
type is not a known enumerator.
|
nodiscardnoexcept |
Translate a raw circuit-format value received over the wire into a mqss::CircuitFormat.
protobuf preserves unknown enum values as their raw integer, so a peer built against a newer protocol can hand us an enumerator this build does not know; this is the only supported way to turn such a value into a mqss::CircuitFormat.
| format | The raw circuit-format value as carried in the message. |
format is not a known enumerator.
|
nodiscard |
Wrap a submitter failure as a QRM&CI failure of a kind the caller names.
The submitter's ErrorCode is deliberately generic – it cannot distinguish a refused submission from a device fault – so the caller, which knows what it was trying to do, supplies the Kind. This function only formats the detail: the error code's own name followed by the submitter's message.
| kind | The QRM&CI error kind this failure should carry. |
| error | The submitter error to wrap. |
kind, detailing error.