DEENESPTFRRUARHIKOZHNL

class ara::per::PerErrorDomain

[SWS_PER_00312] Upstream: RS_AP_00122, RS_AP_00127, RS_AP_00140

class PerErrorDomain final :             public ara::core::ErrorDomain {...};

Defines the error domain for Persistency.

Header-Datei#include "ara/per/per_error_domain.h"
Forwarding-Header#include "ara/per/per_fwd.h"
Scopenamespace ara::per
Basisklasse(n)ara::core::ErrorDomain
Unique IDAs per ara::per::PerErrorDomain in [SWS_CORE_90023]

User GuideAI-GENERATED

Defines the error domain of the Persistency module for providing error codes, text descriptions, and exceptions.
AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: da81ed3d3cb6 Provenance Open questions (1)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

Defines the error domain of the Persistency module for providing error codes, text descriptions, and exceptions.

Class ara::per::PerErrorDomain defines the error domain for the Persistency module and links error codes with descriptive messages as well as exception types [SWS_PER_00411]. Via thread-safe interfaces, it enables querying the domain name and resolving error descriptions for concrete error values. When required, it converts errors into C++ exceptions via ThrowAsException() [SWS_PER_00350]. If exceptions are disabled in the compiler toolchain, this throwing function is not available, so error checking must be purely return-value-based.

Context

Class ara::per::PerErrorDomain defines the specific error domain for the Persistency module (Persistency) within the AUTOSAR Adaptive Platform. It inherits from the base type definition ara::core::ErrorDomain and is declared as final, thereby forming the basis for typed error handling and error mapping of all persistency-related operations. Via standardized type aliases Errc [SWS_PER_00411] for the underlying error code enumeration PerErrc as well as Exception [SWS_PER_00412] for the module-specific exception base class PerException, the class links numeric error values, descriptive error messages, and concrete C++ exception objects. In the platform architecture, the error domain interacts closely with the Persistency services, the calling functional clusters, and the generic error and result structures from ara::core.

Lifecycle

An instance is created via the default constructor PerErrorDomain() [SWS_PER_00313]. This constructor is declared as noexcept, fully exception-safe (exception safe), and thread-safe (thread-safe). Interpretation: The instance of PerErrorDomain is likely to be managed typically as a long-lived or global object to ensure consistent domain comparisons and type resolutions for persistence errors throughout operation. Question Q-5d90982fddec40a7 (open) Since all querying operations of the class are likewise classified as thread-safe, multiple threads can access the same domain instance in parallel without requiring additional synchronization mechanisms at the caller level.

Usage Path

A typical usage path comprises identifying the domain, querying comprehensible diagnostic information, and optionally throwing exceptions upon errors occurring in the Persistency module. First, member function Name() returns the unique identifier of the error domain as a string [SWS_PER_00314]; it is specified as noexcept, exception safe, and thread-safe. If an error occurs during a Persistency operation, its numeric error value is resolved via Message() [SWS_PER_00315]. This method accepts the numeric error code of type CodeType and returns the associated error message as a pointer to constant char (const char *), likewise under the guarantee of complete exception safety and thread safety.

If an error state is to be converted into a C++ exception, function ThrowAsException() is used [SWS_PER_00350]. The following sequence illustrates the interaction during error querying and exception throwing:

Error query and exception throwing in PerErrorDomainApplicationPersistenzLaufzeitPerErrorDomainExecute persistence operation()Return error code / ResultMessage(errorCode)const char * (Fehlernachricht)optException handling desiredThrowAsException(errorCode)throw PerException

Sequence diagram: Typical flow of error checking, text querying, and exception throwing via PerErrorDomain. Sources: [SWS_PER_00314], [SWS_PER_00315], [SWS_PER_00350].

Error Scenarios

In practical use of ara::per::PerErrorDomain, developers must take into account the varying guarantees regarding error handling and exception safety. While the querying interfaces Name() [SWS_PER_00314] and Message() [SWS_PER_00315] are strictly declared as noexcept and classified as exception-safe, the member function ThrowAsException() is considered not exception-safe (not exception safe) [SWS_PER_00350]. This behavior is semantically justified because the purpose of the function consists in throwing an exception corresponding to the error code in a controlled manner (noexcept(false)).

