![]() |
MATLAB帮助内容的一种抽象方法
在普通的类方法中,我可以为MATLAB中的“ help”命令提供内容。但是,在编写抽象方法时,帮助功能看不到抽象方法。例如,如果您有一个NeedsHelp类:
classdef NeedsHelp methods (Abstract) INeedHelp(self) % This method is not visible to the help command. end methods function IHaveHelp(self) % This method shows help as expected. end end end 帮助命令的行为如下(R2009b): >> help NeedsHelp.IHaveHelp This method shows help as expected. >> help NeedsHelp.INeedHelp NeedsHelp.INeedHelp not found. 是否有提供抽象方法文档的解决方案? 回答: 根据Loren在MathWorks上的博客,看来从R2009b开始这是不可能的。看到[URL="http://blogs.mathworks.com/loren/2006/06/07/publishing/#comment-30683"]此评论和她的回复[/URL] 。 [url=https://stackoverflow.com/questions/1925222]更多&回答...[/url] |
所有时间均为北京时间。现在的时间是 01:18。 |
Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.