File path: /jfreechart-1.0.10/tests/org/jfree/data/time/junit/TimeSeriesCollectionTests.java | File path: /jfreechart-1.0.10/tests/org/jfree/data/time/ohlc/junit/OHLCSeriesCollectionTests.java | |||
Method name: void test1170825()
|
Method name: void test1170825()
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | TimeSeries s1 = new TimeSeries("Series1");↵ | 1 | OHLCSeries s1 = new OHLCSeries("Series1");↵ | |
2 | TimeSeriesCollection dataset = new TimeSeriesCollection();↵ | 2 | OHLCSeriesCollection dataset = new OHLCSeriesCollection();↵ | |
3 | dataset.addSeries(s1);↵ | 3 | dataset.addSeries(s1);↵ | |
4 | try {↵ | 4 | try {↵ | |
5 | /* TimeSeries s = */ dataset.getSeries(1); | 5 | /* XYSeries s = */ dataset.getSeries(1); | |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 5 |
Number of mapped statements | 3 |
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) | 0.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | TimeSeries s1 = new TimeSeries("Series1"); |
| 1 | OHLCSeries s1 = new OHLCSeries("Series1"); | ||||||||||||||||||
2 | TimeSeriesCollection dataset = new TimeSeriesCollection(); |
| 2 | OHLCSeriesCollection dataset = new OHLCSeriesCollection(); | ||||||||||||||||||
3 | dataset.addSeries(s1); |
| 3 | dataset.addSeries(s1); |
Row | Violation |
---|---|
1 | Expression new TimeSeries("Series1") cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression new TimeSeriesCollection() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression new OHLCSeriesCollection() cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression s1 cannot be unified with expression s1 , because common superclass type org.jfree.data.general.Series cannot be passed as an argument to public void addSeries(org.jfree.data.time.TimeSeries) |
5 | Expression dataset cannot be unified with expression dataset , because common superclass org.jfree.data.xy.AbstractXYDataset does not declare member(s) public void addSeries(org.jfree.data.time.TimeSeries) , public void addSeries(org.jfree.data.time.ohlc.OHLCSeries) |
6 | Clone fragment #1 returns variable dataset with type org.jfree.data.time.TimeSeriesCollection , while Clone fragment #2 returns variable dataset with type org.jfree.data.time.ohlc.OHLCSeriesCollection |