DEENESPTFRRUARHIKOZHNL

类 <SI-Namespace>::skeleton::fields::<Field>

[SWS_CM_00007] Upstream: RS_CM_00219, RS_AP_00114

class <Field> {...};

Service skeleton Field class, one for each Field defined in the ServiceInterface in the role field.

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Forwarding-Header#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton/<SiShortname>_skeleton_fwd.h"
Scopenamespace <SI-Namespace>::skeleton::fields

用户指南人工智能生成

支持服务 Skeleton 提供、更新和类型化处理字段请求。
AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 7ece784e04d9 来源 未决问题(2)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

支持服务 Skeleton 提供、更新和类型化处理字段请求。

类 <SI-Namespace>::skeleton::fields::<Field> 在服务器端提供 ServiceInterface 的字段,并为所提供的服务连接 Getter、Setter 以及通知功能。提供者应用程序为传入的读取和写入访问注册异步处理程序([SWS_CM_00114]、[SWS_CM_00116]),并通过方法 Update([SWS_CM_00119])主动将值变更分发给订阅客户端。在此过程中,传入的处理程序必须有效,而发送调用必须遵守配置的最短发送时间,以避免出现诸如 kMinimumSendIntervalViolationError 之类的错误。

上下文

模板类 <SI-Namespace>::skeleton::fields::<Field> 在 Adaptive Communication Management 内封装了在 ServiceInterface 中建模的字段的服务器端表示。对于在服务接口中定义的每个字段,中间件都会使用头文件路径 #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" 在命名空间 skeleton::fields 中生成相应的类实例。字段结合了数据传输和方法调用的功能特征,可选择包含 Getter、Setter 以及通知功能。字段值的对应数据类型通过类型别名 FieldType 提供([SWS_CM_11402])。核心交互伙伴包括提供服务的提供者应用程序、作为中介的 Skeleton 字段实例、订阅的服务使用者(Proxy)以及 Executor 形式的可选执行上下文([SWS_CM_11360]、[SWS_CM_11362])。

app Provider-Anwendung field skeleton::fields::<Field> app->field RegisterGetHandler() RegisterSetHandler() Update() field->app Get / Set Callback client Client / Proxy field->client Feld-Notifizierungen client->field Get / Set Anfragen executor ExecutorT (ara::core::Executor) executor->field Asynchroner Kontext

上下文图:Skeleton Field 类在请求和通知中的交互伙伴。来源:[SWS_CM_00114]、[SWS_CM_00116]、[SWS_CM_00119]、[SWS_CM_11360]。

生命周期

字段实例的生命周期与上级服务 Skeleton 实例紧密耦合。解释:Field 实例可能是作为所属 Skeleton 类的成员对象进行实例化,并完全共享其生命周期。 问题 Q-dedeaea09a8abb20 (未决)各个接口方法的可用性直接取决于软件设计中的定义:方法 RegisterGetHandler 仅在字段配置了 Field.hasGetter == TRUE 时存在([SWS_CM_00114]),而 RegisterSetHandler 则要求通过 Field.hasSetter == TRUE 存在 Setter([SWS_CM_00116])。为了防止通信受到端到端传输错误的影响,应用程序可以通过 SetTransportFaultConditionHandler 注册特定的处理程序([SWS_CM_00096]),并在需要时通过 UnsetTransportFaultConditionHandler 将其重新移除([SWS_CM_00098])。在并发性方面,带有模板参数 ExecutorT 的重载(例如 ara::core::Executor)提供了将回调函数的执行转移到已定义的异步执行上下文中的可能性([SWS_CM_11360]、[SWS_CM_11362]、[SWS_CM_00097]、AUTOSAR_AP_EXP_ARAComAPI 第11页)。

使用路径

常规操作流程分为回调函数配置、查询处理以及主动发送数据更新:

解释:处理程序的注册宜在提供服务之前完成,以便能够无缝处理传入的请求。 问题 Q-617e65d056af24f9 (未决)存在 Getter 时,应用程序通过 RegisterGetHandler 绑定一个返回 ara::core::Future<FieldType> 的回调函数([SWS_CM_00114])。对于修改性访问,它通过 RegisterSetHandler 注册一个处理程序,该处理程序接收新值并进行处理,同样通过 Future 异步提供结果状态([SWS_CM_00116])。如果服务提供者希望自主更新字段值,则使用新值调用方法 Update([SWS_CM_00119]、AUTOSAR_AP_EXP_ARAComAPI 第11页)。由此重新设置字段的内部状态。只要字段建模有通知功能(Field.hasNotifier == TRUE),Update 就会促使将更改后的数据值立即传输给所有已注册的订阅者([SWS_CM_00119]、[SWS_CM_00120]、[SWS_CM_00162])。

