shadowing static class method

1 次查看(过去 30 天)
Pieter van den Berg
Is it possible to shadow a static class method of a builtin class? E.g. suppose that there is a class
in .../MATLAB/.../toolbox/.../@foo/foo.m
classdef foo
...
methods(Hidden = true, Static = true, Access = 'public')
function obj = loadobj(x)
...
end
end
end
can I shadow the loadobj method somehow? I tried creating a file @foo/foo.m in my path with only the static method in it but that doesn't seem to work.
cheers,
Pieter
  2 个评论
per isakson
per isakson 2013-9-22
编辑:per isakson 2013-9-22
Remark on nomenclature: foo in your example is not a builtin class. Doc says
A built-in function is part of the *MATLAB executable*. MATLAB does not
implement these functions in the MATLAB language. Although most built-in
functions have a .m file associated with them, this file only supplies
documentation for the function.
Nevertheless, your question is easily understood. AFAIK: the answer is no.
Pieter van den Berg
Ok, thanks! I think you are right.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Whos 的更多信息

标签

产品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by