File path: /jfreechart-1.0.10/src/org/jfree/data/category/DefaultIntervalCategoryDataset.java | File path: /jfreechart-1.0.10/src/org/jfree/data/category/DefaultIntervalCategoryDataset.java | |||
Method name: Number getValue(Comparable, Comparable)
|
Method name: Number getStartValue(Comparable, Comparable)
|
|||
Number of AST nodes: 7 | Number of AST nodes: 7 | |||
1 | int seriesIndex = getSeriesIndex(series);↵ | 1 | int seriesIndex = getSeriesIndex(series);↵ | |
2 | if (seriesIndex < 0) {↵ | 2 | if (seriesIndex < 0) {↵ | |
3 | throw new UnknownKeyException("Unknown 'series' key.");↵ | 3 | throw new UnknownKeyException("Unknown 'series' key.");↵ | |
4 | }↵ | 4 | }↵ | |
5 | int itemIndex = getColumnIndex(category);↵ | 5 | int itemIndex = getColumnIndex(category);↵ | |
6 | if (itemIndex < 0) {↵ | 6 | if (itemIndex < 0) {↵ | |
7 | throw new UnknownKeyException("Unknown 'category' key.");↵ | 7 | throw new UnknownKeyException("Unknown 'category' key.");↵ | |
8 | }↵ | 8 | }↵ | |
9 | return getValue(seriesIndex, itemIndex); | 9 | return getStartValue(seriesIndex, itemIndex); | |
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.2 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 22 |
Number of mapped statements | 7 |
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) | 2.7 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | int seriesIndex = getSeriesIndex(series); | 1 | int seriesIndex = getSeriesIndex(series); | |||||||||||||
2 | if (seriesIndex < 0) | 2 | if (seriesIndex < 0) | |||||||||||||
3 | throw new UnknownKeyException("Unknown 'series' key."); | 3 | throw new UnknownKeyException("Unknown 'series' key."); | |||||||||||||
4 | int itemIndex = getColumnIndex(category); | 4 | int itemIndex = getColumnIndex(category); | |||||||||||||
5 | if (itemIndex < 0) | 5 | if (itemIndex < 0) | |||||||||||||
6 | throw new UnknownKeyException("Unknown 'category' key."); | 6 | throw new UnknownKeyException("Unknown 'category' key."); | |||||||||||||
7 | return getValue(seriesIndex, itemIndex); |
| 7 | return getStartValue(seriesIndex, itemIndex); |
Row | Violation |
---|---|
1 | Expression getValue(seriesIndex,itemIndex) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression getStartValue(seriesIndex,itemIndex) cannot be parameterized, because it has dependencies to/from statements that will be extracted |