DEENESPTFRRUARHIKOZHNL

class ara::diag::DataTransferReadSession

[SWS_DM_01548] Upstream: RS_Diag_04135

class DataTransferReadSession final {...};

Encapsulates all data transfer reading variants.

Header-Datei#include "ara/diag/data_transfer.h"
Forwarding-Header#include "ara/diag/diag_fwd.h"
Scopenamespace ara::diag

User GuideAI-GENERATED

Encapsulates active diagnostic read transfers and forwards incoming data transfers to registered handlers.
AI-GENERATED unreviewed Model: gemini-3.8-flash-medium · Effort: medium · Temperature: not controllable · Prompt: 9db606b147f6 Provenance Open questions (2)
translated from the German guidegemini-3.8-flash-low · 2026-10-13 · German original

Encapsulates active diagnostic read transfers and forwards incoming data transfers to registered handlers.

The class serves for the encapsulation and structured management of all variants of diagnostic read transfers within the adaptive AUTOSAR diagnostic module according to [SWS_DM_01548]. After the successful initiation of a read operation, the diagnostic server instance delegates incoming requests for sequential data block transfer and for session termination to the registered methods of the read handler [SWS_DM_01317]. By specifically disabling copy operations while simultaneously supporting move semantics, the class ensures an unambiguous ownership assignment of the underlying transfer session.

Context

The class ara::diag::DataTransferReadSession represents the encapsulation of all variants for diagnostic reading of data blocks in the adaptive diagnostic module [SWS_DM_01548]. In the context of standardized UDS services such as RequestFileTransfer (0x38), TransferData (0x36), and RequestTransferExit (0x37), the session class acts as a link between the internal runtime environment of the diagnostic server and the application-specific read handlers SWS Diagnostics §7 “Realization of TransferData and RequestTransferExit”. It ensures that ongoing read-out operations—such as for files via ReadFile [SWS_DM_01314] or directories via ReadDir [SWS_DM_01315]—are managed in an isolated manner and forwarded to the associated handlers.

DataTransferReadSessionContext client Diagnose-Client (Tester) server Diagnostic Server (ara::diag) client->server UDS RequestFileTransfer TransferData / Exit session ara::diag::DataTransferReadSession (Transfersitzung) server->session verwaltet Lesesitzung handler Lese-Handler (Applikation) session->handler delegiert Read() / Exit()

Context diagram: Embedding of DataTransferReadSession between diagnostic server and application handler. Sources: [SWS_DM_01317], [SWS_DM_01318], SWS Diagnostics §7 “Realization of TransferData and RequestTransferExit”.

Lifecycle

An instance of ara::diag::DataTransferReadSession has a lifetime that is strictly coupled to the transfer session. Creation via a default constructor is explicitly prohibited [SWS_DM_01549]. Instead, the session is initialized via specialized template constructors that register the application-specific handlers SWS Diagnostics §7 “Realization of TransferData and RequestTransferExit”. In practice, instantiation is likely typically performed by the diagnostic server or the service handler upon initiation of the file transfer. Question Q-b0706bcd28c702c6 (open)

To rule out multiple assignments or inconsistent session states, ara::diag::DataTransferReadSession is designed as a non-copyable single instance: both the copy constructor [SWS_DM_01553] and the copy assignment operator [SWS_DM_01554] are deleted (=delete). A transfer of ownership is intended exclusively via move semantics. The move constructor [SWS_DM_01551] and the move assignment operator [SWS_DM_01552] are defined as noexcept=default. Destruction occurs deterministically via the destructor [SWS_DM_01550], which is likewise declared as noexcept=default. Completing the transfer via RequestTransferExit presumably leads to the release of the object. Question Q-c1999fd1f283a007 (open)

Usage Path

