File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/CombinedDomainCategoryPlot.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/CombinedRangeXYPlot.java | |||
Method name: CategoryPlot findSubplot(PlotRenderingInfo, Point2D)
|
Method name: XYPlot findSubplot(PlotRenderingInfo, Point2D)
|
|||
Number of AST nodes: 9 | Number of AST nodes: 9 | |||
1 | if (info == null) {↵ | 1 | if (info == null) {↵ | |
2 | throw new IllegalArgumentException("Null 'info' argument.");↵ | 2 | throw new IllegalArgumentException("Null 'info' argument.");↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (source == null) {↵ | 4 | if (source == null) {↵ | |
5 | throw new IllegalArgumentException("Null 'source' argument.");↵ | 5 | throw new IllegalArgumentException("Null 'source' argument.");↵ | |
6 | }↵ | 6 | }↵ | |
7 | CategoryPlot result = null;↵ | 7 | XYPlot result = null;↵ | |
8 | int subplotIndex = info.getSubplotIndex(source);↵ | 8 | int subplotIndex = info.getSubplotIndex(source);↵ | |
9 | if (subplotIndex >= 0) {↵ | 9 | if (subplotIndex >= 0) {↵ | |
10 | result = (CategoryPlot) this.subplots.get(subplotIndex);↵ | 10 | result = (XYPlot) this.subplots.get(subplotIndex);↵ | |
11 | }↵ | 11 | }↵ | |
12 | return result; | 12 |
| |
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.6 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 30 |
Number of mapped statements | 9 |
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) | 9.4 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (info == null) | 1 | if (info == null) | ||||||||||||||||
2 | throw new IllegalArgumentException("Null 'info' argument."); | 2 | throw new IllegalArgumentException("Null 'info' argument."); | ||||||||||||||||
3 | if (source == null) | 3 | if (source == null) | ||||||||||||||||
4 | throw new IllegalArgumentException("Null 'source' argument."); | 4 | throw new IllegalArgumentException("Null 'source' argument."); | ||||||||||||||||
5 | CategoryPlot result = null; |
| 5 | XYPlot result = null; | |||||||||||||||
6 | int subplotIndex = info.getSubplotIndex(source); | 6 | int subplotIndex = info.getSubplotIndex(source); | ||||||||||||||||
7 | if (subplotIndex >= 0) | 7 | if (subplotIndex >= 0) | ||||||||||||||||
8 | result = (CategoryPlot)this.subplots.get(subplotIndex); |
| 8 | result = (XYPlot)this.subplots.get(subplotIndex); | |||||||||||||||
9 | return result; |
| 9 | return result; |
Row | Violation |
---|---|
1 | Expression (CategoryPlot)this.subplots.get(subplotIndex) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression (XYPlot)this.subplots.get(subplotIndex) cannot be parameterized, because it has dependencies to/from statements that will be extracted |