I suggest you use the meta information provided by the MCOS class system:
>> class = ?containers.Map;
>> method = class.MethodList({mclass.MethodList.Name} == "subsref");
>> method.InputNames
ans =
2×1 cell array
'A'
'S'
>> method.OutputNames
ans =
cell
'B'
It is reliable in most cases except when your class definition uses the old-style @ folder or if you query a non-MCOS class such as a Java class or such. On the side note, the accepted answer will not work for a qualified class such as above, which just shows that the NARGIN/NARGOUT functions are function-oriented are have not been adapted for the MCOS class system.
0 Comments
Sign in to comment.