The typical sequence of a read transfer session is divided into three consecutive phases:

  • Initialization: An external diagnostic client sends RequestFileTransfer with a read mode such as ReadFile (0x04) [SWS_DM_01314] or ReadDir (0x05) [SWS_DM_01315]. During this, the session instance is created and the read handler is registered.
  • Data transfer: The diagnostic server processes incoming diagnostic requests of type TransferData (0x36) by calling the corresponding Read method of the handler registered via the template constructors [SWS_DM_01317]. This is done iteratively for each requested data block.
  • Termination: As soon as all data has been transferred, the client sends RequestTransferExit (0x37). The diagnostic server then calls the Exit method of the registered handler in order to terminate the read operation properly [SWS_DM_01318].
Sequence of a file-based read transferDiagnostic clientDiagnostic ServerDataTransferReadSessionRequestFileTransfer (0x38)ReadFile / ReadDirInitialisierung viaTemplate-KonstruktorPositiv-Response (0x78)loopAs long as data blocks are transferredTransferData (0x36)Read()Gelesene BlockdatenTransferData Positiv-ResponseRequestTransferExit (0x37)Exit()Confirmation of completionRequestTransferExit Response

Sequence diagram: Call sequence of a UDS read transfer with handover to the registered session. Sources: [SWS_DM_01314], [SWS_DM_01315], [SWS_DM_01317], [SWS_DM_01318].

Error Scenarios

Since ara::diag::DataTransferReadSession is declared as final and the default constructor [SWS_DM_01549] does not exist, erroneous creation without a registered handler is already prevented at compile time. Likewise, the deleted copy operations [SWS_DM_01553] prevent accidental duplication of session states. Both move construction as well as move assignment and destruction guarantee absolute exception safety through their noexcept specification [SWS_DM_01551] [SWS_DM_01550]. If the provision of data blocks in the handler fails, this is handled on the protocol level within the scope of UDS communication.

This guide is based on the specification AUTOSAR Adaptive Platform R25-11 (diag module) and summarizes the requirements for ara::diag::DataTransferReadSession.

Member map

Operators

1

Class diagram

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

G nara__diag__DataTransferReadSession318 DataTransferReadSession + DataTransferReadSession() + ~DataTransferReadSession() + operator=()

Detail view

Select an entry in the outline.

Constructors and destructor

No default construction allowed.

Overloads DataTransferReadSession 3
DataTransferReadSession ()=delete; SWS_DM_01549
DataTransferReadSession (DataTransferReadSession &&other) noexcept=default; SWS_DM_01551
DataTransferReadSession (DataTransferReadSession const &)=delete; SWS_DM_01553

Destructs an instance of this class.

~DataTransferReadSession () noexcept=default;

Operators

operator= function 2

Move assigns an instance of this class.

Overloads = 2
auto operator= (DataTransferReadSession &&other) & noexcept -> Data TransferReadSession & =default; SWS_DM_01552
auto operator= (DataTransferReadSession const &) -> DataTransferRead Session &=delete; SWS_DM_01554

Method documentation

function DataTransferReadSession [SWS_DM_01549] Upstream: RS_Diag_04135

DataTransferReadSession ()=delete;

No default construction allowed.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession

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

Record
AUTOSAR/AP/record/SWS_DM_01549
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01549@rel:R25-11#c4cbcc0b
Content hash
c4cbcc0b
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01549
Status: valid/unmigrated Version: rel:R25-11#b12b963b 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_DM_01549@rel:R25-11#b12b963b
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#c4cbcc0b2026-09-30
  • R22-11rel:R22-11#99668fac2026-10-14
  • R23-11rel:R23-11#f616e79a2026-10-14
  • R24-11rel:R24-11#b12b963b2026-10-14
  • R25-11rel:R25-11#b12b963b2026-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 DataTransferReadSession [SWS_DM_01551] Upstream: RS_Diag_04135

DataTransferReadSession (DataTransferReadSession &&other) noexcept=default;

Move constructs an instance of this class.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession
Exception-Sicherheitexception safe

Parameter (out)

ParameterBeschreibung
otherThe other object

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

