if (src == null && dir == null) {
String message = "Either the file or the dir attribute "
+ "must be specified";
throw new BuildException(message, getLocation());
}
if (token == null && replacefilters.size() == 0) {
String message = "Either token or a nested replacefilter "
+ "must be specified";
throw new BuildException(message, getLocation());
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Replace.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Replace.java
|
Method name: void validateAttributes()
|
|
Method name: void validateAttributes()
|
Number of AST nodes: 3
|
|
Number of AST nodes: 3
|
|
1 | if (src == null && dir == null) {↵ | | 1 | if (token == null && replacefilters.size() == 0) {↵
|
2 | String message = "Either the file or the dir attribute "↵ | | 2 | String message = "Either token or a nested replacefilter "↵
|
3 | + "must be specified";↵ | | 3 | + "must be specified";↵
|
4 | throw new BuildException(message, getLocation());↵ | | 4 | throw new BuildException(message, getLocation());↵
|
5 | } | | 5 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 1 |