MATLAB Data API for C++
MATLAB Data API 为在 MATLAB 外部运行的应用程序提供了一种方法,可通过独立于 MATLAB 的接口来处理 MATLAB 数据。此 API 使用现代 C++ 语义和设计模式,并通过使用 MATLAB 的写入时复制 (copy-on-write) 语义来尽可能地避免数据复制。
注意
MATLAB Data API 支持现代 C++ 功能,但与 C Matrix API 不兼容。您不能在 MEX 文件中将来自 MATLAB Data API 的函数与来自 C Matrix API 和 C MEX API 的函数混合使用。同样,您不能将 MATLAB Data API 函数与 从 C 调用 MATLAB 中所述的 C Engine API 函数或 编写 C 程序以读取 MAT 文件数据 中所述的 C MAT-File API 函数混合使用。
类
主题
- Create Arrays with C++ MATLAB Data API
Create MATLAB array.
- Copy C++ MATLAB Data Arrays
The
matlab::data::Array
class supports both copy and move semantics. - Access C++ Data Array Container Elements
The C++ MATLAB Data API
CellArray
andStructArray
types are containers for other MATLAB Data Arrays. - C++ Cell Arrays
To create a cell array, use the
matlab::data::ArrayFactory
createCellArray
function. - Operate on C++ Arrays Using Visitor Pattern
The visitor design pattern is a useful technique for performing various operations on arrays.
- MATLAB Data API Random Access Iterators
The MATLAB Data API provides random access iterators based on the C++ language specification.
- MATLAB Data API Exceptions
The MATLAB Data API defines specific exception classes for MATLAB.
- MATLAB Data API Types
The MATLAB Data API defines specific types for working with MATLAB.