classes and the "set" method
Ältere Kommentare anzeigen
Hi,
I am trying to write a class in Matlab and I am new to it, sorry that I probably don't use the correct terminology. In a basic example, I would like to have data structured in this way:
classdef DummyBasic
properties
av = 1;
end
methods
end
end
and
classdef Dummy
properties
X = 0;
a = DummyBasic;
end
methods
end
end
Now, I would like to change X whenever a.av is changed. I guess it would be easy to do if a rearranged the properties X and av to a single class. But is it possible to somehow keep this structure (I am using Matlab2015b)?
Any help appreciated.
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Class Introspection and Metadata finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!