333-1-9

for (int i = 0; i < this.rangeAxes.size(); i++) { ValueAxis axis = (ValueAxis) this.rangeAxes.get(i); if (axis != null) { axis.removeChangeListener(this); } } this.rangeAxes.clear(); fireChangeEvent();
for (int i = 0; i < this.data.size(); i++) { XYIntervalSeries series = (XYIntervalSeries) this.data.get(i); series.removeChangeListener(this); } this.data.clear(); fireDatasetChanged();

Clone fragments detected by clone detection tool
File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/CategoryPlot.java |  | File path: /jfreechart-1.0.10/src/org/jfree/data/xy/XYIntervalSeriesCollection.java
Method name: `void clearRangeAxes()` |  | Method name: `void removeAllSeries()`
Number of AST nodes: 6 |  | Number of AST nodes: 5

1

    for (int i = 0; i < this.rangeAxes.size(); i++) {↵

1

    for (int i = 0; i < this.data.size(); i++) {↵

2

                ValueAxis axis = (ValueAxis) this.rangeAxes.get(i);↵

2

              ↵

3

                if (axis != null) {↵

4

                    axi↵

3

    XYIntervalSeries series = (XYIntervalSeries) this.data.get(i);↵

5

    s.removeChangeListener(this);↵

4

              series.removeChangeListener(this);↵

6

                }↵

5

            }↵

7

            }↵

6

            ↵

8

            this.rangeAxes.clear();↵

7

    this.data.clear();↵

9

            fireChangeEvent();

8

            fireDatasetChanged();

See real code fragment |  | See real code fragment

Summary
Number of common nesting structure subtrees | 0
Number of refactorable cases | 0
Number of non-refactorable cases | 0
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0
Clones location | Clones are in different classes
Number of node comparisons | 1