An essential constraint concerns platforms or build configurations without enabled C++ exceptions: if exception handling is disabled in the compiler, ThrowAsException() does not participate in overload resolution according to [SWS_PER_00350]. In such environments, the application software must fall back on evaluating error codes via the provided aliases Errc [SWS_PER_00411] and textual descriptions of Message() [SWS_PER_00315] instead of catching exception objects of type Exception [SWS_PER_00412].

This guide was generated automatically based on AUTOSAR specification requirements.

Member map

Constructors and destructor

1

Type aliases

2

Class diagram

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

G nara__per__PerErrorDomain979 PerErrorDomain + PerErrorDomain() + Message() + Name() + ThrowAsException() nara__core__ErrorDomain335 ErrorDomain nara__per__PerErrorDomain979->nara__core__ErrorDomain335

Detail view

Select an entry in the outline.

Constructors and destructor

Creates a PerErrorDomain instance.

PerErrorDomain () noexcept;

Methods

Message function

Returns the message associated with the error code.

const char * Message (CodeType errorCode) const noexcept override;
Name function

Returns the name of the error domain.

const char * Name () const noexcept override;

Throws the exception associated with the error code. As per [SWS_CORE_10304], this function does not participate in overload resolution when C++ exceptions are disabled in the compiler toolchain.

void ThrowAsException (const ara::core::ErrorCode &errorCode) const noexcept(false) override;

Type aliases

Errc type alias

Alias for the error code value enumeration.

using Errc = PerErrc;
Exception type alias

Alias for the exception base class.

Method documentation

function Message [SWS_PER_00315] Upstream: RS_AP_00119, RS_AP_00120, RS_AP_00121, RS_AP_00159

const char * Message (CodeType errorCode) const noexcept override;

Returns the message associated with the error code.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
Exception-Sicherheitexception safe
Thread-Sicherheitthread-safe

Parameter (in)

ParameterBeschreibung
errorCodeThe error code number.

Rückgabewert

TypBeschreibung
const char *The message associated with the error code.

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

Record
AUTOSAR/AP/record/SWS_PER_00315
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00315@rel:R25-11#dcf865cc
Content hash
dcf865cc
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00315
Status: valid/unmigrated Version: rel:R25-11#b3b0e84a Versionshistorie & Revisions (1 transition, 8 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_PER_00315@rel:R25-11#b3b0e84a
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#dcf865cc2026-09-30
  • R19-11rel:R19-11#fa40c0592026-10-14
  • R20-11rel:R20-11#482223252026-10-14
  • R21-11rel:R21-11#4762f8102026-10-14
  • R22-11rel:R22-11#03cd14022026-10-14
  • R23-11rel:R23-11#d69d63782026-10-14
  • R24-11rel:R24-11#b3b0e84a2026-10-14
  • R25-11rel:R25-11#b3b0e84a2026-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

function Name [SWS_PER_00314] Upstream: RS_AP_00119, RS_AP_00120, RS_AP_00159

const char * Name () const noexcept override;

Returns the name of the error domain.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
Exception-Sicherheitexception safe
Thread-Sicherheitthread-safe

Rückgabewert

TypBeschreibung
const char *As per ara::per::PerErrorDomain in [SWS_CORE_90023].

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

Record
AUTOSAR/AP/record/SWS_PER_00314
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00314@rel:R25-11#8efa8b41
Content hash
8efa8b41
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00314
Status: valid/unmigrated Version: rel:R25-11#bbc9c834 Versionshistorie & Revisions (1 transition, 8 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_PER_00314@rel:R25-11#bbc9c834
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#8efa8b412026-09-30
  • R19-11rel:R19-11#157f07862026-10-14
  • R20-11rel:R20-11#578706942026-10-14
  • R21-11rel:R21-11#578706942026-10-14
  • R22-11rel:R22-11#7e3ba2a72026-10-14
  • R23-11rel:R23-11#4ed7a81d2026-10-14
  • R24-11rel:R24-11#f4d2bd532026-10-14
  • R25-11rel:R25-11#bbc9c8342026-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

function PerErrorDomain [SWS_PER_00313] Upstream: RS_AP_00119, RS_AP_00120, RS_AP_00159

PerErrorDomain () noexcept;

Creates a PerErrorDomain instance.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
Exception-Sicherheitexception safe
Thread-Sicherheitthread-safe

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