骨架处字段交互的典型流程Provider-Anwendungskeleton::fields::<Field>Client / ProxyUse Case: 初始化与处理程序注册RegisterGetHandler(handler)RegisterSetHandler(setHandler)Use Case: Get 与 Set 处理Get()handler()ara::core::Future<FieldType>FieldType 返回Set(value)setHandler(value)ara::core::Future<FieldType>Aktualisierter WertUse Case: 值更新与通知Update(value)ara::core::Result<void>Notifizierung (Event/Field-Update)

时序图:处理程序注册、请求处理和数据更新的典型流程。来源:[SWS_CM_00114]、[SWS_CM_00116]、[SWS_CM_00119]。

错误场景

错误条件表现为注册时的编程契约违反或运行时的传输错误。所有处理程序注册方法——RegisterGetHandler、RegisterSetHandler 以及 SetTransportFaultConditionHandler——均被指定为 noexcept 并具有 exception safe 异常保证([SWS_CM_00114]、[SWS_CM_00116]、[SWS_CM_00096])。前置条件为传入的可调用对象(Callable)必须存在且不能为 null;违反此条件会触发 InvalidHandlerViolation([SWS_CM_00114]、[SWS_CM_11360]、[SWS_CM_00116]、[SWS_CM_11362]、[SWS_CM_00096]、[SWS_CM_00097])。

通过 Update 进行主动更新时,错误反馈通过返回类型 ara::core::Result<void> 进行([SWS_CM_00119])。如果发生错误,Result 对象将提供来自 ara::com::ComErrc 的错误代码。特别是,以短于部署属性 ServiceInterfaceDeploymentElement.minimumSendInterval 规定的间隔进行发送会导致返回错误 ComErrc::kMinimumSendIntervalViolationError([SWS_CM_00119])。

本指南基于 AUTOSAR Adaptive Platform 规范版本 R25-11,由自动化工具生成。

成员图

类图

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

G n_SI_Namespace___skeleton__fields___Field_667 <Field> + SetTransportFaultConditionHandler() + UnsetTransportFaultConditionHandler() + Update() + RegisterGetHandler() + RegisterSetHandler()

详细视图

请在大纲中选择一个条目。

方法

Register a callback function to be invoked when a Get() request is received. The method exists only if the offered service contains a Field and Field.hasGetter ==TRUE

重载 RegisterGetHandler 2
void RegisterGetHandler (std::function< ara::core::Future< FieldType >()> handler) noexcept; SWS_CM_00114
template <typename ExecutorT> void RegisterGetHandler (std::function< ara::core::Future< FieldType >()> handler, ExecutorT &&executor) noexcept; SWS_CM_11360

Register a callback function to be invoked when a Set() request is received. The method exists only if the offered service contains a Field and Field.hasSetter ==TRUE

重载 RegisterSetHandler 2
void RegisterSetHandler (std::function< ara::core::Future< FieldType >(<SFieldDerivedType> value)> handler) noexcept; SWS_CM_00116
template <typename ExecutorT> void RegisterSetHandler (std::function< ara::core::Future< FieldType >(<SFieldDerivedType> value)> setHandler, ExecutorT &&executor) noexcept; SWS_CM_11362

Provides possibility to register a ara::com::e2e::TransportFaultConditionHandler for a given Skeleton Field Get/Set.

重载 SetTransportFaultConditionHandler 2
void SetTransportFaultConditionHandler (ara::com::e2e::TransportFault ConditionHandler handler) noexcept; SWS_CM_00096
template <typename ExecutorT> void SetTransportFaultConditionHandler (ara::com::e2e::TransportFault ConditionHandler handler, ExecutorT &&executor) noexcept; SWS_CM_00097

Provides the possibility to unregister a previously set ara::com::e2e:: TransportFaultConditionHandler for a given Skeleton Field Get/Set.

void UnsetTransportFaultConditionHandler () noexcept;
Update 函数

Initiate the transmission of updated field data to the subscribers. See [SWS_CM_00162] for the required behavior. The Update function shall also update the fields internal value. An update notification shall be sent to any subscribers if: • Field.hasNotifier ==TRUE (according to [SWS_CM_00120])

ara::core::Result< void > Update (<SFieldDerivedType> value) noexcept;

