File path: /sql12/plugins/graph/src/net/sourceforge/squirrel_sql/plugins/graph/ConstraintData.java | File path: /sql12/plugins/graph/src/net/sourceforge/squirrel_sql/plugins/graph/ConstraintData.java | |||
Method name: String[] getDDL()
|
Method name: String[] getDDL()
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | for (int i = 0; i < _columnInfos.length; i++)↵ | 1 | for (int i = 0; i < _columnInfos.length; i++)↵ | |
2 | {↵ | 2 | {↵ | |
3 | if(i < _columnInfos.length -1)↵ | 3 | if(i < _columnInfos.length -1)↵ | |
4 | {↵ | 4 | {↵ | |
5 | ret.add(" " + _columnInfos[i].getName() + ",");↵ | 5 | ret.add(" " + _columnInfos[i].getImportedColumnName() + ",");↵ | |
6 | }↵ | 6 | }↵ | |
7 | else↵ | 7 | else↵ | |
8 | {↵ | 8 | {↵ | |
9 | ret.add(" " + _columnInfos[i].getName());↵ | 9 | ret.add(" " + _columnInfos[i].getImportedColumnName());↵ | |
10 | }↵ | 10 | }↵ | |
11 | } | 11 |
| |
See real code fragment | See real code fragment |
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.5 |
Clones location | Clones are in the same method |
Number of node comparisons | 13 |
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) | 7.8 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
20 | for (int i = 0; i < _columnInfos.length; i++) | 27 | for (int i = 0; i < _columnInfos.length; i++) | |||||||||||||
21 | if (i < _columnInfos.length - 1) | 28 | if (i < _columnInfos.length - 1) | |||||||||||||
22 | ret.add(" " + _columnInfos[i].getName() + ","); |
| 29 | ret.add(" " + _columnInfos[i].getImportedColumnName() + ","); | ||||||||||||
else | else | |||||||||||||||
23 | ret.add(" " + _columnInfos[i].getName()); |
| 30 | ret.add(" " + _columnInfos[i].getImportedColumnName()); |
Row | Violation |
---|---|
1 | Expression _columnInfos[i].getName() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression _columnInfos[i].getImportedColumnName() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression _columnInfos[i].getName() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression _columnInfos[i].getImportedColumnName() cannot be parameterized, because it has dependencies to/from statements that will be extracted |