Record
AUTOSAR/AP/record/SWS_PER_00313
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00313@rel:R25-11#2fe03ca6
Content hash
2fe03ca6
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00313
Status: valid/unmigrated Version: rel:R25-11#676bd5fe Versionshistorie & Revisions (1 transition, 8 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_PER_00313@rel:R25-11#676bd5fe
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#2fe03ca62026-09-30
  • R19-11rel:R19-11#493784652026-10-14
  • R20-11rel:R20-11#e90ad4282026-10-14
  • R21-11rel:R21-11#4fed90922026-10-14
  • R22-11rel:R22-11#c86bdbe02026-10-14
  • R23-11rel:R23-11#07bddb402026-10-14
  • R24-11rel:R24-11#676bd5fe2026-10-14
  • R25-11rel:R25-11#676bd5fe2026-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

function ThrowAsException [SWS_PER_00350] Upstream: RS_AP_00120, RS_AP_00121

void ThrowAsException (const ara::core::ErrorCode &errorCode) const noexcept(false) override;

Throws the exception associated with the error code. As per [SWS_CORE_10304], this function does not participate in overload resolution when C++ exceptions are disabled in the compiler toolchain.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
Exception-Sicherheitnot exception safe
Thread-Sicherheitthread-safe

Parameter (in)

ParameterBeschreibung
errorCodeThe error to throw.

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_PER_00350
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00350@rel:R25-11#ac2c5033
Content hash
ac2c5033
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00350
Status: valid/unmigrated Version: rel:R25-11#d5cad670 Versionshistorie & Revisions (1 transition, 8 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_PER_00350@rel:R25-11#d5cad670
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#ac2c50332026-09-30
  • R19-11rel:R19-11#08d8b5132026-10-14
  • R20-11rel:R20-11#bcef1c2f2026-10-14
  • R21-11rel:R21-11#bcef1c2f2026-10-14
  • R22-11rel:R22-11#855e1f712026-10-14
  • R23-11rel:R23-11#a44240ed2026-10-14
  • R24-11rel:R24-11#d5cad6702026-10-14
  • R25-11rel:R25-11#d5cad6702026-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

Type alias documentation

type alias Errc [SWS_PER_00411] Upstream: RS_AP_00122

using Errc = PerErrc;

Alias for the error code value enumeration.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
SymbolErrc

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

Record
AUTOSAR/AP/record/SWS_PER_00411
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00411@rel:R25-11#78fe2202
Content hash
78fe2202
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00411
Status: valid/unmigrated Version: rel:R25-11#9d0ddf8d Versionshistorie & Revisions (1 transition, 7 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_PER_00411@rel:R25-11#9d0ddf8d
Point-in-Time History:
Recorded Revisions (7):
  • R25-11rel:R25-11#78fe22022026-09-30
  • R20-11rel:R20-11#39e744882026-10-14
  • R21-11rel:R21-11#39e744882026-10-14
  • R22-11rel:R22-11#8f96934a2026-10-14
  • R23-11rel:R23-11#9d0ddf8d2026-10-14
  • R24-11rel:R24-11#9d0ddf8d2026-10-14
  • R25-11rel:R25-11#9d0ddf8d2026-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

type alias Exception [SWS_PER_00412] Upstream: RS_AP_00122

using Exception = PerException;

Alias for the exception base class.

Header-Datei#include "ara/per/per_error_domain.h"
Scopeclass ara::per::PerErrorDomain
SymbolException

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

Record
AUTOSAR/AP/record/SWS_PER_00412
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_PER_00412@rel:R25-11#0875fcdc
Content hash
0875fcdc
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Persistency.pdf#nameddest=SWS_PER_00412
Status: valid/unmigrated Version: rel:R25-11#12539c4d Versionshistorie & Revisions (1 transition, 7 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_PER_00412@rel:R25-11#12539c4d
Point-in-Time History:
Recorded Revisions (7):
  • R25-11rel:R25-11#0875fcdc2026-09-30
  • R20-11rel:R20-11#e88607572026-10-14
  • R21-11rel:R21-11#e88607572026-10-14
  • R22-11rel:R22-11#b0bd04f32026-10-14
  • R23-11rel:R23-11#12539c4d2026-10-14
  • R24-11rel:R24-11#12539c4d2026-10-14
  • R25-11rel:R25-11#12539c4d2026-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