类型别名

FieldType 类型别名

Data type for the value of a field (an alias for the CppImplementationDataType of the Field, i.e. for the CppImplementationDataType which is either referenced by the VariableDataPrototype in the role type directly or via indirection of a DataTypeMap)

using FieldType = <SFieldCppidt>;

方法文档

函数 RegisterGetHandler [SWS_CM_00114] Upstream: RS_CM_00218, RS_AP_00114, RS_AP_00120, RS_AP_00127, RS_AP_00128, RS_AP_00138

void RegisterGetHandler (std::function< ara::core::Future< FieldType >()> handler) noexcept;

Register a callback function to be invoked when a Get() request is received. The method exists only if the offered service contains a Field and Field.hasGetter ==TRUE

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 01ae49e1e2d8 来源
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

使用

方法 RegisterGetHandler 在服务器端于 Skeleton 的字段对象上调用([SWS_CM_00114])。仅当在相关字段的接口描述中配置了 Getter 时,它才会存在于生成的代码中(Field.hasGetter == TRUE)(EXP ARAComAPI §5.4.8.1 “Registering Getters”)。传入类型为 std::function<ara::core::Future<FieldType>()> 的回调 handler,当收到代理的 Get() 请求时,绑定实现将调用该回调。

注册此类 Handler 完全是可选的(EXP ARAComAPI §5.4.8.1 “Registering Getters”)。通常,服务实现不需要 Getter Handler,因为 Communication Management 会缓存最近通过 Update() 设置的值并自主响应代理请求。只有当确定字段值非常耗时或计算量很大,因此应在实际需要时才通过 Promise/Future 模式异步进行时,Handler 才尤为有意义。

错误处理与边界条件

该函数没有返回值,声明为 noexcept 并且是异常安全的(exception safe)([SWS_CM_00114])。如果传入的 Callable 不存在或为 null,则存在错误 InvalidHandlerViolation([SWS_CM_00114])。

相互作用

与 RegisterSetHandler(在存在 Setter 时必须调用 EXP ARAComAPI §5.4.8.2 “Registering Setters”)相反,RegisterGetHandler 完全是可选的。如果 Handler 要在特定执行上下文中异步处理,还可以使用带有 ExecutorT 的重载模板函数([SWS_CM_11360])。

本使用说明由 AI 基于 AUTOSAR R25-11 规范生成。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Parameter (in)

ParameterBeschreibung
handlerThe callback function to be invoked to process the Field get request

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_00114
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00114@rel:R25-11#ec2a9a8c
Content hash
ec2a9a8c
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00114
Status: valid/unmigrated Version: rel:R25-11#c6386380 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_CM_00114@rel:R25-11#c6386380
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#417163c72026-09-30
  • R19-11rel:R19-11#f07f56a32026-10-14
  • R20-11rel:R20-11#cdd125c72026-10-14
  • R21-11rel:R21-11#cdd125c72026-10-14
  • R22-11rel:R22-11#6a153b112026-10-14
  • R23-11rel:R23-11#23956e7c2026-10-14
  • R24-11rel:R24-11#5d29d0102026-10-14
  • R25-11rel:R25-11#c63863802026-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

函数 RegisterGetHandler [SWS_CM_11360] Upstream: RS_CM_00211, RS_AP_00114, RS_AP_00120, RS_AP_00127, RS_AP_00128, RS_AP_00138

template <typename ExecutorT> void RegisterGetHandler (std::function< ara::core::Future< FieldType >()> handler, ExecutorT &&executor) noexcept;

As per [SWS_CM_00114] but the method shall execute in a provided context

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 44ad84fd0b08 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

使用

命名空间 <SI-Namespace>::skeleton::fields::<Field> 中的方法 RegisterGetHandler 注册一个应用程序端回调(handler),当代理发起传入的 Get() 调用时,通信绑定将调用该回调([SWS_CM_11360]、EXP ARAComAPI §5.4.8.1 “Registering Getters”)。与无参数的基本重载 [SWS_CM_00114] 不同,该方法接收类型为 ExecutorT 的执行上下文 executor,回调将在其中异步执行([SWS_CM_11360])。作为执行器,可以使用标准化的 ara::core::Executor 或具有相同接口的用户特定类型([SWS_CM_11360])。

