CloneSet243


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
16210.996method_declaration
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
116176
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/tests/org/jfree/chart/plot/junit/CombinedDomainCategoryPlotTests.java
216177
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/tests/org/jfree/chart/plot/junit/CombinedRangeCategoryPlotTests.java
Next
Last
Clone Instance
1
Line Count
16
Source Line
176
Source File
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/tests/org/jfree/chart/plot/junit/CombinedDomainCategoryPlotTests.java

/**
 * Check that only one chart change event is generated by a change to a
 * subplot.
 */
public void testNotification() {
  CombinedDomainCategoryPlot plot = createPlot();
  JFreeChart chart = new JFreeChart(plot);
  chart.addChangeListener(this );
  CategoryPlot subplot1 = (CategoryPlot) plot.getSubplots().get(0);
  NumberAxis yAxis = (NumberAxis) subplot1.getRangeAxis();
  yAxis.setAutoRangeIncludesZero( !yAxis.getAutoRangeIncludesZero());
  assertEquals(1, this.events.size());
  // a redraw should NOT trigger another change event
  BufferedImage image = new BufferedImage(200, 100, BufferedImage.TYPE_INT_RGB);
  Graphics2D g2 = image.createGraphics();
  this.events.clear();
  chart.draw(g2, new Rectangle2D.Double(0.0, 0.0, 200.0, 100.0));
  assertTrue(this.events.isEmpty());
}


First
Previous
Clone Instance
2
Line Count
16
Source Line
177
Source File
E:/TSE/Projects-CloneDR/jfreechart-1.0.10/tests/org/jfree/chart/plot/junit/CombinedRangeCategoryPlotTests.java

/**
 * Check that only one chart change event is generated by a change to a
 * subplot.
 */
public void testNotification() {
  CombinedRangeCategoryPlot plot = createPlot();
  JFreeChart chart = new JFreeChart(plot);
  chart.addChangeListener(this );
  CategoryPlot subplot1 = (CategoryPlot) plot.getSubplots().get(0);
  NumberAxis yAxis = (NumberAxis) subplot1.getRangeAxis();
  yAxis.setAutoRangeIncludesZero( !yAxis.getAutoRangeIncludesZero());
  assertEquals(1, this.events.size());
  // a redraw should NOT trigger another change event
  BufferedImage image = new BufferedImage(200, 100, BufferedImage.TYPE_INT_RGB);
  Graphics2D g2 = image.createGraphics();
  this.events.clear();
  chart.draw(g2, new Rectangle2D.Double(0.0, 0.0, 200.0, 100.0));
  assertTrue(this.events.isEmpty());
}


Clone AbstractionParameter Count: 1Parameter Bindings

/**
     * Check that only one chart change event is generated by a change to a
     * subplot.
     */
public void testNotification() {
   [[#variable1a8baba0]] plot = createPlot();
  JFreeChart chart = new JFreeChart(plot);
  chart.addChangeListener(this );
  CategoryPlot subplot1 = (CategoryPlot) plot.getSubplots().get(0);
  NumberAxis yAxis = (NumberAxis) subplot1.getRangeAxis();
  yAxis.setAutoRangeIncludesZero( !yAxis.getAutoRangeIncludesZero());
  assertEquals(1, this.events.size());
  // a redraw should NOT trigger another change event
  BufferedImage image = new BufferedImage(200, 100, BufferedImage.TYPE_INT_RGB);
  Graphics2D g2 = image.createGraphics();
  this.events.clear();
  chart.draw(g2, new Rectangle2D.Double(0.0, 0.0, 200.0, 100.0));
  assertTrue(this.events.isEmpty());
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#1a8baba0]]
CombinedDomainCategoryPlot 
12[[#1a8baba0]]
CombinedRangeCategoryPlot