Record
AUTOSAR/AP/record/SWS_DM_01551
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01551@rel:R25-11#21edf176
Content hash
21edf176
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01551
Status: valid/unmigrated Version: rel:R25-11#9d8ef11f 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_DM_01551@rel:R25-11#9d8ef11f
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#21edf1762026-09-30
  • R22-11rel:R22-11#313c13512026-10-14
  • R23-11rel:R23-11#ab0c46e72026-10-14
  • R24-11rel:R24-11#5b475da32026-10-14
  • R25-11rel:R25-11#9d8ef11f2026-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 DataTransferReadSession [SWS_DM_01553] Upstream: RS_Diag_04135

DataTransferReadSession (DataTransferReadSession const &)=delete;

DataTransferReadSession shall be a single not copy-able instance.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession

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

Record
AUTOSAR/AP/record/SWS_DM_01553
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01553@rel:R25-11#a630ea6c
Content hash
a630ea6c
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01553
Status: valid/unmigrated Version: rel:R25-11#fbc13491 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_DM_01553@rel:R25-11#fbc13491
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#a630ea6c2026-09-30
  • R22-11rel:R22-11#35a6d77b2026-10-14
  • R23-11rel:R23-11#c1d834202026-10-14
  • R24-11rel:R24-11#6803928e2026-10-14
  • R25-11rel:R25-11#fbc134912026-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 operator= [SWS_DM_01552] Upstream: RS_Diag_04135

auto operator= (DataTransferReadSession &&other) & noexcept -> Data TransferReadSession & =default;

Move assigns an instance of this class.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession
Exception-Sicherheitexception safe

Parameter (out)

ParameterBeschreibung
otherThe other object

Rückgabewert

TypBeschreibung
DataTransferReadSessionReference to self

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

Record
AUTOSAR/AP/record/SWS_DM_01552
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01552@rel:R25-11#457fd3d0
Content hash
457fd3d0
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01552
Status: valid/unmigrated Version: rel:R25-11#d99670ce 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_DM_01552@rel:R25-11#d99670ce
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#457fd3d02026-09-30
  • R22-11rel:R22-11#85ce121e2026-10-14
  • R23-11rel:R23-11#e7bc25f92026-10-14
  • R24-11rel:R24-11#826c7d1b2026-10-14
  • R25-11rel:R25-11#d99670ce2026-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 operator= [SWS_DM_01554] Upstream: RS_Diag_04135

auto operator= (DataTransferReadSession const &) -> DataTransferRead Session &=delete;

DataTransferReadSession shall be a single not assign-able instance.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession

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

Record
AUTOSAR/AP/record/SWS_DM_01554
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01554@rel:R25-11#a2fa062f
Content hash
a2fa062f
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01554
Status: valid/unmigrated Version: rel:R25-11#8d7ab93b 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_DM_01554@rel:R25-11#8d7ab93b
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#a2fa062f2026-09-30
  • R22-11rel:R22-11#609b1c622026-10-14
  • R23-11rel:R23-11#22a9c8aa2026-10-14
  • R24-11rel:R24-11#c9a88d712026-10-14
  • R25-11rel:R25-11#8d7ab93b2026-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 ~DataTransferReadSession [SWS_DM_01550] Upstream: RS_Diag_04135

~DataTransferReadSession () noexcept=default;

Destructs an instance of this class.

Header-Datei#include "ara/diag/data_transfer.h"
Scopeclass ara::diag::DataTransferReadSession
Exception-Sicherheitexception safe

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

Record
AUTOSAR/AP/record/SWS_DM_01550
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_DM_01550@rel:R25-11#d3c56064
Content hash
d3c56064
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Diagnostics.pdf#nameddest=SWS_DM_01550
Status: valid/unmigrated Version: rel:R25-11#0b5bb2a2 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_DM_01550@rel:R25-11#0b5bb2a2
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#d3c560642026-09-30
  • R22-11rel:R22-11#18bafff82026-10-14
  • R23-11rel:R23-11#bfe91d802026-10-14
  • R24-11rel:R24-11#94e05f472026-10-14
  • R25-11rel:R25-11#0b5bb2a22026-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