class2struct

バージョン 1.2.0.0 (1.42 KB) 作成者: Ofek
Strip all class methods, leaving just the bare data as struct fields
ダウンロード: 54
更新 2016/9/11

ライセンスの表示

Often one comes across the need to strip a class down to its bare data - in particular in contexts of serializing/deserializing, and working with it across external interfaces.
Matlab's built in struct(cls) doesn't suffice, as the class can have properties that are classes themselves. Hence, this small utility.
Please say if it helps you, and more importantly - if it doesn't.
Doesn't require any fancy new functionality - probably works in 2009+ versions, but I'm unable to test.

引用

Ofek (2026). class2struct (https://jp.mathworks.com/matlabcentral/fileexchange/58426-class2struct), MATLAB Central File Exchange. 取得日: .

MATLAB リリースの互換性
作成: R2016a
すべてのリリースと互換性あり
プラットフォームの互換性
Windows macOS Linux
カテゴリ
Help Center および MATLAB AnswersData Type Conversion についてさらに検索
タグ タグを追加
バージョン 公開済み リリース ノート
1.2.0.0

Fixed shape of embedded cell arrays and matrices
fix name

1.1.0.0

Documentation added and warnings handled

1.0.0.0