File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/PiePlot.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/PiePlot3D.java | |||
Method name: void drawPie(Graphics2D, Rectangle2D, PlotRenderingInfo)
|
Method name: void draw(Graphics2D, Rectangle2D, Point2D, PlotState, PlotRenderingInfo)
|
|||
Number of AST nodes: 9 | Number of AST nodes: 9 | |||
1 | if (DEBUG_DRAW_INTERIOR) {↵ | 1 | if (DEBUG_DRAW_INTERIOR) {↵ | |
2 | double hGap = plotArea.getWidth() * this.interiorGap;↵ | 2 | double hGap = plotArea.getWidth() * getInteriorGap();↵ | |
3 | double vGap = plotArea.getHeight() * this.interiorGap;↵ | 3 | double vGap = plotArea.getHeight() * getInteriorGap↵ | |
4 | ↵ | 4 | ();↵ | |
5 | double igx1 = plotArea.getX() + hGap;↵ | 5 | double igx1 = plotArea.getX() + hGap;↵ | |
6 | double igx2 = plotArea.getMaxX() - hGap;↵ | 6 | double igx2 = plotArea.getMaxX() - hGap;↵ | |
7 | double igy1 = plotArea.getY() + vGap;↵ | 7 | double igy1 = plotArea.getY() + vGap;↵ | |
8 | double igy2 = plotArea.getMaxY() - vGap;↵ | 8 | double igy2 = plotArea.getMaxY() - vGap;↵ | |
9 | g2.setPaint(Color.gray);↵ | 9 | g2.setPaint(Color.lightGray);↵ | |
10 | g2.draw(new Rectangle2D.Double(igx1, igy1, igx2 - igx1, ↵ | 10 | g2.draw(new Rectangle2D.Double(igx1, igy1, igx2 - igx1, ↵ | |
11 | igy2 - igy1));↵ | 11 | igy2 - igy1));↵ | |
12 | } | 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.1 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 81 |
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) | 35.4 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
7 | if (DEBUG_DRAW_INTERIOR) | 16 | if (DEBUG_DRAW_INTERIOR) | |||||||||||||||||||
8 | double hGap = plotArea.getWidth() * this.interiorGap; |
| 17 | double hGap = plotArea.getWidth() * getInteriorGap(); | ||||||||||||||||||
9 | double vGap = plotArea.getHeight() * this.interiorGap; |
| 18 | double vGap = plotArea.getHeight() * getInteriorGap(); | ||||||||||||||||||
10 | double igx1 = plotArea.getX() + hGap; | 19 | double igx1 = plotArea.getX() + hGap; | |||||||||||||||||||
11 | double igx2 = plotArea.getMaxX() - hGap; | 20 | double igx2 = plotArea.getMaxX() - hGap; | |||||||||||||||||||
12 | double igy1 = plotArea.getY() + vGap; |
| 22 | double igy2 = plotArea.getMaxY() - vGap; | ||||||||||||||||||
13 | double igy2 = plotArea.getMaxY() - vGap; |
| 21 | double igy1 = plotArea.getY() + vGap; | ||||||||||||||||||
14 | g2.setPaint(Color.gray); |
| 23 | g2.setPaint(Color.lightGray); | ||||||||||||||||||
15 | g2.draw(new Rectangle2D.Double(igx1, igy1, igx2 - igx1, igy2 - igy1)); | 24 | g2.draw(new Rectangle2D.Double(igx1, igy1, igx2 - igx1, igy2 - igy1)); |
Row | Violation |
---|---|
1 | Expression plotArea.getY() + vGap cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression plotArea.getMaxY() - vGap cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression plotArea.getMaxY() - vGap cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression plotArea.getY() + vGap cannot be parameterized, because it has dependencies to/from statements that will be extracted |