DEENESPTFRRUARHIKOZHNL

class ara::diag::DiagSovdException

[SWS_DM_01807] Upstream: RS_AP_00119

class DiagSovdException :           public ara::core::Exception {...};

Exception type for SOVD thrown by Diag classes.

Header-Datei#include "ara/diag/diag_sovd_error_domain.h"
Forwarding-Header#include "ara/diag/diag_fwd.h"
Scopenamespace ara::diag
Basisklasse(n)ara::core::Exception

User GuideAI-GENERATED

Signals SOVD-specific diagnostic errors as an exception-safe exception with an associated error code to callers.
AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 58783cae6416 Provenance Open questions (2)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

Signals SOVD-specific diagnostic errors as an exception-safe exception with an associated error code to callers.

The class ara::diag::DiagSovdException serves as a specialized exception type for Service-Oriented Vehicle Diagnostics (SOVD) and is thrown by diagnostic classes in module diag for error signaling [SWS_DM_01807]. It derives from ara::core::Exception and is explicitly instantiated with a ara::core::ErrorCode in error situations to transmit error information to the calling context via C++ stack unwinding [SWS_DM_01808]. As a central constraint, the constructor is specified as noexcept, thereby ensuring full exception safety as well as thread safety during object creation.

Context

The class ara::diag::DiagSovdException represents the central exception type for Service-Oriented Vehicle Diagnostics (SOVD) in the diagnostic module of the AUTOSAR Adaptive Platform ([SWS_DM_01807], SWS Diagnostics §8.51.4 “Class: DiagSovdException”). It is thrown by internal diagnostic classes to indicate specific error conditions during the processing of SOVD requests ([SWS_DM_01807], SWS Diagnostics, p. 69).

The class derives publicly from the general base exception ara::core::Exception ([SWS_DM_01807], SWS Diagnostics §8.51.4). Its direct interaction partners include functional diagnostic classes of the module diag, which analyze diagnostic requests and throw exceptions on errors, as well as the calling application software, which must catch and process such exceptions. The class is declared in header ara/diag/diag_sovd_error_domain.h to fulfill higher-level architectural requirements ([SWS_DM_01808], SWS Diagnostics §8.51.4.1.1.1 “DiagSovdException”).

Lifecycle

Instantiation of ara::diag::DiagSovdException is performed via a constructor that mandatorily accepts a ara::core::ErrorCode as parameter err ([SWS_DM_01808], SWS Diagnostics §8.51.4.1.1.1). This constructor is declared as explicit to prevent implicit conversions from error codes to exception objects and is marked as noexcept ([SWS_DM_01808]).

Regarding robustness and concurrency, the specification guarantees that construction is fully exception-safe (exception safe) and thread-safe ([SWS_DM_01808]). This guarantees that the error creation itself causes no further exceptions or inconsistencies, even in concurrent diagnostic scenarios. The life cycle of the exception follows standard C++ stack unwinding: in case of error, the object is created within a diagnostic function, passed along call levels, and deterministically destroyed upon exiting the handling catch block.

Usage Path

The typical sequence when using ara::diag::DiagSovdException is divided into the following steps:

  • An application initiates an SOVD-related diagnostic operation on an interface of module diag.
  • The responsible diagnostic component detects an erroneous condition and generates an appropriate ara::core::ErrorCode from the SOVD error domain ([SWS_DM_01808]).
  • The component constructs the exception using explicit DiagSovdException(err) and throws it ([SWS_DM_01808], [SWS_DM_01807]).
  • The application catches the exception via catch (const ara::diag::DiagSovdException& ex) or polymorphically via const ara::core::Exception& to react to the error state.
Sequence of exception handling with DiagSovdExceptionApplicationDiagnoseklasseDiagSovdExceptionPerform SOVD diagnostic callSOVD-Fehlerbedingung feststellenara::core::ErrorCode erzeugenDiagSovdException(err) konstruierenthrow DiagSovdExceptioncatch (const DiagSovdException& ex)Analyze and handle error

Sequence diagram: Invocation and handling sequence when throwing a DiagSovdException. Sources: [SWS_DM_01807], [SWS_DM_01808].

Error Scenarios

As an error carrier, the class itself serves to handle exceptional conditions ([SWS_DM_01807]). The formal precondition for creation is the provisioning of an initialized ara::core::ErrorCode ([SWS_DM_01808]). Since the constructor is declared as noexcept, no exceptions occur during object creation itself ([SWS_DM_01808]).

Interpretation: The instance presumably encapsulates the passed error code persistently so that downstream error handlers can inspect it via inherited functions of ara::core::Exception. Question Q-332b95b96849e379 (open) In system configurations with C++ exceptions disabled, the diagnostic component is likely to prefer alternative error mechanisms, whereas DiagSovdException represents the dedicated path for exception handling.

This guide is based on the AUTOSAR Adaptive Platform R25-11 specification and summarizes the requirements for SOVD exception handling.

UML class diagram

Hohle Dreieckspfeile = Vererbung (zeigt zur Basisklasse); Klicken öffnet die jeweilige Klassenseite.

G nara__diag__DiagSovdException335 DiagSovdException + DiagSovdException() nara__core__Exception792 Exception nara__diag__DiagSovdException335->nara__core__Exception792 nstd__exception10 std::exception nara__core__Exception792->nstd__exception10

Constructors and destructor

Construct a new DiagSovdException from an ErrorCode.

explicit DiagSovdException (ara::core::ErrorCode err) noexcept;

Method documentation

function DiagSovdException [SWS_DM_01808] Upstream: RS_AP_00119

explicit DiagSovdException (ara::core::ErrorCode err) noexcept;

Construct a new DiagSovdException from an ErrorCode.

Header-Datei#include "ara/diag/diag_sovd_error_domain.h"
Scopeclass ara::diag::DiagSovdException
Exception-Sicherheitexception safe
Thread-Sicherheitthread-safe

Parameter (in)

ParameterBeschreibung
errthe ErrorCode

Request a governed re-review of this record. The record is not changed immediately.

Record
AUTOSAR/AP/record/SWS_DM_01808
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01808@rel:R25-11#76e1ec2d
Content hash
76e1ec2d
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01808
Status: valid/unmigrated Version: rel:R25-11#e8244057 Versionshistorie & Revisions (1 transition, 4 revision)
Current State
valid/unmigrated
Reason
mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
Campaign
2026-08-13-status-backfill
Active Version
AUTOSAR/AP/record/SWS_DM_01808@rel:R25-11#e8244057
Point-in-Time History:
Recorded Revisions (4):
  • R25-11rel:R25-11#76e1ec2d2026-09-30
  • R23-11rel:R23-11#62167f502026-10-14
  • R24-11rel:R24-11#e82440572026-10-14
  • R25-11rel:R25-11#e82440572026-10-14 active
DateActorTransitionReason / RationaleCampaign
2026-08-13toolnone → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record2026-08-13-status-backfill