注册的处理器返回 ara::core::Future<FieldType>,从而通过 Promise/Future 模式将字段值的计算解耦([SWS_CM_11360]、EXP ARAComAPI §5.4.8.1 “Registering Getters”)。该注册完全是可选的:如果未注册处理器,Communication Management 将使用最后通过 Update() 设置的值自主响应请求(EXP ARAComAPI §5.4.8.1 “Registering Getters”)。Getter 处理器主要适用于按需确定繁重或耗时的字段值(EXP ARAComAPI §5.4.8.1 “Registering Getters”)。

限制与错误处理

仅当在 IDL 中为该字段配置了 Getter 时,该方法才会存在于 Skeleton 中(Field.hasGetter == TRUE、[SWS_CM_00114]、EXP ARAComAPI §5.4.8.1 “Registering Getters”)。RegisterGetHandler 被声明为 noexcept;然而,如果传入了无效或可调用的空对象,则构成 InvalidHandlerViolation([SWS_CM_11360])。理解:传入的执行器在处理器的整个使用期限内应该都必须保持有效,因为传入的请求会被异步调度到其上下文中。 问题 Q-c58eb22b06a8c27c (未决)

本使用说明由 AI 基于 AUTOSAR 规范 R25-11 生成。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Template-Parameter

ParameterBeschreibung
ExecutorTWrapper type providing methods for asynchronous execution of Callables. AUTOSAR provides a standardized ara::core:: Executor or implementations may use a custom type which provides the same interface.

Parameter (in)

ParameterBeschreibung
handlerAs per [SWS_CM_00114]
executorThe context in which this method shall be "executed"

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_11360
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_11360@rel:R25-11#1b9b8314
Content hash
1b9b8314
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_11360
Status: valid/unmigrated Version: rel:R25-11#bd94b445 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_CM_11360@rel:R25-11#bd94b445
Point-in-Time History:
Recorded Revisions (7):
  • R25-11rel:R25-11#9957b1ff2026-09-30
  • R20-11rel:R20-11#437503622026-10-14
  • R21-11rel:R21-11#29c07ecb2026-10-14
  • R22-11rel:R22-11#29c07ecb2026-10-14
  • R23-11rel:R23-11#1e758dfd2026-10-14
  • R24-11rel:R24-11#6f38f9302026-10-14
  • R25-11rel:R25-11#bd94b4452026-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

函数 RegisterSetHandler [SWS_CM_00116] Upstream: RS_CM_00218, RS_AP_00114, RS_AP_00120, RS_AP_00127, RS_AP_00128, RS_AP_00138

void RegisterSetHandler (std::function< ara::core::Future< FieldType >(<SFieldDerivedType> value)> handler) noexcept;

Register a callback function to be invoked when a Set() request is received. The method exists only if the offered service contains a Field and Field.hasSetter ==TRUE

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: f0cab292149d 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

使用

方法RegisterSetHandler在服务端(骨架)用于注册一个回调函数,当客户端针对某个字段的Set()请求到达时,该回调函数将被调用[SWS_CM_00116]。仅当所提供的字段配置了 Setter 支持时(Field.hasSetter == TRUE),该方法才存在[SWS_CM_00116]。与 Getter 注册不同,调用RegisterSetHandler是强制性的,因为服务端实现必须预先验证匿名客户端的新字段值或已更新字段值EXP ARAComAPI §5.4.8.2 “Registering Setters”。

注册的处理程序接收新值作为参数,并返回包含生效的(可能经过修正的)值的ara::core::Future<FieldType>[SWS_CM_00116],EXP ARAComAPI §5.4.8.2 “Registering Setters”。该生效值由通信管理系统隐式采用并发布给客户端;因此在处理程序内部无需显式调用Update()EXP ARAComAPI §5.4.8.2 “Registering Setters”。

错误处理与边界条件

该函数被定义为noexcept并且是异常安全的[SWS_CM_00116]。如果传递了不存在或无效的(null)Callable,则构成形式为InvalidHandlerViolation的规范违规[SWS_CM_00116]。解释:可能必须在通过OfferService()提供服务之前完成注册,以便从一开始就能够接收传入的客户端请求。 问题 Q-d45be0a899ddb6dd (未决)

相互作用

除了基本方法之外,还存在一个模板重载[SWS_CM_11362],通过它可以将处理程序的执行绑定到特定的执行上下文(符合[SWS_CM_11360]的ExecutorT)EXP ARAComAPI。

本使用说明是根据 R25-11 规范版本自动生成的。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Parameter (in)

