函数 now [SWS_CORE_06432] Upstream: RS_AP_00130
static time_point now () noexcept;
Return a time_point representing the current value of the clock.
静态函数 ara::core::SteadyClock::now() 同步返回一个 time_point,表示时钟的当前计数值 [SWS_CORE_06432]。使用时需包含头文件 ara/core/steady_clock.h [SWS_CORE_06432]。由于该方法静态绑定到 ara::core::SteadyClock,因此无需对该类进行实例化;可直接通过作用域进行访问。
关于错误处理,该函数使用 noexcept 声明,并标明为异常安全(exception safe)[SWS_CORE_06432]。因此,调用方无需为时间查询提供异常处理,因为该操作保证无错误返回。
关于并发性和限制,now() 被指定为线程安全(thread-safe)[SWS_CORE_06432]。允许在无需应用侧同步的情况下,从任意执行上下文和线程中并行调用该函数。
在 ara::core::SteadyClock 的接口内,该函数的主要用途推测是为相对时间间隔测量和运行时间确定提供时间点(解释:由作用域和返回类型 [SWS_CORE_06432] 推导得出)。 问题 Q-34b2317714fd4e03 (未决)
本使用说明由系统自动生成,基于 AUTOSAR Adaptive R25-11 规范。
| Header-Datei | #include "ara/core/steady_clock.h" |
|---|---|
| Scope | class ara::core::SteadyClock |
| Exception-Sicherheit | exception safe |
| Thread-Sicherheit | thread-safe |
Rückgabewert
| Typ | Beschreibung |
|---|---|
| time_point | a time_point |
Request a governed re-review of this record. The record is not changed immediately.
- Record
AUTOSAR/AP/record/SWS_CORE_06432- Status
- valid/unmigrated
- Version
AUTOSAR/AP/record/SWS_CORE_06432@rel:R25-11#d718975c- Content hash
d718975c- Source
- https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Core.pdf#nameddest=SWS_CORE_06432
Status: valid/unmigrated
Version: rel:R25-11#5c6a8c47
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_CORE_06432@rel:R25-11#5c6a8c47
Recorded Revisions (7):
- R25-11
rel:R25-11#bd3e18002026-09-30 - R20-11
rel:R20-11#2ebaac9e2026-10-14 - R21-11
rel:R21-11#2ebaac9e2026-10-14 - R22-11
rel:R22-11#23f195162026-10-14 - R23-11
rel:R23-11#1e8f88b82026-10-14 - R24-11
rel:R24-11#5c6a8c472026-10-14 - R25-11
rel:R25-11#5c6a8c472026-10-14 active
Requirement Text as-of this release:
Curation Decisions:
Reachable Artifacts & Dependents:
| Date | Actor | Transition | Reason / Rationale | Campaign |
|---|---|---|---|---|
| 2026-08-13 | tool | none → valid/unmigrated | mechanically 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 · 德文原文