DEENESPTFRRUARHIKOZHNL

class ara::com::e2e::ComE2EException

[SWS_CM_12501] Upstream: RS_AP_00122, RS_AP_00127, RS_AP_00130

class ComE2EException final :            public ara::core::Exception {...};

Defines a class for exceptions to be thrown by the E2E APIs

Header-Datei#include "ara/com/e2e/e2e_error_domain.h"
Forwarding-Header#include "ara/com/com_fwd.h"
Scopenamespace ara::com::e2e
Basisklasse(n)ara::core::Exception

User GuideAI-GENERATED

Serves as a specific C++ exception for signaling errors from End-to-End interfaces along with an error code.
AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 385c2dd6528b Provenance Open questions (2)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

Serves as a specific C++ exception for signaling errors from End-to-End interfaces along with an error code.

The class ara::com::e2e::ComE2EException serves as a standardized C++ exception for reporting errors from the E2E APIs of communication management ([SWS_CM_12501]). It derives from ara::core::Exception and encapsulates a specific ara::core::ErrorCode passed during instantiation via an exception-safe noexcept constructor ([SWS_CM_12502]). If C++ exceptions are disabled in the compiler toolchain, the triggering function does not participate in overload resolution according to the specification, so this error path requires active exception support.

Context

The class ara::com::e2e::ComE2EException serves as a standardized C++ exception class thrown by the End-to-End (E2E) APIs in communication management to signal error conditions that have occurred ([SWS_CM_12501], AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”). The class is declared as final and derives publicly from ara::core::Exception (AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”). It is provided via the header file ara/com/e2e/e2e_error_domain.h ([SWS_CM_12502]).

Within the functional architecture of AUTOSAR Adaptive, ComE2EException acts as a communication bridge between the platform's E2E monitoring routines and the calling application software. If an E2E function detects an error state during the checking or processing of data, this error is transmitted to the higher-level control flow by throwing this exception (AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”).

Lifecycle

The instantiation of an object of ComE2EException is performed explicitly by passing an error code to constructor explicit ComE2EException(ara::core::ErrorCode errorCode) noexcept ([SWS_CM_12502], AUTOSAR_AP_SWS_CommunicationManagement §8.15.4.1.1.1 “ComE2EException”). The constructor is specified as noexcept and exception-safe (exception safe) ([SWS_CM_12502]). This guarantees that no further exceptions can be thrown during the construction of the exception itself, which ensures robustness in the error path.

Regarding ownership, the exception is created by the triggering E2E interface and thrown by value (AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”). On the application side, the object is typically caught by const reference. As soon as the corresponding handler block is exited, automatic destruction takes place as part of regular C++ stack unwinding. Because the class is defined as final, no subclasses are intended.

Usage Path

The typical sequence when using the exception is divided into the following phases:

  • The application software calls an E2E-protected function of communication management.
  • During data processing or checking, the E2E logic detects an error, instantiates an instance of ara::com::e2e::ComE2EException with the specific errorCode, and throws it (AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”).
  • The application catches the exception in a try-catch block. Callers are likely (interpretation) to access the inherited base methods of ara::core::Exception here in order to evaluate the contained ara::core::ErrorCode for error diagnostics. Question Q-8dfac2428f223afe (open)
Sequence of exception handling for E2E errorsApplicationara::com E2E-APIComE2EExceptionCall E2E-checked operationUse Case: Error case E2E checkoptC++ Exceptions aktiviertComE2EException(errorCode) instanziierenthrow ComE2EExceptionCatch exception and evaluate error code

Sequence diagram: Flow of error handling when E2E errors occur via ComE2EException. Sources: [SWS_CM_12501], [SWS_CM_12502], AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”.

Error Scenarios

For the use of ComE2EException, an essential precondition applies regarding the toolchain: according to [SWS_CORE_10304], the function that creates and throws the instance does not participate in overload resolution if C++ exceptions are disabled in the compiler (AUTOSAR_AP_SWS_CommunicationManagement §8.15.4 “Class: ComE2EException”). In runtime environments without C++ exception support, this signaling path therefore does not exist; in this case, errors are presumably (interpretation) transmitted via alternative, non-exception-based platform error mechanisms. Question Q-e1b3f4f1dfc191ef (open)

Provided exceptions are active, each ComE2EException mandatorily carries an error code ([SWS_CM_12502]). As a precondition for instantiation, a valid ara::core::ErrorCode must be available ([SWS_CM_12502]). Since the constructor is declared as exception-safe ([SWS_CM_12502]), object creation itself cannot fail even in an error case.

This guide is based on the AUTOSAR specification R25-11 and was automatically curated.

UML class diagram

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

G nara__com__e2e__ComE2EException703 ComE2EException + ComE2EException() nara__core__Exception792 Exception nara__com__e2e__ComE2EException703->nara__core__Exception792 nstd__exception10 std::exception nara__core__Exception792->nstd__exception10

Constructors and destructor

Constructs a new ara::com::e2e::ComE2EException object containing an error code

explicit ComE2EException (ara::core::ErrorCode errorCode) noexcept;

Method documentation

function ComE2EException [SWS_CM_12502] Upstream: RS_AP_00120, RS_AP_00121, RS_AP_00130

explicit ComE2EException (ara::core::ErrorCode errorCode) noexcept;

Constructs a new ara::com::e2e::ComE2EException object containing an error code

Header-Datei#include "ara/com/e2e/e2e_error_domain.h"
Scopeclass ara::com::e2e::ComE2EException
Exception-Sicherheitexception safe

Parameter (in)

ParameterBeschreibung
errorCodeThe error code.

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

Record
AUTOSAR/AP/record/SWS_CM_12502
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_12502@rel:R25-11#e593e160
Content hash
e593e160
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_12502
Status: valid/unmigrated Version: rel:R25-11#f55f1c7d Versionshistorie & Revisions (1 transition, 5 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_CM_12502@rel:R25-11#f55f1c7d
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#e593e1602026-09-30
  • R22-11rel:R22-11#803783f82026-10-14
  • R23-11rel:R23-11#0ff65df22026-10-14
  • R24-11rel:R24-11#eaa1533d2026-10-14
  • R25-11rel:R25-11#f55f1c7d2026-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