AP_autosar_core_note

Core module

Feature - Types
  • 重新定义了部分C++ 11的std库中的类型
    • std中的类型的内存分别在汽车领域不完全适用(the memory allocation behavior of std:: types is often not suitable for automative purposes)
    • 重新定义类型的内存分配和异常处理等(the ara::core ones define their own memory allocation behavior and perform some other necessary adaptions)
  • Static Containers: ara::core::array 等同于 std::array
  • Dynamic Containers
    • ara::core::vector 等同于 std::vector
    • ara::core::map 等同于 std::map
    • ara::core::String 等同于 std::basic_string
  • View Containers
    • ara::core::StringView 等同于 std::basic_string_view
    • ara::core::Span 等同于 std::span
  • Union Containers
    • ara::core::Variant 等同于 std::variant
  • Others
    • ara::core::Optional 近似 std::optional
    • ara::core::Byte 近似 std::byte
    • ara::InstanceSpecifier: 识别模型中的服务接口类型
Feature - Functions
  • 异常处理
    • Corruption: 资源异常
    • Violation: 违背API需求(pre/post-conditions)
    • Errors: 执行失败
      • ErrorCode: 枚举
      • ErrorDomain: 对ErrorCode扩展,可自定义
  • 同步函数调用: Result(Error/Value)
  • 异步函数调用: ara::core::Future/Promise, 功能类似于std::future/promise
  • 初始化和下电: ara::core::initialize/ara::core::deinitialize
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值