函数 Convert [SWS_CRYPT_50198] Upstream: RS_CRYPTO_02112
virtual ara::core::Result< void > Convert (ReadOnlyMemRegion input, ReadWriteMemRegion out) const noexcept=0;
Converts the data according to the previous configuration of the Formatter.
接口ara::crypto::Formatter的纯虚成员函数Convert根据先前确定的 Formatter 对象配置执行数据的同步转换[SWS_CRYPT_50198]。声明可通过头文件#include "ara/crypto/common/formatter.h"获取[SWS_CRYPT_50198]。调用时,调用方通过类型为ReadOnlyMemRegion的缓冲区input传入原始格式的输入数据,并通过类型为ReadWriteMemRegion的可写缓冲区out接收写入的目标格式转换数据[SWS_CRYPT_50198]。
返回值定义为ara::core::Result<void>,指示成功或发生的错误[SWS_CRYPT_50198]。若转换期间发生问题,将采用具有以下特定错误代码的回滚语义[SWS_CRYPT_50198]:
ara::crypto::CryptoErrc::kInvalidArgument:若序列化的输入数据不符合指定格式,则返回此项[SWS_CRYPT_50198]。ara::crypto::CryptoErrc::kInsufficientCapacity:当传入的输出缓冲区out容量过小而无法接收结果数据时发生[SWS_CRYPT_50198]。
在并发性和容错性方面,该方法被指定为线程安全(thread-safe)和异常安全(exception safe)[SWS_CRYPT_50198]。由于签名带有说明符const和noexcept,该操作不抛出 C++ 异常,且不改变 Formatter 实例的状态[SWS_CRYPT_50198]。
此使用说明由人工智能基于规范自动生成。
| Header-Datei | #include "ara/crypto/common/formatter.h" |
|---|---|
| Scope | class ara::crypto::Formatter |
| Exception-Sicherheit | exception safe |
| Thread-Sicherheit | thread-safe |
Parameter (in)
| Parameter | Beschreibung |
|---|---|
| input | an input buffer containing the data in the input format |
Parameter (out)
| Parameter | Beschreibung |
|---|---|
| out | an output buffer that the data will be written to in the output format |
Rückgabewert
| Typ | Beschreibung |
|---|---|
| ara::core::Result< void > | An empty result or an error. |
Fehler
| Fehlercode | Beschreibung |
|---|---|
| ara::crypto::CryptoErrc::kInvalidArgument | rollback_semantics if serialized does not conform to the specified format |
| ara::crypto::CryptoErrc::kInsufficientCapacity | rollback_semantics if the output buffer is too small |
Request a governed re-review of this record. The record is not changed immediately.
- Record
AUTOSAR/AP/record/SWS_CRYPT_50198- Status
- valid/unmigrated
- Version
AUTOSAR/AP/record/SWS_CRYPT_50198@rel:R25-11#8e9d3a56- Content hash
8e9d3a56- Source
- https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Cryptography.pdf#nameddest=SWS_CRYPT_50198
Status: valid/unmigrated
Version: rel:R25-11#19644f36
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_CRYPT_50198@rel:R25-11#19644f36
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 · 德文原文