ParameterBeschreibung
handlerAs per [SWS_CM_00114]

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_00116
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00116@rel:R25-11#0a4c0b54
Content hash
0a4c0b54
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00116
Status: valid/unmigrated Version: rel:R25-11#a967ca39 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_CM_00116@rel:R25-11#a967ca39
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#50a50c352026-09-30
  • R19-11rel:R19-11#320f0ae42026-10-14
  • R20-11rel:R20-11#e56d43e62026-10-14
  • R21-11rel:R21-11#e56d43e62026-10-14
  • R22-11rel:R22-11#f8c463c42026-10-14
  • R23-11rel:R23-11#4653d88a2026-10-14
  • R24-11rel:R24-11#eb7262452026-10-14
  • R25-11rel:R25-11#a967ca392026-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

函数 RegisterSetHandler [SWS_CM_11362] Upstream: RS_CM_00211, RS_AP_00114, RS_AP_00120, RS_AP_00127, RS_AP_00128, RS_AP_00138

template <typename ExecutorT> void RegisterSetHandler (std::function< ara::core::Future< FieldType >(<SFieldDerivedType> value)> setHandler, ExecutorT &&executor) noexcept;

As per [SWS_CM_00116] but the method shall execute in a provided context

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: aa59afd1a2ad 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

模板函数 RegisterSetHandler 在Field的服务器层或Skeleton层注册一个回调函数,一旦客户端发送 Set() 请求,该回调函数就会被调用([SWS_CM_11362],[SWS_CM_00116])。仅当配置的服务Field提供Setter支持(Field.hasSetter == TRUE)时,该接口才存在([SWS_CM_00116])。与Get注册不同,注册Set处理程序是强制性的,因为服务器实现必须始终验证来自匿名客户端的新Field值(EXP ARAComAPI §5.4.8.2 “Registering Setters”)。

与符合 [SWS_CM_00116] 的标准注册相比,此重载额外接受一个类型为 ExecutorT&& 的执行上下文 executor([SWS_CM_11362],[SWS_CM_11360])。Interpretation:executor 推测控制回调在哪个线程上下文或任务调度器上下文中执行。 问题 Q-6dec4c0005c388dd (未决)传入的处理程序具有签名 std::function<ara::core::Future<FieldType>(<SFieldDerivedType> value)>;它接收由客户端设置的值,并通过 ara::core::Future 异步返回有效的(可能经过验证或校正的)值([SWS_CM_11362],EXP ARAComAPI §5.4.8.2 “Registering Setters”)。

Communication Management隐式采用处理程序返回的有效值,就好像服务器应用程序本身调用了 Update() 一样;因此在处理程序内部手动调用 Update() 是多余的(EXP ARAComAPI §5.4.8.2 “Registering Setters”,EXP ARAComAPI §4.6 “Data Type Abstractions”)。

错误处理与并发性:

  • 异常安全性:该函数被声明为 noexcept,并被指定为异常安全(exception safe)([SWS_CM_11362])。
  • 违规:如果传入的可调用对象 setHandler 不存在或是 nullptr,则属于违规 InvalidHandlerViolation([SWS_CM_11362])。
  • 上下文:该方法确保处理程序的执行在 executor 所提供的上下文中进行([SWS_CM_11362])。

此使用说明基于AUTOSAR规范自动创建。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Template-Parameter

ParameterBeschreibung
ExecutorTAs per [SWS_CM_11360]

Parameter (in)

ParameterBeschreibung
setHandlerAs per [SWS_CM_00116]
executorAs per [SWS_CM_11360]

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_11362
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_11362@rel:R25-11#4a75d1a8
Content hash
4a75d1a8
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_11362
Status: valid/unmigrated Version: rel:R25-11#012add4b 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_CM_11362@rel:R25-11#012add4b
Point-in-Time History:
Recorded Revisions (7):
  • R25-11rel:R25-11#6e268d732026-09-30
  • R20-11rel:R20-11#a1cce0c32026-10-14
  • R21-11rel:R21-11#46e987b82026-10-14
  • R22-11rel:R22-11#46e987b82026-10-14
  • R23-11rel:R23-11#cdcd5ed72026-10-14
  • R24-11rel:R24-11#d4ed3d212026-10-14
  • R25-11rel:R25-11#012add4b2026-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

函数 SetTransportFaultConditionHandler [SWS_CM_00096] Upstream: RS_CM_00224, RS_E2E_08534

void SetTransportFaultConditionHandler (ara::com::e2e::TransportFault ConditionHandler handler) noexcept;

Provides possibility to register a ara::com::e2e::TransportFaultConditionHandler for a given Skeleton Field Get/Set.

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 50dd99d62bf7 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

