Selfdestruction of an object
4 ビュー (過去 30 日間)
古いコメントを表示
Hey,
is it possible to make an object destroy itself and how?
0 件のコメント
採用された回答
Walter Roberson
2022 年 3 月 12 日
If you have a handle object, then when it is constructed, or upon any relevant event, it can create a timer that does a delete() of the object. This will affect all places that have a copy of the handle.
If you have a value object, then NO, the most you could do would be to destroy a copy of the object, but all the other copies would be intact.
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Get Started with Optimization Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!