Eclipse+PMD插件分析代码规则(中文).xlsVIP

  1. 1、本文档共20页,可阅读全部内容。
  2. 2、有哪些信誉好的足球投注网站(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
  5. 5、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
  6. 6、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们
  7. 7、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
  8. 8、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
EclipsePMD插件分析代码规则(中文),pmdeclipse插件,pmdeclipse插件下载,eclipse代码统计插件,eclipse代码生成插件,eclipse代码折叠插件,eclipse代码检查插件,eclipse代码提示插件,eclipse代码补全插件,eclipse代码分析插件

Sheet4 Sheet3 Sheet2 Sheet1 A switch with less than 3 branches is inefficient, use a if statement instead. 一个少于3个分支的switch语句是低效率的,应使用if语句。 Swith are designed complex branches, and allow branches to share treatement. Using a switch for only 2 branches is ill advised, as switches are not as easy to understand as if. In this case, its most likely is a good idea to use a if statement instead, at least to increase code readability. Avoid really long classes. 避免多长的类。 ExcessiveMethodLength Avoid really long methods. 避免过长函数。 Violations of this rule usually indicate that the method is doing too much. Try to reduce the method size by creating helper methods and removing any copy/pasted code. ExcessiveParameterList Avoid really long parameter lists. 过长参数列可以表明应该创建一个新的对象来封装众多的参数。从根本上来说,尝试对参数进行集合。 Long parameter lists can indicate that a new object should be created to wrap the numerous parameters. Basically, try to group the parameters together. TooManyFields Too many fields 太多的类变量 有太多类变量的类应被重新设计为含有少量的类变量,可能通过嵌套对象对信息归类。 例如,一个类包含有城市/国家/邮编成员变量应以地址类变量类代替。 Classes that have too many fields could be redesigned to have fewer fields, possibly through some nested object grouping of some of the information. For example, a class with city/state/zip fields could instead have one Address field. TooManyMethods This class has too many methods,consider refacting it. 这个类包含了太多的方法,考虑重构它。 在构造函数中调用父类 CheckResultSet Always check the return of one of the navigation method(next,previous,first,last) of a ResultSet. 始终检查记录集中的导航方法的返回记录(下一条,上一条,第一条,最后一条) Always check the return of one of the navigation method (next,previous,first,last) of a ResultSet. Indeed, if the value return is false, the developer should deal with it ! 函数/方法{0}()的执行路径复杂度是{0} The NPath complexity of a method is the number of acyclic execution paths through that method. A threshold of 200 is generally considered the point where measures should be taken to reduce complexity. Assigning an Object to null is a code smell. Consider r

文档评论(0)

wdhao + 关注
实名认证
文档贡献者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档