函数 SetTransportFaultConditionHandler 用于在命名空间 <SI-Namespace>::skeleton::fields::<Field> [SWS_CM_00096] 中的 Skeleton 层级上,为字段的 Get 和 Set 请求注册类型为 ara::com::e2e::TransportFaultConditionHandler 的错误处理器。该调用同步执行,没有返回值(void),并通过规范为 noexcept 保证异常安全 [SWS_CM_00096]。对于需要将 Handler 执行委托给显式执行上下文的场景,提供了带有 Executor 对象 ExecutorT&& executor 的模板重载 [SWS_CM_00097]。

错误条件定义为违背 InvalidHandlerViolation;当传入的 Callable handler 不存在或为 null 时发生 [SWS_CM_00096]。虽然客户端的方法和字段请求错误通过各个 ara::core::Future 实例中的 ComErrc::kCommunicationFailure 进行报告 [SWS_CM_00090],但该函数允许服务器实例在传入 Get 和 Set 调用时接收传输错误 [SWS_CM_00096]。

该概念对应于 Skeleton 服务实例的所有方法的相关注册机制 [SWS_CM_00093],以及事件 [SWS_CM_00099]、触发器 [SWS_CM_00106] 和字段通知器 [SWS_CM_00109] 的代理端 Handler。Interpretation:Handler 的注册适宜在提供 Skeleton 之前的初始化阶段进行,以便能够无缝捕获初始字段访问时的错误。 问题 Q-627229896b666532 (未决)

本使用说明为自动生成,基于 AUTOSAR R25-11 规范文档。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Parameter (in)

ParameterBeschreibung
handlerHandler of type ara::com::e2e:: TransportFaultConditionHandler to be set

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_00096
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00096@rel:R25-11#a4176dfc
Content hash
a4176dfc
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00096
Status: valid/unmigrated Version: rel:R25-11#3e34141f Versionshistorie & Revisions (1 transition, 3 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_00096@rel:R25-11#3e34141f
Point-in-Time History:
Recorded Revisions (3):
  • R25-11rel:R25-11#37a0a6942026-09-30
  • R24-11rel:R24-11#b910a6fe2026-10-14
  • R25-11rel:R25-11#3e34141f2026-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

函数 SetTransportFaultConditionHandler [SWS_CM_00097] Upstream: RS_CM_00224, RS_E2E_08534

template <typename ExecutorT> void SetTransportFaultConditionHandler (ara::com::e2e::TransportFault ConditionHandler handler, ExecutorT &&executor) noexcept;

Execution Context overload for hierarchicalnamespacelistlowerskeleton:: skeleton::fields::fieldname::SetTransportFaultConditionHandler for a given Skeleton Field Get/Set.

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 0b525529fe14 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

命名空间 <SI-Namespace>::skeleton::fields::<Field> 中的函数 SetTransportFaultConditionHandler 注册一个错误处理程序,用于处理 Skeleton 级别字段的 Get 和 Set 请求时的传输故障 [SWS_CM_00097]。它通过头文件 <SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h 包含 [SWS_CM_00097]。

用法与参数

该调用同步进行且没有返回值(void)[SWS_CM_00097]。类型为 ara::com::e2e::TransportFaultConditionHandler 的可调用错误回调 handler 以及泛型类型 ExecutorT&& 的转发引用 executor 作为参数传递 [SWS_CM_00097]。参数 executor 表示执行对象,任何异步计算都在该对象的上下文中执行 [SWS_CM_00097]。

错误处理与并发

该方法被声明为 noexcept 并保证完全的异常安全性(exception safe)[SWS_CM_00097]。如果传入的 handler 可调用对象不存在或为 null,则会引发 InvalidHandlerViolation [SWS_CM_00097]。解释:通过传入的 executor 对象,推测将确定在哪个线程或任务上下文中处理传输错误时的异步通知。 问题 Q-4101faaa8d6a3130 (未决)

相互作用

该方法通过为 Skeleton 字段提供专用执行上下文扩展了标准注册 [SWS_CM_00096] [SWS_CM_00097]。对于 Skeleton 方法([SWS_CM_00094])以及在客户端或 Proxy 端针对事件([SWS_CM_00100])和字段通知器([SWS_CM_00110]),也存在带有执行器的相应重载。

本使用说明由人工智能生成,并且仅基于 Release R25-11 的规范。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe
Verletzungen (Violations)InvalidHandlerVio- Provided Callable handler does not exist or is null lation

Parameter (in)

