CPD报告代码重复。
Catching code duplication with CPD.
用CPD捕捉代码重复。
Notice any code duplication there?
注意是否有任何代码复制的现象?
This is to avoid code duplication.
这避免了代码副本的出现。
Is this considered code duplication?
这是被认为是重复的代码?
This helps you avoid code duplication.
这可帮助您避免代码重复问题。
PMD's CPD: Enables discovering code duplication
PMD的CPD:帮助发现代码重复
Reducing code duplication in the data access tier.
减少数据访问层中的代码重复。
CPD: a freely available code duplication tool from the PMD team.
CPD:来自PMD小组的免费代码复制工具。
But the problem with this approach is, it will introduce code duplication and related issues.
但是,这种方法是,将推出代码重复的问题和有关问题。
This enabled me to avoid code duplication more elegantly than I could have with a procedural language.
这使得我可以避免代码重复,从而比使用过程语言更为优雅。
There's a bit of code duplication in the Person class, but I'll leave that for a later refactoring exercise.
在person类中有一些重复的代码,但我把它留给稍后的重构练习。
Named templates are particularly useful for dividing your code into smaller chunks and avoiding code duplication.
命名模板对于将代码划分为较小的区块、避免代码内容重复非常有用。
The generic DAO pattern (also called Typesafe DAO) is critical to reducing code duplication in the data access tier.
泛型dao模式(也称为类型安全的DAO)对于减少数据访问层中的代码重复非常重要。
And just as code duplication can make a software program more difficult to maintain, so too does duplicate code in build scripts.
代码复制令软件程序更难于维护,同理,构建脚本中的复制代码也存在这样的问题。
The measure for finding duplicated code is to search for code duplication within classes and among other classes in the code base.
查找重复代码的度量方法是在代码库中的类的内部和其他类之间搜索代码重复。
There is a lot of code duplication, significant overlap of data in the database, etc. According to Neal, that is typically happening
有很多代码冗余,数据库里的数据也存在严重的重叠,等等。
At first glance, this strategy seems like a good idea — code duplication is a bad thing, so consolidating these duplicated paths should be an improvement.
乍一看,该策略似乎是一个好方法——但代码副本有错误,所以整合这些复制路径应该是一种改进。
You can reduce code duplication by abstracting the common behavior and including it in the generic DAO, where all users of the class will have access to the functionality.
提取通用行为并把它们包含在泛型DAO 中,让类的所有用户通过泛型 DAO访问这些功能,这样就可以减少代码重复。
This logic in the session bean will force the clients to always do the right thing, ensuring consistency in the application and preventing code duplication at the client side.
会话bean中的这个逻辑将强制客户机一直做正确的事情,确保应用程序中的一致性并防止客户端的代码重复。
By using a static analysis tool such as PMD's CPD or CheckStyle, you can determine areas of high code duplication on a continual basis as part of running an automated build.
使用诸如pmd的CPD或CheckStyle这样的静态分析工具,您能够将整个分析过程作为自动构建的一部分,持续分析,确定代码重复度高的区域。
This article's code examples (see Download to obtain the full package) show how to use these interfaces to facilitate auditing and reduce code duplication in data access objects (DAOs).
本文的代码示例(在下载中可以获得完整的代码包)演示如何使用这些接口帮助执行审计和减少数据访问对象(DAO)中的代码重复。
This rule, and the rule to do one thing, are both corollaries of an underlying principle: avoid duplication of code whenever possible.
这条规则,以及做好一件事情的规则,都是一个根本原理的必然结果:无论何时都要尽可能避免代码重复。
Duplication harms projects because it resists attempts to make structural changes or refactor toward better code.
复制对项目有害,因为它不利于做出结构更改或重构为更好的代码。
Duplication in code obscures the design because you can't find idiomatic patterns.
代码复制使设计变得更加模糊,因为您无法找到惯用模式。
This kind of structure is an example of a bad "code smell" in that it relies upon duplication.
这种结构是坏“代码味道”的一个例子,原因在于它依赖于复制。
This can be tedious to maintain because it imposes a duplication of code.
这样维护起来会非常繁琐,因为代码是重复的。
This can be tedious to maintain because it imposes a duplication of code.
这样维护起来会非常繁琐,因为代码是重复的。
应用推荐