if ( !propertiesFile.exists() ) {
throw new BuildException("Properties file: " + propertiesFile + " does not exist.");
}
log("Using properties file " + propertiesFile, Project.MSG_DEBUG);
this.propertiesFile = propertiesFile;
if ( !propertiesFile.exists() ) {
throw new BuildException("Properties file: " + propertiesFile + " does not exist.");
}
log("Using properties file " + propertiesFile, Project.MSG_DEBUG);
this.propertiesFile = propertiesFile;
Clone fragments detected by clone detection tool
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tool/hbm2ddl/SchemaExportTask.java
|
|
File path: /hibernate-distribution-3.3.2.GA/project/core/src/main/java/org/hibernate/tool/hbm2ddl/SchemaValidatorTask.java
|
Method name: void setProperties(File)
|
|
Method name: void setProperties(File)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | if ( !propertiesFile.exists() ) {↵ | | 1 | if ( !propertiesFile.exists() ) {↵
|
2 | throw new BuildException("Properties file: " + propertiesFile + " does not exist.");↵ | | 2 | throw new BuildException("Properties file: " + propertiesFile + " does not exist.");↵
|
3 | }↵ | | 3 | }↵
|
|
4 | log("Using properties file " + propertiesFile, Project.MSG_DEBUG);↵ | | 4 | log("Using properties file " + propertiesFile, Project.MSG_DEBUG);↵
|
5 | this.propertiesFile = propertiesFile; | | 5 | this.propertiesFile = propertiesFile;
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 6 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.6 |
Clone type | Type 1 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
1 | if (!propertiesFile.exists()) | | 1 | if (!propertiesFile.exists()) |
2 | throw new BuildException("Properties file: " + propertiesFile + " does not exist."); | | 2 | throw new BuildException("Properties file: " + propertiesFile + " does not exist."); |
3 | log("Using properties file " + propertiesFile, Project.MSG_DEBUG); | | 3 | log("Using properties file " + propertiesFile, Project.MSG_DEBUG); |
4 | this.propertiesFile = propertiesFile; | | 4 | this.propertiesFile = propertiesFile; |
Precondition Violations (0)
Row |
Violation |