ParameterBeschreibung
handlerHandler of type ara::com::e2e:: TransportFaultConditionHandler to be set
executorExecutor object in which any asynchronous computation spawn shall be invoked

Rückgabewert

TypBeschreibung
None
Siehe auch: [SWS_CM_00096]

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

Record
AUTOSAR/AP/record/SWS_CM_00097
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00097@rel:R25-11#70a2b402
Content hash
70a2b402
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00097
Status: valid/unmigrated Version: rel:R25-11#43b66b1f Versionshistorie & Revisions (1 transition, 3 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_00097@rel:R25-11#43b66b1f
Point-in-Time History:
Recorded Revisions (3):
  • R25-11rel:R25-11#225cecf82026-09-30
  • R24-11rel:R24-11#ee2004b32026-10-14
  • R25-11rel:R25-11#43b66b1f2026-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

函数 UnsetTransportFaultConditionHandler [SWS_CM_00098] Upstream: RS_CM_00224, RS_E2E_08534

void UnsetTransportFaultConditionHandler () noexcept;

Provides the possibility to unregister a previously set ara::com::e2e:: TransportFaultConditionHandler for a given Skeleton Field Get/Set.

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 6f1322ef4e13 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

在服务接口的 Skeleton 端,函数 UnsetTransportFaultConditionHandler 用于取消先前为字段的 Get 和 Set 请求注册的 ara::com::e2e::TransportFaultConditionHandler([SWS_CM_00098])。它在命名空间 <SI-Namespace>::skeleton::fields::<Field> 中定义并通过头文件 <SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h 包含(AUTOSAR_AP_SWS_CommunicationManagement §8.4.3.2.1.3 “UnsetTransportFaultConditionHandler”)。该调用同步进行,不接受输入参数且不返回返回值(void)。

通过注销,针对字段请求时传输错误状态的应用程序专用回调将被停用(AUTOSAR_AP_SWS_CommunicationManagement §7.4.1 “End-to-end communication protection for SOMEIP”)。该接口被声明为noexcept,并保证异常安全性(exception safe)([SWS_CM_00098])。未通过 DET 或 DEM 指定错误代码或特定错误消息;该操作被设计为无差错完成。

关于并发性和可重入性,该规范未包含单独规定。因此,注销最好在去初始化阶段或在并发 Get/Set 处理之外执行,以避免正在进行的通信过程中出现不一致。 问题 Q-06bc8d90f1891904 (未决)

该操作是服务实例端到端通信保护的一部分(AUTOSAR_AP_SWS_CommunicationManagement §7.4.1 “End-to-end communication protection for SOMEIP”)。它是[SWS_CM_00095]在字段层面的对应项,后者用于注销骨架(Skeleton)所有方法的处理程序。在代理(Proxy)端,它对应于针对事件([SWS_CM_00105])、触发器([SWS_CM_00108])以及字段通知器([SWS_CM_00126])的相应注销操作。

本使用说明基于 AUTOSAR 规范 R25-11 自动创建。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe

Rückgabewert

TypBeschreibung
None

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

Record
AUTOSAR/AP/record/SWS_CM_00098
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00098@rel:R25-11#7a0faa0f
Content hash
7a0faa0f
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00098
Status: valid/unmigrated Version: rel:R25-11#0a13a3e7 Versionshistorie & Revisions (1 transition, 3 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_00098@rel:R25-11#0a13a3e7
Point-in-Time History:
Recorded Revisions (3):
  • R25-11rel:R25-11#567e08112026-09-30
  • R24-11rel:R24-11#8140569f2026-10-14
  • R25-11rel:R25-11#0a13a3e72026-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

函数 Update [SWS_CM_00119] Upstream: RS_CM_00218, RS_AP_00114, RS_AP_00120, RS_AP_00121

ara::core::Result< void > Update (<SFieldDerivedType> value) noexcept;

Initiate the transmission of updated field data to the subscribers. See [SWS_CM_00162] for the required behavior. The Update function shall also update the fields internal value. An update notification shall be sent to any subscribers if: • Field.hasNotifier ==TRUE (according to [SWS_CM_00120])

AI 生成 未审核 模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: ceb337447ab4 来源 未决问题(1)
译自德文指南gemini-3.8-flash-low · 2026-10-13 · 德文原文

