Create entity type and define attributes in custom entity generator using Matlab discrete event system
1 回表示 (過去 30 日間)
古いコメントを表示
Hi, I want to create a custom entity generator using Matlab discrete event system but I can't find any documentation of how you define which attributes the entity generated in a MDES has?
Example: I want to generate entities which have attributes x and y in a MDES and then define their respective value in a generate event.
0 件のコメント
回答 (1 件)
Abdolkarim Mohammadi
2022 年 4 月 7 日
編集済み: Abdolkarim Mohammadi
2022 年 4 月 7 日
You must set the attribute in the Generate event action.
function [entity,events] = generate(obj,storage,entity,tag)
entity.data.Attribute1 = 1;
events = [];
end
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Discrete-Event Simulation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!