类 ara::per::FileAccessor
[SWS_PER_00588] Upstream: RS_PER_00004 , RS_AP_00122 , RS_AP_00146
class FileAccessor {...};
FileAccessor contains a common basis for ReadAccessor and WriteAccessor. It provides methods for checking and setting the current position in the file (GetPosition, Set Position, MovePosition, IsEof) and for checking the current size of the file (GetSize).
Header-Datei #include "ara/per/file_accessor.h" Forwarding-Header #include "ara/per/per_fwd.h" Scope namespace ara::per
用户指南人工智能生成 用作专用文件访问中文件大小查询和位置导航的通用基类。
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: e1768b56d42c
来源
未决问题(2)
摘要 详细
用作专用文件访问中文件大小查询和位置导航的通用基类。
类 ara::per::FileAccessor 在 AUTOSAR 持久化模块中用作有序文件访问的位置导航和大小检查的通用基类([SWS_PER_00424] )。它通过已删除的构造函数禁止直接实例化和拷贝操作([SWS_PER_00589] )。当位置指定无效时,会采用回滚语义来保护当前指针位置。所有操作都是异常安全的,但在并发使用时需要外部同步。
更多 ›
本文由 AI 基于 AUTOSAR 规范 R25-11 编写。它补充了规范性文档,提供了导航抽象的整体概述。
分组依据 类别 历史
成员图 类图 Hohle Dreieckspfeile = Vererbung (zeigt zur Basisklasse); Klicken öffnet die jeweilige Klassenseite.
G
nara__per__FileAccessor932
FileAccessor
+ FileAccessor()
+ operator=()
+ ~FileAccessor()
+ GetPosition()
+ GetSize()
+ IsEof()
+ MovePosition()
+ SetPosition()
nara__per__ReadAccessor956
ReadAccessor
nara__per__ReadAccessor956->nara__per__FileAccessor932
nara__per__WriteAccessor940
WriteAccessor
nara__per__WriteAccessor940->nara__per__FileAccessor932
详细视图 此版本没有元素数据
构造函数和析构函数 The default constructor for FileAccessor shall not be used.
重载 FileAccessor 3 Destructor for FileAccessor.
方法 Returns the current position relative to the beginning of the file. The returned position may be at the end of the file.
Returns the current size of a file in bytes.
Checks if the current position is at end of file.
bool IsEof () const noexcept;
Moves the current position in the file relative to the Origin. In case of an error, the current position is not changed.
Sets the current position relative to the beginning of the file. In case of an error, the current position is not changed.
运算符 The move assignment operator for FileAccessor shall not be used.
重载 = 2
点击条目以查看其关系。
基类 派生类 使用 被使用于 继承 自此版本起移除 用于 此类中无关联 函数 AI 评注 打开类页面 无法加载类页面。 调整顺序 调整宽度 调整大纲宽度 章节 阅读时间 SWS 引用 图表 放回中间 调整顺序或拖到标题栏 取消停靠 – 在内容中显示 移到中间栏 作为标签停靠到标题栏 元素 AI 模型 打开审计档案 档案 打开简短版本 打开中等版本 打开完整版本 恢复默认视图 已恢复默认视图 撤销 关闭详细视图 签名 基本信息 值 截至所选版本的最后一次更改 之后的下一次更改 单击:选择版本 无法放在此处:拖到标题栏可停靠,拖到中间栏可取消停靠。 新增 已更改 未更改 已移除 未包含 更改 内容无变化 首次出现于 移除于 没有可用的版本数据。 正在加载版本数据 … 文本 此版本未收录措辞 悬停或单击单元格:与所选版本比较 · 单击版本标题:选择版本 选择版本 属性 版本 元素 只有一个版本有措辞 PDF 中存在,原文尚未导入 首次采集原文 自 {rel} 起未更改 版本颜色 最早版本 最新版本
方法文档
FileAccessor ()=delete;
The default constructor for FileAccessor shall not be used.
Status: valid/unmigrated
Version: rel:R25-11#f2d5e1fc
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_PER_00589@rel:R25-11#f2d5e1fc
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
FileAccessor (FileAccessor &&ra)=delete;
The move constructor for FileAccessor shall not be used.
Status: valid/unmigrated
Version: rel:R25-11#08b3d49a
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_PER_00590@rel:R25-11#08b3d49a
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
FileAccessor (const FileAccessor &)=delete;
The copy constructor for FileAccessor shall not be used.
Status: valid/unmigrated
Version: rel:R25-11#d27604ed
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_PER_00592@rel:R25-11#d27604ed
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
std::uint64_t GetPosition () const noexcept;
Returns the current position relative to the beginning of the file. The returned position may be at the end of the file.
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Rückgabewert
Typ Beschreibung std::uint64_t The current position in the file in bytes from the beginning of the file.
Status: valid/unmigrated
Version: rel:R25-11#f20dc3e3
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_PER_00162@rel:R25-11#f20dc3e3
Point-in-Time History:
Release:
R25-11 (Current / Active) R19-11 R20-11 R21-11 R22-11 R23-11 R24-11
View Snapshot
Recorded Revisions (8):
R25-11 rel:R25-11#416e7a9c2026-09-30 Inspect R19-11 rel:R19-11#ae38b90b2026-10-14 Inspect R20-11 rel:R20-11#a53d148f2026-10-14 Inspect R21-11 rel:R21-11#b0fecce62026-10-14 Inspect R22-11 rel:R22-11#0f4d44d22026-10-14 Inspect R23-11 rel:R23-11#912ecabe2026-10-14 Inspect R24-11 rel:R24-11#eb8d26992026-10-14 Inspect R25-11 rel:R25-11#f20dc3e32026-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
std::uint64_t GetSize () const noexcept;
Returns the current size of a file in bytes.
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Rückgabewert
Typ Beschreibung std::uint64_t The current size of the file in bytes.
Status: valid/unmigrated
Version: rel:R25-11#0403ec61
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_PER_00424@rel:R25-11#0403ec61
Point-in-Time History:
Release:
R25-11 (Current / Active) R20-11 R21-11 R22-11 R23-11 R24-11 R19-11
View Snapshot
Recorded Revisions (7):
R25-11 rel:R25-11#212e3e742026-09-30 Inspect R20-11 rel:R20-11#4d8b55b62026-10-14 Inspect R21-11 rel:R21-11#ea1c0d632026-10-14 Inspect R22-11 rel:R22-11#20de23fe2026-10-14 Inspect R23-11 rel:R23-11#ef0c633f2026-10-14 Inspect R24-11 rel:R24-11#5d07b21d2026-10-14 Inspect R25-11 rel:R25-11#0403ec612026-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
bool IsEof () const noexcept;
Checks if the current position is at end of file.
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Rückgabewert
Typ Beschreibung bool True if the current position is at the end of the file, false otherwise.
Status: valid/unmigrated
Version: rel:R25-11#1ea53dae
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_PER_00107@rel:R25-11#1ea53dae
Point-in-Time History:
Release:
R25-11 (Current / Active) R19-11 R20-11 R21-11 R22-11 R23-11 R24-11
View Snapshot
Recorded Revisions (8):
R25-11 rel:R25-11#a72969de2026-09-30 Inspect R19-11 rel:R19-11#a79d80012026-10-14 Inspect R20-11 rel:R20-11#6fb143982026-10-14 Inspect R21-11 rel:R21-11#6fb143982026-10-14 Inspect R22-11 rel:R22-11#a37547212026-10-14 Inspect R23-11 rel:R23-11#a3e1b2842026-10-14 Inspect R24-11 rel:R24-11#b7d2c0c02026-10-14 Inspect R25-11 rel:R25-11#1ea53dae2026-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
ara::core::Result < std::uint64_t > MovePosition (Origin origin, std::int64_t offset) noexcept;
Moves the current position in the file relative to the Origin. In case of an error, the current position is not changed.
用户指南
AI 生成
未审核
模型: gemini-3.8-flash-medium · 推理强度: medium · 温度: 不可控 · 提示词: 436bd0736ae4
来源
此文本由 AI 系统创建,并由 autodocs 整理。
实现者指南即将推出(复杂度 I1)
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Parameter (in)
Parameter Beschreibung origin Starting point from which to move ’offset’ bytes. offset Offset in bytes relative to ’origin’. Can be positive in case of k Beginning and kCurrent and negative in case of kCurrent and k End. In case of kCurrent, an offset of zero will not change the current position. In case of kEnd, an offset of zero will set the position to the end of the file.
Rückgabewert
Typ Beschreibung ara::core::Result <std::uint64_t >A Result containing the new position in bytes from the beginning of the file. In case of an error, it contains any of the errors defined below, or a vendor specific error.
Fehler
Fehlercode Beschreibung PerErrc ::kInvalidPositionrollback_semantics Returned if the resulting position is lower than zero or beyond the end of the file.
Status: valid/unmigrated
Version: rel:R25-11#ccd6513c
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_PER_00164@rel:R25-11#ccd6513c
Point-in-Time History:
Release:
R25-11 (Current / Active) R19-11 R20-11 R21-11 R22-11 R23-11 R24-11
View Snapshot
Recorded Revisions (8):
R25-11 rel:R25-11#66a724ef2026-09-30 Inspect R19-11 rel:R19-11#73c3e07f2026-10-14 Inspect R20-11 rel:R20-11#4c68dcef2026-10-14 Inspect R21-11 rel:R21-11#824627d92026-10-14 Inspect R22-11 rel:R22-11#838d6e5d2026-10-14 Inspect R23-11 rel:R23-11#129626382026-10-14 Inspect R24-11 rel:R24-11#8245580d2026-10-14 Inspect R25-11 rel:R25-11#ccd6513c2026-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
ara::core::Result < void > SetPosition (std::uint64_t position) noexcept;
Sets the current position relative to the beginning of the file. In case of an error, the current position is not changed.
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Parameter (in)
Parameter Beschreibung position Current position in the file in bytes from the beginning of the file.
Rückgabewert
Typ Beschreibung ara::core::Result < void >A Result of void. In case of an error, it contains any of the errors defined below, or a vendor specific error.
Fehler
Fehlercode Beschreibung PerErrc ::kInvalidPositionrollback_semantics Returned if the given position is beyond the end of the file.
Status: valid/unmigrated
Version: rel:R25-11#70153a82
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_PER_00163@rel:R25-11#70153a82
Point-in-Time History:
Release:
R25-11 (Current / Active) R19-11 R20-11 R21-11 R22-11 R23-11 R24-11
View Snapshot
Recorded Revisions (8):
R25-11 rel:R25-11#758322e02026-09-30 Inspect R19-11 rel:R19-11#1942368c2026-10-14 Inspect R20-11 rel:R20-11#84c129222026-10-14 Inspect R21-11 rel:R21-11#3b14f9b62026-10-14 Inspect R22-11 rel:R22-11#932ec6d22026-10-14 Inspect R23-11 rel:R23-11#f53627272026-10-14 Inspect R24-11 rel:R24-11#b6f855cb2026-10-14 Inspect R25-11 rel:R25-11#70153a822026-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
FileAccessor & operator= (FileAccessor &&ra)=delete;
The move assignment operator for FileAccessor shall not be used.
Status: valid/unmigrated
Version: rel:R25-11#74c045de
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_PER_00591@rel:R25-11#74c045de
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
FileAccessor & operator= (const FileAccessor &)=delete;
The copy assignment operator for FileAccessor shall not be used.
Status: valid/unmigrated
Version: rel:R25-11#01ebcde1
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_PER_00593@rel:R25-11#01ebcde1
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
virtual ~FileAccessor () noexcept;
Destructor for FileAccessor.
Header-Datei #include "ara/per/file_accessor.h" Scope class ara::per::FileAccessor Exception-Sicherheit exception safe Thread-Sicherheit not thread-safe
Status: valid/unmigrated
Version: rel:R25-11#f4cbf0b1
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_PER_00594@rel:R25-11#f4cbf0b1
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 · 德文原文