"meng long" <menglong6518@yeah.net> wrote in message
news:hd3esd$8i9$1@fred.mathworks.com...
> In classdef block, there are a static methods block
>
> methods (Static)
> oPath = CrHPath(dCdPrdt);
This needs to be the declaration of a function CrHPath:
methods (Static)
function oPath = CrHPath(dCdPrdt)
% fill in the implementation of CrHPath
end
end
"Steven Lord" <slord@mathworks.com> wrote in message <hd7l5k$m75$1@fred.mathworks.com>...
>
> "meng long" <menglong6518@yeah.net> wrote in message
> news:hd3esd$8i9$1@fred.mathworks.com...
> > In classdef block, there are a static methods block
> >
> > methods (Static)
> > oPath = CrHPath(dCdPrdt);
>
> This needs to be the declaration of a function CrHPath:
>
> methods (Static)
> function oPath = CrHPath(dCdPrdt)
> % fill in the implementation of CrHPath
> end
> end
>
> *snip*
>
> --
> Steve Lord
> slord@mathworks.com
> comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
> Dear Mt. Steven Lord
thanks for your answer.
As mentined in matlab_document, it is allowd that a static method can be defined in "method block" by only attribute, and its body is defined in @ directory.
I must define many static methods. Each static method has coded more than 50 rows.
It is not convient to write code as your mentioned.
NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for
all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content.
Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available
via MATLAB Central.
Read the complete Terms prior to use.