方法 Update() 在服务器端的作用域 <SI-Namespace>::skeleton::fields::<Field> 中调用,以更新字段的内部值并启动向已订阅客户端传输新数据([SWS_CM_00119],AUTOSAR_AP_EXP_ARAComAPI §4.6 “Data Type Abstractions”)。当为字段配置了 hasNotifier == TRUE 时,会向订阅者发送通知([SWS_CM_00119],[SWS_CM_00120],[SWS_CM_00162])。参数 value 通过引用传递;绑定实现将在调用期间创建通常已序列化的副本,以便应用程序数据在调用方返回后可以被修改或释放(AUTOSAR_EXP_ARAComAPI “UpdateRate Class”)。

该函数定义为 noexcept 以及 exception safe,并同步返回一个 ara::core::Result<void>([SWS_CM_00119])。如果发生错误,结果将包含来自 ara::com::ComErrc 的错误代码([SWS_CM_00119],[SWS_CM_10432])。具体而言,如果发送请求的发生速度快于所配置的最小发送间隔 ServiceInterfaceDeploymentElement.minimumSendInterval 所规定的速度,则会返回具有回滚语义的 ComErrc::kMinimumSendIntervalViolationError([SWS_CM_00119])。

在服务生命周期中,在提供服务之前需要初始调用 Update():如果在初始化字段值之前调用了 OfferService(),则提供将失败并返回 ComErrc::kFieldValueNotInitialized([SWS_CM_00101],[SWS_CM_00128])。由于标准中缺乏显式的可重入性保证,同一字段实例上的并发调用应当在应用程序端进行同步。 问题 Q-67b174ef05867989 (未决)

本使用说明基于 AUTOSAR 标准 R25-11 自动创建。

实现者指南即将推出(复杂度 I2)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
Exception-Sicherheitexception safe

Parameter (in)

ParameterBeschreibung
valueThe value to be sent to subscribers

Rückgabewert

TypBeschreibung
ara::core::Result< void >• If successful: an ara::core::Result containing a ara:: core::Result::value_type • If unsuccessful: an ara::core::Result containing an ara:: core::Result::error_type i.e. a corresponding ara:: com::ComErrc

Fehler

FehlercodeBeschreibung
ComErrc::kMinimumSendIntervalViolationErrorrollback_semantics Minimum Send Interval violation, because a transmission request for a service instance element (event, field or method call) was issued faster than allowed, i.e., the configured minimum send interval ServiceInterfaceDeploymentElement. minimumSendInterval for the service instance element has not yet expired.

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

Record
AUTOSAR/AP/record/SWS_CM_00119
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_00119@rel:R25-11#a3f7bfd4
Content hash
a3f7bfd4
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_00119
Status: valid/unmigrated Version: rel:R25-11#f2b83ddc 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_CM_00119@rel:R25-11#f2b83ddc
Point-in-Time History:
Recorded Revisions (8):
  • R25-11rel:R25-11#de7aa84f2026-09-30
  • R19-11rel:R19-11#e64af9a12026-10-14
  • R20-11rel:R20-11#e8f21c102026-10-14
  • R21-11rel:R21-11#0afac5612026-10-14
  • R22-11rel:R22-11#3e7a86112026-10-14
  • R23-11rel:R23-11#daabe32d2026-10-14
  • R24-11rel:R24-11#c1e2db482026-10-14
  • R25-11rel:R25-11#f2b83ddc2026-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

类型别名文档

类型别名 FieldType [SWS_CM_11402] Upstream: RS_CM_00219, RS_AP_00114

using FieldType = <SFieldCppidt>;

Data type for the value of a field (an alias for the CppImplementationDataType of the Field, i.e. for the CppImplementationDataType which is either referenced by the VariableDataPrototype in the role type directly or via indirection of a DataTypeMap)

Header-Datei#include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h"
Scopeclass <SI-Namespace>::skeleton:: fields::<Field>
SymbolFieldType

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

Record
AUTOSAR/AP/record/SWS_CM_11402
Status
valid/unmigrated
Version
AUTOSAR/AP/record/SWS_CM_11402@rel:R25-11#a0bab412
Content hash
a0bab412
Source
https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_CommunicationManagement.pdf#nameddest=SWS_CM_11402
Status: valid/unmigrated Version: rel:R25-11#11e46b26 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_11402@rel:R25-11#11e46b26
Point-in-Time History:
Recorded Revisions (5):
  • R25-11rel:R25-11#ab2582db2026-09-30
  • R22-11rel:R22-11#fd04825a2026-10-14
  • R23-11rel:R23-11#fd04825a2026-10-14
  • R24-11rel:R24-11#f639aee72026-10-14
  • R25-11rel:R25-11#11e46b262026-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