类 <SI-Namespace>::skeleton::triggers::<Trigger>
[SWS_CM_00726] Upstream: RS_CM_00201 , RS_AP_00114
class <Trigger> {...};
Service skeleton Trigger class, one for each Trigger defined in the ServiceInterface in the role trigger.
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Forwarding-Header #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton/<SiShortname>_skeleton_fwd.h" Scope namespace <SI-Namespace>::skeleton::triggers
用户指南人工智能生成 使服务 Skeleton 能够发送触发信号并监控订阅者状态。
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 6e97d3082aff
来源
摘要 详细
使服务 Skeleton 能够发送触发信号并监控订阅者状态。
上下文
模板类 <SI-Namespace>::skeleton::triggers::<Trigger> 表示在 ServiceInterface 内以 trigger 角色定义的触发器的服务端接口。作为服务骨架(Skeleton)的组成部分,该类用于服务实例向整个系统中的订阅 Client 应用程序发送异步通知或触发信号。触发器与常规事件的区别在于,它主要充当没有复杂有效负载的纯信号指示事件,如 EXP_ARAComAPI §3 “Trigger::Send” 和 SWS_CommunicationManagement §7.2.2.1.4 “Handling Triggers” 中的归类所述。交互伙伴包括提供服务的服务器应用程序、中间件 Communication Management(ara::com)以及通过网络连接的 Subscriber Client。
生命周期
触发器对象的实例化通常作为相应 ServiceInterface 的 Skeleton 实例的组成部分执行。在主动使用之前,必须通过 Communication Management 提供 Skeleton;如果尝试在此之前触发 Trigger,则传输将失败([SWS_CM_00721] )。该类通过 ara::com::SubscriptionState 管理订阅者的订阅状态,该状态可随时通过 GetSubscriptionState() 查询([SWS_CM_01109] )。为了进行异步状态监控,可以通过 SetSubscriptionStateChangeHandler() 注册回调([SWS_CM_01110] )。对于并发架构,存在一个接受用户定义的 Executor 的重载,以便在所需的线程或任务上下文中执行通知([SWS_CM_01111] )。可以通过 UnsetSubscriptionStateChangeHandler() 再次取消注册([SWS_CM_01112] )。该类的所有方法均提供异常安全保证 noexcept(exception safe)。
使用路径
使用触发器的典型流程包括观察订阅状态以及实际向所有活动订阅者触发传输:
服务骨架处的触发信号发送流程 Server-App Trigger-Instanz ara::com SetSubscriptionStateChangeHandler(handler) void Use Case: 客户端更改订阅 handler(kSubscribed) GetSubscriptionState() kSubscribed Use Case: Trigger senden Send() Sende Trigger-Signal Result<void>
时序图:带有订阅监控的触发器传输典型流程。来源:[SWS_CM_01110] ,[SWS_CM_01109] ,[SWS_CM_00721] ,SWS_CommunicationManagement §7.2.2.1.4 。
错误场景
方法 Send() 返回一个 ara::core::Result<void>,可能的传输和配置错误将通过它进行传递([SWS_CM_00721] ):
ComErrc::kServiceNotOffered:当服务实例尚未通过 OfferService() 提供时发生([SWS_CM_00721] )。
ComErrc::kMinimumSendIntervalViolationError:如果在连续传输之间低于配置的最小发送间隔(minimumSendInterval),则返回此项([SWS_CM_00721] )。
ComErrc::kCommunicationFailure:如果触发器的发送由于底层网络错误而在本地失败,则报告此项([SWS_CM_10517] )。
无效的处理程序(InvalidHandlerViolation):向 SetSubscriptionStateChangeHandler() 传递不存在或空的可调用对象(Callable)构成对 API 契约条件的违反([SWS_CM_01110] ,[SWS_CM_01111] )。
本指南完全基于 AUTOSAR Adaptive Platform 版本 R25-11 规范。
分组依据 类别 历史
成员图 类图 Hohle Dreieckspfeile = Vererbung (zeigt zur Basisklasse); Klicken öffnet die jeweilige Klassenseite.
G
n_SI_Namespace___skeleton__triggers___Trigger_907
<Trigger>
+ Send()
+ SetSubscriptionStateChangeHandler()
+ GetSubscriptionState()
+ UnsetSubscriptionStateChangeHandler()
详细视图 此版本没有元素数据
方法 Query ara::com::SubscriptionState of an trigger.
Send trigger to all subscribing applications.
Set/Register ara::com::SubscriptionState change handler
重载 SetSubscriptionStateChangeHandler 2 Unset/Deregister the ara::com::SubscriptionState change handler
void UnsetSubscriptionStateChangeHandler () noexcept;
点击条目以查看其关系。
基类 派生类 使用 被使用于 继承 自此版本起移除 用于 此类中无关联 函数 AI 评注 打开类页面 无法加载类页面。 调整顺序 调整宽度 调整大纲宽度 章节 阅读时间 SWS 引用 图表 放回中间 调整顺序或拖到标题栏 取消停靠 – 在内容中显示 移到中间栏 作为标签停靠到标题栏 元素 AI 模型 打开审计档案 档案 打开简短版本 打开中等版本 打开完整版本 恢复默认视图 已恢复默认视图 撤销 关闭详细视图 签名 基本信息 值 截至所选版本的最后一次更改 之后的下一次更改 单击:选择版本 无法放在此处:拖到标题栏可停靠,拖到中间栏可取消停靠。 新增 已更改 未更改 已移除 未包含 更改 内容无变化 首次出现于 移除于 没有可用的版本数据。 正在加载版本数据 … 文本 此版本未收录措辞 悬停或单击单元格:与所选版本比较 · 单击版本标题:选择版本 选择版本 属性 版本 元素 只有一个版本有措辞 PDF 中存在,原文尚未导入 首次采集原文 自 {rel} 起未更改 版本颜色 最早版本 最新版本
方法文档
ara::com::SubscriptionState GetSubscriptionState () const noexcept;
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Scope class <SI-Namespace>::skeleton:: triggers::<Trigger> Exception-Sicherheit exception safe
Rückgabewert
Status: valid/unmigrated
Version: rel:R25-11#3c94b170
Versionshistorie & Revisions (1 transition)
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_01109@rel:R25-11#3c94b170
Point-in-Time History:
Release:
R25-11 (Current / Active) R20-11 R19-11
View Snapshot
Historical Snapshot:
× Back to current
🚫
Requirement entfallen: Dieses Element ist im gewählten Release nicht mehr enthalten.
Requirement Text as-of this release:
Reachable Artifacts & Dependents:
Date Actor Transition Reason / Rationale Campaign
2026-08-13 tool none → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record 2026-08-13-status-backfill
ara::core::Result < void > Send () noexcept;
Send trigger to all subscribing applications.
用户指南
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: a3259c7728c6
来源
未决问题(1)
本文由 AI 基于 AUTOSAR 规范 R25-11 生成。
实现者指南即将推出(复杂度 I2)
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Scope class <SI-Namespace>::skeleton:: triggers::<Trigger> Exception-Sicherheit exception safe
Rückgabewert
Typ Beschreibung ara::core::Result < void >• If successful: an ara::core::Result containing a ara:: core::Result::value_type containing a void • If unsuccessful: an ara::core::Result containing an ara:: core::Result::error_type i.e. a corresponding ara:: com::ComErrc
Fehler
Fehlercode Beschreibung ComErrc::kServiceNotOffered rollback_semantics Service has not yet been offered via OfferService() ComErrc::kMinimumSendIntervalViolationError rollback_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.
Status: valid/unmigrated
Version: rel:R25-11#358a03ec
Versionshistorie & Revisions (1 transition, 6 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_00721@rel:R25-11#358a03ec
Point-in-Time History:
Release:
R25-11 (Current / Active) R21-11 R22-11 R23-11 R24-11 R20-11 R19-11
View Snapshot
Recorded Revisions (6):
R25-11 rel:R25-11#3ca0ef032026-09-30 Inspect R21-11 rel:R21-11#28e321132026-10-14 Inspect R22-11 rel:R22-11#9e3dfc132026-10-14 Inspect R23-11 rel:R23-11#11d16c2d2026-10-14 Inspect R24-11 rel:R24-11#7198da332026-10-14 Inspect R25-11 rel:R25-11#358a03ec2026-10-14 active Inspect
Historical Snapshot:
× Back to current
🚫
Requirement entfallen: Dieses Element ist im gewählten Release nicht mehr enthalten.
Requirement Text as-of this release:
Reachable Artifacts & Dependents:
Date Actor Transition Reason / Rationale Campaign
2026-08-13 tool none → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record 2026-08-13-status-backfill
void SetSubscriptionStateChangeHandler (ara::com::SubscriptionState ChangeHandler handler) noexcept;
用户指南
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: d968f8357edf
来源
本文由 AI 基于 AUTOSAR 规范 R25-11 生成。
实现者指南即将推出(复杂度 I2)
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Scope class <SI-Namespace>::skeleton:: triggers::<Trigger> Exception-Sicherheit exception safe Verletzungen (Violations) InvalidHandlerVio- Provided Callable handler does not exist or is null lation
Parameter (in)
Parameter Beschreibung handler The handler (as per [SWS_CM_00311] ) that shall be called by Communication Management as soon as the ara::com :: SubscriptionState of the trigger has changed.
Rückgabewert
Status: valid/unmigrated
Version: rel:R25-11#c6e0fca1
Versionshistorie & Revisions (1 transition)
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_01110@rel:R25-11#c6e0fca1
Point-in-Time History:
Release:
R25-11 (Current / Active) R20-11 R19-11
View Snapshot
Historical Snapshot:
× Back to current
🚫
Requirement entfallen: Dieses Element ist im gewählten Release nicht mehr enthalten.
Requirement Text as-of this release:
Reachable Artifacts & Dependents:
Date Actor Transition Reason / Rationale Campaign
2026-08-13 tool none → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record 2026-08-13-status-backfill
template <typename ExecutorT> void SetSubscriptionStateChangeHandler (ara::com::SubscriptionState ChangeHandler handler, ExecutorT &&executor) noexcept;
As per [SWS_CM_12008] but the method shall execute in a provided context
用户指南
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: f69a35ebe8e5
来源
未决问题(1)
此使用说明基于AUTOSAR Adaptive R25-11的规范数据自动生成。
实现者指南即将推出(复杂度 I2)
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Scope class <SI-Namespace>::skeleton:: triggers::<Trigger> Exception-Sicherheit exception safe Verletzungen (Violations) InvalidHandlerVio- Provided Callable handler does not exist or is null lation
Template-Parameter
Parameter (in)
Rückgabewert
Status: valid/unmigrated
Version: rel:R25-11#fc3a9545
Versionshistorie & Revisions (1 transition)
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_01111@rel:R25-11#fc3a9545
Point-in-Time History:
Release:
R25-11 (Current / Active) R20-11 R19-11
View Snapshot
Historical Snapshot:
× Back to current
🚫
Requirement entfallen: Dieses Element ist im gewählten Release nicht mehr enthalten.
Requirement Text as-of this release:
Reachable Artifacts & Dependents:
Date Actor Transition Reason / Rationale Campaign
2026-08-13 tool none → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record 2026-08-13-status-backfill
void UnsetSubscriptionStateChangeHandler () noexcept;
用户指南
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: d6281d4aa1ed
来源
未决问题(1)
本使用说明基于 AUTOSAR R25-11 规范自动生成。
实现者指南即将推出(复杂度 I2)
Header-Datei #include "<SiNamespaceDerivedDirectoryPath>/<SiShortname>_skeleton.h" Scope class <SI-Namespace>::skeleton:: triggers::<Trigger> Exception-Sicherheit exception safe
Rückgabewert
Status: valid/unmigrated
Version: rel:R25-11#19334e8a
Versionshistorie & Revisions (1 transition)
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_01112@rel:R25-11#19334e8a
Point-in-Time History:
Release:
R25-11 (Current / Active) R20-11 R19-11
View Snapshot
Historical Snapshot:
× Back to current
🚫
Requirement entfallen: Dieses Element ist im gewählten Release nicht mehr enthalten.
Requirement Text as-of this release:
Reachable Artifacts & Dependents:
Date Actor Transition Reason / Rationale Campaign
2026-08-13 tool none → valid/unmigratedmechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record 2026-08-13-status-backfill
gemini-3.8-flash-low· 2026-10-13 · 德文原文