nus-yam/ex-repair huggingface dataset:
Program: 65979
Project: 65979
Buggy source:
public void widgetSelected(SelectionEvent e){
  if (e.getSource() instanceof CTabFolder) {
    String taskId=(String)e.item.getData();
    int indexLabel=this.wizardBase.vTaskIDs.indexOf(taskId);
    if (indexLabel >= 0) {
      this.wizardBase.switchTo(taskId);
      getButton(IDialogConstants.NEXT_ID).setEnabled(indexLabel < this.wizardBase.vTaskIDs.size() - 1);
      getButton(IDialogConstants.BACK_ID).setEnabled(indexLabel > 0);
    }
  }
 else   if (e.getSource() instanceof Button) {
    if (wizardBase.getTabToolButtons().contains(((Button)e.getSource()).getData())) {
      IButtonHandler btnHandle=(IButtonHandler)((Button)e.getSource()).getData();
      btnHandle.run();
    }
  }
}

Fixed version (ground truth):
public void widgetSelected(SelectionEvent e){
  if (e.getSource() instanceof CTabFolder) {
    String taskId=(String)e.item.getData();
    int indexLabel=this.wizardBase.vTaskIDs.indexOf(taskId);
    if (indexLabel >= 0) {
      this.wizardBase.switchTo(taskId);
      getButton(IDialogConstants.NEXT_ID).setEnabled(indexLabel < this.wizardBase.vTaskIDs.size() - 1);
      getButton(IDialogConstants.BACK_ID).setEnabled(indexLabel > 0);
    }
  }
 else   if (e.getSource() instanceof ToolItem) {
    if (wizardBase.getTabToolButtons().contains(((ToolItem)e.getSource()).getData())) {
      IButtonHandler btnHandle=(IButtonHandler)((ToolItem)e.getSource()).getData();
      btnHandle.run();
    }
  }
}
Program: 65980
Project: 65980
Buggy source:
protected void createTabToolButtons(CTabFolder tabFolder){
  List<IButtonHandler> buttons=wizardBase.getTabToolButtons();
  if (buttons.size() == 0) {
    return;
  }
  Composite comp=new Composite(tabFolder,SWT.NONE);
  tabFolder.setTopRight(comp);
  GridLayout gl=new GridLayout(buttons.size(),false);
  gl.marginBottom=0;
  gl.marginHeight=0;
  gl.marginLeft=0;
  gl.marginRight=0;
  gl.marginTop=0;
  gl.marginWidth=0;
  comp.setLayout(gl);
  for (  IButtonHandler btnHandler : buttons) {
    Button btn=new Button(comp,SWT.NONE);
    GridData gd=new GridData();
    btn.setLayoutData(gd);
    btn.addSelectionListener(this);
    btn.setData(btnHandler);
    if (btnHandler.getLabel() != null) {
      btn.setText(btnHandler.getLabel());
    }
    if (btnHandler.getTooltip() != null) {
      btn.setToolTipText(btnHandler.getTooltip());
    }
    if (btnHandler.getIcon() != null) {
      btn.setImage(btnHandler.getIcon());
    }
    btnHandler.setButton(btn);
  }
}

Fixed version (ground truth):
protected void createTabToolButtons(CTabFolder tabFolder){
  List<IButtonHandler> buttons=wizardBase.getTabToolButtons();
  if (buttons.size() == 0) {
    return;
  }
  ToolBar toolbar=new ToolBar(tabFolder,SWT.FLAT | SWT.WRAP);
  tabFolder.setTopRight(toolbar);
  for (  IButtonHandler btnHandler : buttons) {
    ToolItem btn=new ToolItem(toolbar,SWT.NONE);
    btn.addSelectionListener(this);
    btn.setData(btnHandler);
    if (btnHandler.getLabel() != null) {
      btn.setText(btnHandler.getLabel());
    }
    if (btnHandler.getTooltip() != null) {
      btn.setToolTipText(btnHandler.getTooltip());
    }
    if (btnHandler.getIcon() != null) {
      btn.setImage(btnHandler.getIcon());
    }
  }
}
Program: 65981
Project: 65981
Buggy source:
/** 
 * @param context
 * @throws DataException 
 */
public StreamManager(DataEngineContext context,QueryResultInfo queryResultInfo) throws DataException {
  this.context=context;
  this.rootQueryResultID=queryResultInfo.getRootQueryResultID();
  this.parentQueryResultID=queryResultInfo.getParentQueryResultID();
  this.selfQueryResultID=queryResultInfo.getSelfQueryResultID();
  this.subQueryName=queryResultInfo.getSubQueryName();
  this.subQueryID=subQueryName == null ? null : QueryResultIDUtil.buildSubQueryID(subQueryName,queryResultInfo.getIndex());
  this.cachedStreamManagers=new HashMap();
  this.metaManagers=new HashMap();
  this.dataMetaManagers=new HashMap();
  VersionManager vm=new VersionManager(context);
  if (context.getMode() == DataEngineContext.MODE_GENERATION) {
    this.version=vm.getVersion();
    if (this.version == VersionManager.VERSION_2_0)     this.version=VersionManager.getLatestVersion();
    vm.setVersion(this.version);
  }
 else   if (context.getMode() == DataEngineContext.MODE_UPDATE && this.rootQueryResultID == null) {
    if (this.context.hasInStream(null,null,DataEngineContext.VERSION_INFO_STREAM) == false) {
      this.version=VersionManager.getLatestVersion();
    }
 else     this.version=vm.getVersion();
  }
 else {
    this.version=vm.getVersion();
  }
}

Fixed version (ground truth):
/** 
 * @param context
 * @throws DataException 
 */
public StreamManager(DataEngineContext context,QueryResultInfo queryResultInfo) throws DataException {
  this.context=context;
  this.rootQueryResultID=queryResultInfo.getRootQueryResultID();
  this.parentQueryResultID=queryResultInfo.getParentQueryResultID();
  this.selfQueryResultID=queryResultInfo.getSelfQueryResultID();
  this.subQueryName=queryResultInfo.getSubQueryName();
  this.subQueryID=subQueryName == null ? null : QueryResultIDUtil.buildSubQueryID(subQueryName,queryResultInfo.getIndex());
  this.cachedStreamManagers=new HashMap();
  this.metaManagers=new HashMap();
  this.dataMetaManagers=new HashMap();
  VersionManager vm=new VersionManager(context);
  if (context.getMode() == DataEngineContext.MODE_GENERATION) {
    this.version=vm.getVersion();
    if (this.version == VersionManager.VERSION_2_0)     this.version=VersionManager.getLatestVersion();
    vm.setVersion(this.version);
  }
 else   if (context.getMode() == DataEngineContext.MODE_UPDATE && this.rootQueryResultID == null) {
    if (this.context.hasInStream(null,null,DataEngineContext.VERSION_INFO_STREAM) == false) {
      this.version=VersionManager.getLatestVersion();
      vm.setVersion(this.version);
    }
 else     this.version=vm.getVersion();
  }
 else {
    this.version=vm.getVersion();
  }
}
Program: 65982
Project: 65982
Buggy source:
public void widgetSelected(SelectionEvent e){
  if (e.getSource() instanceof CTabFolder) {
    String taskId=(String)e.item.getData();
    int indexLabel=this.wizardBase.vTaskIDs.indexOf(taskId);
    if (indexLabel >= 0) {
      this.wizardBase.switchTo(taskId);
      getButton(IDialogConstants.NEXT_ID).setEnabled(indexLabel < this.wizardBase.vTaskIDs.size() - 1);
      getButton(IDialogConstants.BACK_ID).setEnabled(indexLabel > 0);
    }
  }
}

Fixed version (ground truth):
public void widgetSelected(SelectionEvent e){
  if (e.getSource() instanceof CTabFolder) {
    String taskId=(String)e.item.getData();
    int indexLabel=this.wizardBase.vTaskIDs.indexOf(taskId);
    if (indexLabel >= 0) {
      this.wizardBase.switchTo(taskId);
      getButton(IDialogConstants.NEXT_ID).setEnabled(indexLabel < this.wizardBase.vTaskIDs.size() - 1);
      getButton(IDialogConstants.BACK_ID).setEnabled(indexLabel > 0);
    }
  }
 else   if (e.getSource() instanceof Button) {
    if (wizardBase.getTabToolButtons().contains(((Button)e.getSource()).getData())) {
      IButtonHandler btnHandle=(IButtonHandler)((Button)e.getSource()).getData();
      btnHandle.run();
    }
  }
}
Program: 65983
Project: 65983
Buggy source:
protected Control createDialogArea(Composite parent){
  Composite composite=new Composite(parent,SWT.NONE);
{
    GridLayout layout=new GridLayout();
    layout.marginHeight=0;
    layout.marginWidth=0;
    layout.verticalSpacing=0;
    layout.horizontalSpacing=0;
    composite.setLayout(layout);
    composite.setLayoutData(new GridData(GridData.FILL_BOTH));
    composite.setFont(parent.getFont());
  }
  Label lblSeparator=new Label(composite,SWT.SEPARATOR | SWT.HORIZONTAL);
  lblSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
  cmpTaskContainer=new CTabFolder(composite,SWT.TOP | SWT.FLAT);
{
    cmpTaskContainer.setLayoutData(new GridData(GridData.FILL_BOTH));
    cmpTaskContainer.setTabHeight(25);
    cmpTaskContainer.addSelectionListener(this);
  }
  lblSeparator=new Label(composite,SWT.SEPARATOR | SWT.HORIZONTAL);
  lblSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
  return composite;
}

Fixed version (ground truth):
protected Control createDialogArea(Composite parent){
  Composite composite=new Composite(parent,SWT.NONE);
{
    GridLayout layout=new GridLayout();
    layout.marginHeight=0;
    layout.marginWidth=0;
    layout.verticalSpacing=0;
    layout.horizontalSpacing=0;
    composite.setLayout(layout);
    composite.setLayoutData(new GridData(GridData.FILL_BOTH));
    composite.setFont(parent.getFont());
  }
  Label lblSeparator=new Label(composite,SWT.SEPARATOR | SWT.HORIZONTAL);
  lblSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
  cmpTaskContainer=new CTabFolder(composite,SWT.TOP | SWT.FLAT);
{
    cmpTaskContainer.setLayoutData(new GridData(GridData.FILL_BOTH));
    cmpTaskContainer.setTabHeight(25);
    cmpTaskContainer.addSelectionListener(this);
  }
  createTabToolButtons(cmpTaskContainer);
  lblSeparator=new Label(composite,SWT.SEPARATOR | SWT.HORIZONTAL);
  lblSeparator.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
  return composite;
}
Program: 65984
Project: 65984
Buggy source:
public boolean isEnabled(){
  return !DEUtil.isReferenceElement(measureViewHandle.getCrosstabHandle());
}

Fixed version (ground truth):
public boolean isEnabled(){
  CubeHandle cubeHandle=measureViewHandle.getCrosstab().getCube();
  if (cubeHandle == null) {
    return false;
  }
  return !DEUtil.isReferenceElement(measureViewHandle.getCrosstabHandle());
}
Program: 65985
Project: 65985
Buggy source:
public boolean isEnabled(){
  return !DEUtil.isReferenceElement(measureViewHandle.getCrosstabHandle());
}

Fixed version (ground truth):
public boolean isEnabled(){
  CubeHandle cubeHandle=measureViewHandle.getCrosstab().getCube();
  if (cubeHandle == null) {
    return false;
  }
  return !DEUtil.isReferenceElement(measureViewHandle.getCrosstabHandle());
}
Program: 65986
Project: 65986
Buggy source:
public Object get(String arg0,Scriptable scope){
  try {
    if (ScriptConstants.OUTER_RESULT_KEYWORD.equals(arg0))     return cursor.getObject(ScriptConstants.OUTER_RESULT_KEYWORD);
    return cursor.getObject(arg0);
  }
 catch (  OLAPException e) {
    throw Context.reportRuntimeError(e.getLocalizedMessage());
  }
}

Fixed version (ground truth):
public Object get(int arg0,Scriptable scope){
  try {
    return cursor.getObject(String.valueOf(arg0));
  }
 catch (  OLAPException e) {
    throw Context.reportRuntimeError(e.getLocalizedMessage());
  }
}
Program: 65987
Project: 65987
Buggy source:
/** 
 * Returns instance of default value chart.
 * @return
 */
public Chart getDefaultValueChart(){
  return this.defaultValueChart;
}

Fixed version (ground truth):
/** 
 * Returns instance of default value chart.
 * @return instance of default value chart.
 */
public Chart getDefaultValueChart(){
  return this.defaultValueChart;
}
Program: 65988
Project: 65988
Buggy source:
/** 
 * @param x
 * @param y
 * @param z
 * @return
 */
public static Angle3D create(double x,double y,double z){
  final Angle3DImpl angle=new Angle3DImpl();
  angle.xAngle=x;
  angle.xAngleESet=true;
  angle.yAngle=y;
  angle.yAngleESet=true;
  angle.zAngle=z;
  angle.zAngleESet=true;
  angle.type=AngleType.NONE_LITERAL;
  angle.typeESet=true;
  return angle;
}

Fixed version (ground truth):
/** 
 * @param x
 * @param y
 * @param z
 * @return instance of <code>Angle3D</code>.
 */
public static Angle3D create(double x,double y,double z){
  final Angle3DImpl angle=new Angle3DImpl();
  angle.xAngle=x;
  angle.xAngleESet=true;
  angle.yAngle=y;
  angle.yAngleESet=true;
  angle.zAngle=z;
  angle.zAngleESet=true;
  angle.type=AngleType.NONE_LITERAL;
  angle.typeESet=true;
  return angle;
}
Program: 65989
Project: 65989
Buggy source:
/** 
 * Returns a curveFitting instance.
 * @return
 */
public static CurveFitting create(){
  final CurveFitting cf=ComponentFactory.eINSTANCE.createCurveFitting();
  ((CurveFittingImpl)cf).initialize();
  return cf;
}

Fixed version (ground truth):
/** 
 * Returns a curveFitting instance.
 * @return instance of <code>CurveFitting</code>.
 */
public static CurveFitting create(){
  final CurveFitting cf=ComponentFactory.eINSTANCE.createCurveFitting();
  ((CurveFittingImpl)cf).initialize();
  return cf;
}
Program: 65990
Project: 65990
Buggy source:
/** 
 * @return
 */
public static final DialRegion create(){
  DialRegion dr=ComponentFactory.eINSTANCE.createDialRegion();
  ((DialRegionImpl)dr).initialize();
  return dr;
}

Fixed version (ground truth):
/** 
 * @return instance of <code>DialRegion</code>.
 */
public static final DialRegion create(){
  DialRegion dr=ComponentFactory.eINSTANCE.createDialRegion();
  ((DialRegionImpl)dr).initialize();
  return dr;
}
Program: 65991
Project: 65991
Buggy source:
/** 
 * @return
 */
public static final Needle create(){
  Needle nl=ComponentFactory.eINSTANCE.createNeedle();
  ((NeedleImpl)nl).initialize();
  return nl;
}

Fixed version (ground truth):
/** 
 * @return instance of <code>Needle</code>.
 */
public static final Needle create(){
  Needle nl=ComponentFactory.eINSTANCE.createNeedle();
  ((NeedleImpl)nl).initialize();
  return nl;
}
Program: 65992
Project: 65992
Buggy source:
/** 
 * @return
 */
public static final Needle createDefault(){
  Needle nl=ComponentFactory.eINSTANCE.createNeedle();
  ((NeedleImpl)nl).initDefault();
  return nl;
}

Fixed version (ground truth):
/** 
 * @return instance of <code>Needle</code> without setting 'isSet' flag.
 */
public static final Needle createDefault(){
  Needle nl=ComponentFactory.eINSTANCE.createNeedle();
  ((NeedleImpl)nl).initDefault();
  return nl;
}
Program: 65993
Project: 65993
Buggy source:
/** 
 * Creates instance of default value chart according to specified chart type.
 * @param cm
 * @return chart instance with default values.
 */
public static Chart createDefaultValueChartInstance(Chart cm){
  Chart instance=null;
  if (cm instanceof DialChart) {
    instance=DefaultValueProvider.defDialChart().copyInstance();
  }
 else   if (cm instanceof ChartWithoutAxes) {
    instance=DefaultValueProvider.defChartWithoutAxes().copyInstance();
  }
 else {
    instance=DefaultValueProvider.defChartWithAxes().copyInstance();
  }
  SeriesDefinition sd=ChartUtil.getOrthogonalSeriesDefinitions(instance,0).get(0);
  List<Series> seriesList=sd.getSeries();
  seriesList.clear();
  if (instance instanceof ChartWithAxes) {
    seriesList.add(DefaultValueProvider.defBarSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defBubbleSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defScatterSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defDifferenceSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defAreaSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defLineSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defGanttSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defStockSeries().copyInstance());
  }
 else {
    seriesList.add(DefaultValueProvider.defDialSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defPieSeries().copyInstance());
  }
  return instance;
}

Fixed version (ground truth):
/** 
 * Creates instance of default value chart according to specified chart type.
 * @param cm
 * @return chart instance with default values.
 */
public static Chart createDefaultValueChartInstance(Chart cm){
  Chart instance=getDefaultValueChart(cm).copyInstance();
  SeriesDefinition sd=ChartUtil.getOrthogonalSeriesDefinitions(instance,0).get(0);
  List<Series> seriesList=sd.getSeries();
  seriesList.clear();
  if (instance instanceof ChartWithAxes) {
    seriesList.add(DefaultValueProvider.defBarSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defBubbleSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defScatterSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defDifferenceSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defAreaSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defLineSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defGanttSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defStockSeries().copyInstance());
  }
 else {
    seriesList.add(DefaultValueProvider.defDialSeries().copyInstance());
    seriesList.add(DefaultValueProvider.defPieSeries().copyInstance());
  }
  return instance;
}
Program: 65996
Project: 65996
Buggy source:
public RadarCategoryLabelSheet(String title,ChartWizardContext context,boolean needRefresh,RadarSeries series){
  super(title,context,needRefresh);
  this.series=series;
}

Fixed version (ground truth):
public RadarCategoryLabelSheet(String title,ChartWizardContext context,boolean needRefresh,RadarSeries series){
  super(title,context,needRefresh);
  this.series=series;
  this.defSeries=(RadarSeries)ChartDefaultValueUtil.getDefaultSeries(series);
}
Program: 65998
Project: 65998
Buggy source:
@Override public int compareTo(Members other){
  for (int i=0; i < members.length; i++) {
    int result=members[i].compareTo(other.members[i]);
    if (result != 0) {
      return result;
    }
  }
  return 0;
}

Fixed version (ground truth):
public int compareTo(Members other){
  for (int i=0; i < members.length; i++) {
    int result=members[i].compareTo(other.members[i]);
    if (result != 0) {
      return result;
    }
  }
  return 0;
}
Program: 66003
Project: 66003
Buggy source:
protected void createLabelSpan(Composite cmpBasic){
  if (getChart().getDimension().getValue() != ChartDimension.THREE_DIMENSIONAL) {
    Label l=new Label(cmpBasic,SWT.NONE);
    l.setText(Messages.getString("String_Node_Str"));
    FieldAssistHelper.getInstance().addRequiredFieldIndicator(l);
    Composite cmpEditorWithUnit=new Composite(cmpBasic,SWT.NONE);
{
      GridData gd=new GridData();
      gd.widthHint=250;
      cmpEditorWithUnit.setLayoutData(gd);
      GridLayout layout=new GridLayout(2,false);
      layout.marginWidth=0;
      layout.marginHeight=0;
      cmpEditorWithUnit.setLayout(layout);
    }
    lneLabelSpan=new LocalizedNumberEditorComposite(cmpEditorWithUnit,SWT.BORDER);
    new TextNumberEditorAssistField(lneLabelSpan.getTextControl(),null);
{
      lneLabelSpan.setValue(getAxisForProcessing().getLabelSpan());
      lneLabelSpan.addModifyListener(this);
      GridData gd=new GridData(GridData.FILL_HORIZONTAL);
      gd.horizontalIndent=5;
      lneLabelSpan.setLayoutData(gd);
      lneLabelSpan.setEnabled(getAxisForProcessing().isSetLabelSpan());
    }
    new Label(cmpEditorWithUnit,SWT.NONE).setText(Messages.getString("String_Node_Str"));
    btnFixLabelSpan=new Button(cmpBasic,SWT.CHECK);
{
      btnFixLabelSpan.setText(Messages.getString("String_Node_Str"));
      btnFixLabelSpan.addSelectionListener(this);
      btnFixLabelSpan.setSelection(getAxisForProcessing().isSetLabelSpan());
    }
  }
}

Fixed version (ground truth):
protected void createLabelSpan(Composite cmpBasic){
  if (!isChart3D()) {
    Label l=new Label(cmpBasic,SWT.NONE);
    l.setText(Messages.getString("String_Node_Str"));
    FieldAssistHelper.getInstance().addRequiredFieldIndicator(l);
    Composite cmpEditorWithUnit=new Composite(cmpBasic,SWT.NONE);
{
      GridData gd=new GridData();
      gd.widthHint=250;
      cmpEditorWithUnit.setLayoutData(gd);
      GridLayout layout=new GridLayout(2,false);
      layout.marginWidth=0;
      layout.marginHeight=0;
      cmpEditorWithUnit.setLayout(layout);
    }
    lneLabelSpan=new LocalizedNumberEditorComposite(cmpEditorWithUnit,SWT.BORDER);
    new TextNumberEditorAssistField(lneLabelSpan.getTextControl(),null);
{
      lneLabelSpan.setValue(getAxisForProcessing().getLabelSpan());
      lneLabelSpan.addModifyListener(this);
      GridData gd=new GridData(GridData.FILL_HORIZONTAL);
      gd.horizontalIndent=5;
      lneLabelSpan.setLayoutData(gd);
      lneLabelSpan.setEnabled(getAxisForProcessing().isSetLabelSpan());
    }
    new Label(cmpEditorWithUnit,SWT.NONE).setText(Messages.getString("String_Node_Str"));
    btnFixLabelSpan=new Button(cmpBasic,SWT.CHECK);
{
      btnFixLabelSpan.setText(Messages.getString("String_Node_Str"));
      btnFixLabelSpan.addSelectionListener(this);
      btnFixLabelSpan.setSelection(getAxisForProcessing().isSetLabelSpan());
    }
  }
}
Program: 66004
Project: 66004
Buggy source:
private void populateLists(){
  NameSet ns=LiteralHelper.axisTypeSet;
  if (getAxisAngleType() == AngleType.Y) {
    ns=ChartUIUtil.getCompatibleAxisType(getAxisForProcessing().getSeriesDefinitions().get(0).getDesignTimeSeries());
  }
  cmbTypes.setItems(ChartUIExtensionUtil.getItemsWithAuto(ns.getDisplayNames()));
  String[] names=ns.getNames();
  cmbTypes.setData(KEY_TYPE_NAMES,names);
  if (!getAxisForProcessing().isSetType()) {
    cmbTypes.select(0);
  }
 else {
    cmbTypes.setText(ns.getDisplayNameByName(getAxisForProcessing().getType().getName()));
  }
  if (getChart().getDimension().getValue() != ChartDimension.THREE_DIMENSIONAL) {
    ns=LiteralHelper.intersectionTypeSet;
    cmbOrigin.setItems(ChartUIExtensionUtil.getItemsWithAuto(ns.getDisplayNames()));
    if (!getAxisForProcessing().getOrigin().isSetType()) {
      cmbOrigin.select(0);
    }
 else {
      cmbOrigin.select(ns.getSafeNameIndex(getAxisForProcessing().getOrigin().getType().getName()) + 1);
    }
  }
  if (txtValue != null && getAxisForProcessing().getOrigin().getType().equals(IntersectionType.VALUE_LITERAL)) {
    txtValue.setDataElement(getAxisForProcessing().getOrigin().getValue());
  }
}

Fixed version (ground truth):
private void populateLists(){
  NameSet ns=LiteralHelper.axisTypeSet;
  if (getAxisAngleType() == AngleType.Y) {
    ns=ChartUIUtil.getCompatibleAxisType(getAxisForProcessing().getSeriesDefinitions().get(0).getDesignTimeSeries());
  }
  cmbTypes.setItems(ChartUIExtensionUtil.getItemsWithAuto(ns.getDisplayNames()));
  String[] names=ns.getNames();
  cmbTypes.setData(KEY_TYPE_NAMES,names);
  if (!getAxisForProcessing().isSetType()) {
    cmbTypes.select(0);
  }
 else {
    cmbTypes.setText(ns.getDisplayNameByName(getAxisForProcessing().getType().getName()));
  }
  if (!isChart3D()) {
    ns=LiteralHelper.intersectionTypeSet;
    cmbOrigin.setItems(ChartUIExtensionUtil.getItemsWithAuto(ns.getDisplayNames()));
    if (!getAxisForProcessing().getOrigin().isSetType()) {
      cmbOrigin.select(0);
    }
 else {
      cmbOrigin.select(ns.getSafeNameIndex(getAxisForProcessing().getOrigin().getType().getName()) + 1);
    }
  }
  if (txtValue != null && getAxisForProcessing().getOrigin().getType().equals(IntersectionType.VALUE_LITERAL)) {
    txtValue.setDataElement(getAxisForProcessing().getOrigin().getValue());
  }
}
Program: 66007
Project: 66007
Buggy source:
public final IReportItem copy(){
  final ChartReportItemImpl crii=new ChartReportItemImpl(handle);
  crii.bCopied=true;
  if (!ChartCubeUtil.isAxisChart(handle)) {
    if (cm == null) {
      crii.cm=null;
    }
 else {
synchronized (this) {
        try {
          crii.cm=cm.copyInstance();
        }
 catch (        ConcurrentModificationException e) {
          crii.cm=cm.copyInstance();
        }
catch (        NullPointerException e) {
          crii.cm=cm.copyInstance();
        }
      }
    }
  }
  return crii;
}

Fixed version (ground truth):
public final IReportItem copy(){
  final ChartReportItemImpl crii=(ChartReportItemImpl)ChartReportItemUtil.instanceChartReportItem(handle);
  crii.bCopied=true;
  if (!ChartCubeUtil.isAxisChart(handle)) {
    if (cm == null) {
      crii.cm=null;
    }
 else {
synchronized (this) {
        try {
          crii.cm=cm.copyInstance();
        }
 catch (        ConcurrentModificationException e) {
          crii.cm=cm.copyInstance();
        }
catch (        NullPointerException e) {
          crii.cm=cm.copyInstance();
        }
      }
    }
  }
  return crii;
}
Program: 66008
Project: 66008
Buggy source:
private String getTitleText(){
  if (getChart().getTitle().isAuto()) {
    return getContext().getUIFactory().createUIHelper().getDefaultTitle(getContext());
  }
  String title=getChart().getTitle().getLabel().getCaption().getValue();
  return (title == null) ? "String_Node_Str" : title;
}

Fixed version (ground truth):
private String getTitleText(){
  if (getChart().getTitle().isAuto() && getContext().getExtendedItem() != null) {
    return getContext().getUIFactory().createUIHelper().getDefaultTitle(getContext());
  }
  String title=getChart().getTitle().getLabel().getCaption().getValue();
  return (title == null) ? "String_Node_Str" : title;
}
Program: 66009
Project: 66009
Buggy source:
protected String getTrendlineText(){
  if (getTrendline().getLabel().getCaption().getValue() == null) {
    return "String_Node_Str";
  }
  return getTrendline().getLabel().getCaption().getValue();
}

Fixed version (ground truth):
protected String getTrendlineText(){
  if (getTrendline().getLabel().getCaption() == null) {
    Text caption=CurveFittingImpl.createDefault().getLabel().getCaption();
    getTrendline().getLabel().setCaption(caption);
    caption.eAdapters().addAll(getTrendline().getLabel().eAdapters());
  }
  if (getTrendline().getLabel().getCaption().getValue() == null) {
    return "String_Node_Str";
  }
  return getTrendline().getLabel().getCaption().getValue();
}
Program: 66012
Project: 66012
Buggy source:
public void testTrailing18() throws IOException {
  int[] values=new int[]{2011,1,0,53};
  String[] types=new String[]{TimeMember.TIME_LEVEL_TYPE_YEAR,TimeMember.TIME_LEVEL_TYPE_MONTH,TimeMember.TIME_LEVEL_TYPE_WEEK_OF_MONTH,TimeMember.TIME_LEVEL_TYPE_WEEK_OF_YEAR};
  TimeMember timeMember=new TimeMember(values,types);
  IPeriodsFunction periodsFunction=TimeFunctionFactory.createTrailingFunction(TimeMember.TIME_LEVEL_TYPE_WEEK_OF_YEAR,-3);
  ReferenceDate referenceDate=new ReferenceDate(new Date(2011,8,28));
  List<TimeMember> timeMembers=periodsFunction.getResult(timeMember);
  printMembers(timeMembers);
  checkOutputFile();
}

Fixed version (ground truth):
public void testTrailing18() throws IOException {
  int[] values=new int[]{2011,1,0,52};
  String[] types=new String[]{TimeMember.TIME_LEVEL_TYPE_YEAR,TimeMember.TIME_LEVEL_TYPE_MONTH,TimeMember.TIME_LEVEL_TYPE_WEEK_OF_MONTH,TimeMember.TIME_LEVEL_TYPE_WEEK_OF_YEAR};
  TimeMember timeMember=new TimeMember(values,types);
  IPeriodsFunction periodsFunction=TimeFunctionFactory.createTrailingFunction(TimeMember.TIME_LEVEL_TYPE_WEEK_OF_YEAR,-3);
  ReferenceDate referenceDate=new ReferenceDate(new Date(2011,8,28));
  List<TimeMember> timeMembers=periodsFunction.getResult(timeMember);
  printMembers(timeMembers);
  checkOutputFile();
}
Program: 66014
Project: 66014
Buggy source:
/** 
 * @throws IOException 
 */
private void setTimeDataType() throws IOException {
  TimeResultRow timeResultRow=null;
  int[] timeAggregationDataType=null;
  for (int i=0; i < this.timeResultSet.size(); i++) {
    timeResultRow=(TimeResultRow)timeResultSet.get(0);
    if (timeResultRow.getValue() == null)     continue;
    boolean existUnknown=false;
    if (timeAggregationDataType == null)     timeAggregationDataType=new int[timeResultRow.getValue().length];
    for (int j=0; j < timeResultRow.getValue().length; j++) {
      if (timeAggregationDataType[j] == DataType.UNKNOWN_TYPE) {
        if (timeResultRow.getValue()[j] != null)         timeAggregationDataType[j]=DataType.getDataType(timeResultRow.getValue()[j].getClass());
 else         existUnknown=true;
      }
    }
    if (!existUnknown) {
      break;
    }
  }
  int[] newAggregationDataType=new int[aggregationDataType.length + timeAggregationDataType.length];
  System.arraycopy(aggregationDataType,0,newAggregationDataType,0,aggregationDataType.length);
  System.arraycopy(timeAggregationDataType,0,newAggregationDataType,aggregationDataType.length,timeAggregationDataType.length);
  aggregationDataType=newAggregationDataType;
}

Fixed version (ground truth):
/** 
 * @throws IOException 
 */
private void setTimeDataType() throws IOException {
  TimeResultRow timeResultRow=null;
  int[] timeAggregationDataType=null;
  for (int i=0; i < this.timeResultSet.size(); i++) {
    timeResultRow=(TimeResultRow)timeResultSet.get(0);
    if (timeResultRow.getValue() == null)     continue;
    boolean existUnknown=false;
    if (timeAggregationDataType == null)     timeAggregationDataType=new int[timeResultRow.getValue().length];
    for (int j=0; j < timeResultRow.getValue().length; j++) {
      if (timeAggregationDataType[j] == DataType.UNKNOWN_TYPE) {
        if (timeResultRow.getValue()[j] != null)         timeAggregationDataType[j]=DataType.getDataType(timeResultRow.getValue()[j].getClass());
 else         existUnknown=true;
      }
    }
    if (!existUnknown) {
      break;
    }
  }
}
Program: 66015
Project: 66015
Buggy source:
@SuppressWarnings("String_Node_Str") private void initBindings(ICubeQueryDefinition cubeQuery,CubeHandle cube) throws BirtException {
  for (Iterator<ComputedColumnHandle> bindings=ChartReportItemUtil.getAllColumnBindingsIterator(handle); bindings.hasNext(); ) {
    ComputedColumnHandle column=bindings.next();
    IBinding binding=new Binding(column.getName());
    binding.setDataType(DataAdapterUtil.adaptModelDataType(column.getDataType()));
    binding.setAggrFunction(column.getAggregateFunction() == null ? null : DataAdapterUtil.adaptModelAggregationType(column.getAggregateFunction()));
    ChartItemUtil.loadExpression(exprCodec,column);
    binding.setExpression(ChartReportItemUtil.adaptExpression(exprCodec,modelAdapter,true));
    List<String> lstAggOn=column.getAggregateOnList();
    if (column.getExpression() == null || !bSingleChart && !lstAggOn.isEmpty()) {
      addAggregateOn(binding,lstAggOn,cubeQuery,cube);
    }
    registeredBindings.put(binding.getBindingName(),binding);
    registeredQueries.put(binding.getBindingName(),exprCodec.encode());
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private void initBindings(ICubeQueryDefinition cubeQuery,CubeHandle cube) throws BirtException {
  for (Iterator<ComputedColumnHandle> bindings=ChartReportItemUtil.getAllColumnBindingsIterator(handle); bindings.hasNext(); ) {
    ComputedColumnHandle column=bindings.next();
    IBinding binding=new Binding(column.getName());
    binding.setDataType(DataAdapterUtil.adaptModelDataType(column.getDataType()));
    binding.setAggrFunction(column.getAggregateFunction() == null ? null : DataAdapterUtil.adaptModelAggregationType(column.getAggregateFunction()));
    if (modelAdapter instanceof ModelAdapter) {
      binding.setTimeFunction(((ModelAdapter)modelAdapter).adaptTimeFunction(column));
    }
    ChartItemUtil.loadExpression(exprCodec,column);
    binding.setExpression(ChartReportItemUtil.adaptExpression(exprCodec,modelAdapter,true));
    List<String> lstAggOn=column.getAggregateOnList();
    if (column.getExpression() == null || !bSingleChart && !lstAggOn.isEmpty()) {
      addAggregateOn(binding,lstAggOn,cubeQuery,cube);
    }
    registeredBindings.put(binding.getBindingName(),binding);
    registeredQueries.put(binding.getBindingName(),exprCodec.encode());
  }
}
Program: 66016
Project: 66016
Buggy source:
private ITimeFunction adaptTimeFunction(ComputedColumnHandle handle) throws DataException, BirtException {
  if (handle.getCalculationType() == null || handle.getCalculationType().trim().length() == 0)   return null;
  TimeFunction timeFunction=new TimeFunction();
  Object referenceDate=null;
  if (DesignChoiceConstants.REFERENCE_DATE_TYPE_TODAY.equals(handle.getReferenceDateType())) {
    referenceDate=ScriptEvalUtil.evalExpr(new ScriptExpression("String_Node_Str"),this.context.getDataEngineContext().getScriptContext(),"String_Node_Str",0);
  }
 else   if (DesignChoiceConstants.REFERENCE_DATE_TYPE_FIXED_DATE.equals(handle.getReferenceDateType())) {
    IBaseExpression sciptExpr=this.adaptExpression((Expression)(handle.getReferenceDateValue().getValue()));
    referenceDate=ScriptEvalUtil.evalExpr(sciptExpr,this.context.getDataEngineContext().getScriptContext(),"String_Node_Str",0);
  }
  timeFunction.setReferenceDate(new ReferenceDate(DataTypeUtil.toDate(referenceDate)));
  timeFunction.setTimeDimension(handle.getTimeDimension());
  timeFunction.setBaseTimePeriod(populateBaseTimePeriod(handle));
  timeFunction.setRelativeTimePeriod(populateRelativeTimePeriod(handle));
  return timeFunction;
}

Fixed version (ground truth):
public ITimeFunction adaptTimeFunction(ComputedColumnHandle handle) throws DataException, BirtException {
  if (handle.getCalculationType() == null || handle.getCalculationType().trim().length() == 0)   return null;
  TimeFunction timeFunction=new TimeFunction();
  Object referenceDate=null;
  if (DesignChoiceConstants.REFERENCE_DATE_TYPE_TODAY.equals(handle.getReferenceDateType())) {
    referenceDate=ScriptEvalUtil.evalExpr(new ScriptExpression("String_Node_Str"),this.context.getDataEngineContext().getScriptContext(),"String_Node_Str",0);
  }
 else   if (DesignChoiceConstants.REFERENCE_DATE_TYPE_FIXED_DATE.equals(handle.getReferenceDateType())) {
    IBaseExpression sciptExpr=this.adaptExpression((Expression)(handle.getReferenceDateValue().getValue()));
    referenceDate=ScriptEvalUtil.evalExpr(sciptExpr,this.context.getDataEngineContext().getScriptContext(),"String_Node_Str",0);
  }
  timeFunction.setReferenceDate(new ReferenceDate(DataTypeUtil.toDate(referenceDate)));
  timeFunction.setTimeDimension(handle.getTimeDimension());
  timeFunction.setBaseTimePeriod(populateBaseTimePeriod(handle));
  timeFunction.setRelativeTimePeriod(populateRelativeTimePeriod(handle));
  return timeFunction;
}
Program: 66017
Project: 66017
Buggy source:
private void updateAttrs(EClass eClass,EObject eParentObj,EObject eObj,EObject eRef,EObject eDef){
  List<EAttribute> listMany=new LinkedList<EAttribute>();
  List<EAttribute> list=new LinkedList<EAttribute>();
  for (  EAttribute eAttr : eClass.getEAllAttributes()) {
    if (eAttr.isMany()) {
      listMany.add(eAttr);
    }
 else {
      list.add(eAttr);
    }
  }
  for (  EAttribute eAttr : listMany) {
    List<?> vList=(List<?>)eObj.eGet(eAttr);
    if (vList.size() == 0) {
      if (eRef != null && ((List<?>)eRef.eGet(eAttr)).size() > 0) {
        vList.addAll((List)eRef.eGet(eAttr));
      }
 else       if (eDef != null) {
        vList.addAll((List)eDef.eGet(eAttr));
      }
    }
  }
  for (  EAttribute eAttr : list) {
    Object val=eObj.eGet(eAttr);
    if (eAttr.isUnsettable()) {
      if (!eObj.eIsSet(eAttr)) {
        if (eRef != null && eRef.eIsSet(eAttr)) {
          eObj.eSet(eAttr,eRef.eGet(eAttr));
        }
 else         if (eDef != null) {
          eObj.eSet(eAttr,eDef.eGet(eAttr));
        }
      }
    }
 else     if (val == null) {
      if (eRef != null && eRef.eGet(eAttr) != null) {
        eObj.eSet(eAttr,eRef.eGet(eAttr));
      }
 else       if (eDef != null) {
        eObj.eSet(eAttr,eDef.eGet(eAttr));
      }
    }
  }
}

Fixed version (ground truth):
@SuppressWarnings({"String_Node_Str","String_Node_Str"}) private void updateAttrs(EClass eClass,EObject eParentObj,EObject eObj,EObject eRef,EObject eDef){
  List<EAttribute> listMany=new LinkedList<EAttribute>();
  List<EAttribute> list=new LinkedList<EAttribute>();
  for (  EAttribute eAttr : eClass.getEAllAttributes()) {
    if (eAttr.isMany()) {
      listMany.add(eAttr);
    }
 else {
      list.add(eAttr);
    }
  }
  for (  EAttribute eAttr : listMany) {
    List<?> vList=(List<?>)eObj.eGet(eAttr);
    if (vList.size() == 0) {
      if (eRef != null && ((List<?>)eRef.eGet(eAttr)).size() > 0) {
        vList.addAll((List)eRef.eGet(eAttr));
      }
 else       if (eDef != null) {
        vList.addAll((List)eDef.eGet(eAttr));
      }
    }
  }
  for (  EAttribute eAttr : list) {
    Object val=eObj.eGet(eAttr);
    if (eAttr.isUnsettable()) {
      if (!eObj.eIsSet(eAttr)) {
        if (eRef != null && eRef.eIsSet(eAttr)) {
          eObj.eSet(eAttr,eRef.eGet(eAttr));
        }
 else         if (eDef != null && eDef.eIsSet(eAttr)) {
          eObj.eSet(eAttr,eDef.eGet(eAttr));
        }
      }
    }
 else     if (val == null) {
      if (eRef != null && eRef.eGet(eAttr) != null) {
        eObj.eSet(eAttr,eRef.eGet(eAttr));
      }
 else       if (eDef != null) {
        eObj.eSet(eAttr,eDef.eGet(eAttr));
      }
    }
  }
}
Program: 66018
Project: 66018
Buggy source:
/** 
 * Returns a chart element instance with default value.
 * @param expected
 * @param name
 * @param eObj
 * @return
 */
public EObject getDefault(EClass expected,String name,EObject eObj){
  EObject def=defaultObjCache.get(eObj.getClass().getSimpleName());
  if (def != null) {
    return def;
  }
  Method m;
  try {
    m=eObj.getClass().getMethod("String_Node_Str");
    EObject object=(EObject)m.invoke(eObj);
    defaultObjCache.put(eObj.getClass().getSimpleName(),object);
    return object;
  }
 catch (  SecurityException e) {
    logger.log(e);
  }
catch (  NoSuchMethodException e) {
    logger.log(e);
  }
catch (  IllegalArgumentException e) {
    logger.log(e);
  }
catch (  IllegalAccessException e) {
    logger.log(e);
  }
catch (  InvocationTargetException e) {
    logger.log(e);
  }
  return null;
}

Fixed version (ground truth):
/** 
 * Returns a chart element instance with default value.
 * @param expected
 * @param name
 * @param eObj
 * @return a chart element instance with default value.
 */
public EObject getDefault(EClass expected,String name,EObject eObj){
  EObject def=defaultObjCache.get(eObj.getClass().getSimpleName());
  if (def != null) {
    return def;
  }
  Method m;
  try {
    m=eObj.getClass().getMethod("String_Node_Str");
    EObject object=(EObject)m.invoke(eObj);
    defaultObjCache.put(eObj.getClass().getSimpleName(),object);
    return object;
  }
 catch (  SecurityException e) {
    logger.log(e);
  }
catch (  NoSuchMethodException e) {
    logger.log(e);
  }
catch (  IllegalArgumentException e) {
    logger.log(e);
  }
catch (  IllegalAccessException e) {
    logger.log(e);
  }
catch (  InvocationTargetException e) {
    logger.log(e);
  }
  return null;
}
Program: 66019
Project: 66019
Buggy source:
/** 
 * Initializes all member variables within this object recursively Note: Manually written
 */
protected void initialize(){
  super.initialize();
  final LineAttributes lia=AttributeFactory.eINSTANCE.createLineAttributes();
  ((LineAttributesImpl)lia).set(null,LineStyle.SOLID_LITERAL,1);
  lia.setVisible(true);
  setLineAttributes(lia);
  final LineAttributes weblia=AttributeFactory.eINSTANCE.createLineAttributes();
  ((LineAttributesImpl)weblia).set(null,LineStyle.SOLID_LITERAL,1);
  weblia.setVisible(true);
  setWebLineAttributes(weblia);
  final Marker m=AttributeFactory.eINSTANCE.createMarker();
  m.setType(MarkerType.BOX_LITERAL);
  m.setSize(4);
  m.setVisible(true);
  LineAttributes la=AttributeFactory.eINSTANCE.createLineAttributes();
  la.setVisible(true);
  m.setOutline(la);
  setMarker(m);
  final Label lab=LabelImpl.create();
  setWebLabel(lab);
  final Label clab=LabelImpl.create();
  setCatLabel(clab);
  setPaletteLineColor(true);
}

Fixed version (ground truth):
/** 
 * Initializes all member variables within this object recursively Note: Manually written
 */
protected void initialize(){
  super.initialize();
  final LineAttributes lia=AttributeFactory.eINSTANCE.createLineAttributes();
  ((LineAttributesImpl)lia).set(null,LineStyle.SOLID_LITERAL,1);
  lia.setVisible(true);
  setLineAttributes(lia);
  final LineAttributes weblia=AttributeFactory.eINSTANCE.createLineAttributes();
  ((LineAttributesImpl)weblia).set(ColorDefinitionImpl.BLACK(),LineStyle.SOLID_LITERAL,1);
  weblia.setVisible(true);
  setWebLineAttributes(weblia);
  final Marker m=AttributeFactory.eINSTANCE.createMarker();
  m.setType(MarkerType.BOX_LITERAL);
  m.setSize(4);
  m.setVisible(true);
  LineAttributes la=AttributeFactory.eINSTANCE.createLineAttributes();
  la.setVisible(true);
  m.setOutline(la);
  setMarker(m);
  final Label lab=LabelImpl.create();
  setWebLabel(lab);
  final Label clab=LabelImpl.create();
  setCatLabel(clab);
  setPaletteLineColor(true);
}
Program: 66020
Project: 66020
Buggy source:
/** 
 * Return available orientation even if it is not set.
 * @param chartType
 * @param dimension
 * @param refOrientation
 * @return available orientation
 */
public Orientation getAvailableOrientation(IChartType chartType,String dimension,Orientation refOrientation){
  if (refOrientation == null) {
    return chartType.getDefaultOrientation();
  }
 else   if (refOrientation == Orientation.HORIZONTAL_LITERAL && !chartType.supportsTransposition(dimension)) {
    return chartType.getDefaultOrientation();
  }
  return refOrientation;
}

Fixed version (ground truth):
/** 
 * Return available orientation even if it is not set.
 * @param chartType
 * @param dimension
 * @param refOrientation
 * @return available orientation
 */
protected Orientation getAvailableOrientation(IChartType chartType,String dimension,Orientation refOrientation){
  if (refOrientation == null) {
    return chartType.getDefaultOrientation();
  }
 else   if (refOrientation == Orientation.HORIZONTAL_LITERAL && !chartType.supportsTransposition(dimension)) {
    return chartType.getDefaultOrientation();
  }
  return refOrientation;
}
Program: 66021
Project: 66021
Buggy source:
/** 
 * Returns available dimension.
 * @param ct
 * @param refDimension
 * @return dimension
 */
public String getAvailableDimension(IChartType ct,String refDimension){
  if (refDimension == null) {
    return ct.getDefaultDimension();
  }
  return refDimension;
}

Fixed version (ground truth):
/** 
 * Returns available dimension.
 * @param ct
 * @param refDimension
 * @return dimension available dimension.
 */
protected String getAvailableDimension(IChartType ct,String refDimension){
  if (refDimension == null) {
    return ct.getDefaultDimension();
  }
  return refDimension;
}
Program: 66024
Project: 66024
Buggy source:
/** 
 * Updates chart element FormatSpecifier.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @generated Don't change this method manually.
 */
protected void updateFormatSpecifierImpl(String name,EObject eParentObj,FormatSpecifier eObj,FormatSpecifier eRefObj,FormatSpecifier eDefObj,boolean eDefOverride){
  if (eObj != null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (eRefObj != null) {
    ChartElementUtil.setEObjectAttribute(eParentObj,name,eRefObj,false);
  }
  if (eDefObj != null) {
    ChartElementUtil.setEObjectAttribute(eParentObj,name,eDefObj,false);
  }
}

Fixed version (ground truth):
/** 
 * Updates chart element FormatSpecifier.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @generated Don't change this method manually.
 */
protected void updateFormatSpecifierImpl(String name,EObject eParentObj,FormatSpecifier eObj,FormatSpecifier eRefObj,FormatSpecifier eDefObj,boolean eDefOverride){
  if (eObj != null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (eRefObj != null) {
    Object v=eRefObj;
    if (eRefObj instanceof IChartObject) {
      v=eRefObj.copyInstance();
    }
    ChartElementUtil.setEObjectAttribute(eParentObj,name,v,false);
  }
 else   if (eDefObj != null) {
    Object v=eDefObj;
    if (eDefObj instanceof IChartObject) {
      v=eDefObj.copyInstance();
    }
    ChartElementUtil.setEObjectAttribute(eParentObj,name,v,false);
  }
}
Program: 66025
Project: 66025
Buggy source:
/** 
 * Updates chart element Fill.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @generated Don't change this method manually.
 */
protected void updateFillImpl(String name,EObject eParentObj,Fill eObj,Fill eRefObj,Fill eDefObj,boolean eDefOverride){
  if (eObj != null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (eRefObj != null) {
    ChartElementUtil.setEObjectAttribute(eParentObj,name,eRefObj,false);
  }
  if (eDefObj != null) {
    ChartElementUtil.setEObjectAttribute(eParentObj,name,eDefObj,false);
  }
}

Fixed version (ground truth):
/** 
 * Updates chart element Fill.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @generated Don't change this method manually.
 */
protected void updateFillImpl(String name,EObject eParentObj,Fill eObj,Fill eRefObj,Fill eDefObj,boolean eDefOverride){
  if (eObj != null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (eRefObj != null) {
    Object v=eRefObj;
    if (eRefObj instanceof IChartObject) {
      v=eRefObj.copyInstance();
    }
    ChartElementUtil.setEObjectAttribute(eParentObj,name,v,false);
  }
 else   if (eDefObj != null) {
    Object v=eDefObj;
    if (eDefObj instanceof IChartObject) {
      v=eDefObj.copyInstance();
    }
    ChartElementUtil.setEObjectAttribute(eParentObj,name,v,false);
  }
}
Program: 66026
Project: 66026
Buggy source:
private boolean hasWallAndFloor(){
  return (getChart() instanceof ChartWithAxes) && (getChart().getDimension().getValue() != ChartDimension.TWO_DIMENSIONAL);
}

Fixed version (ground truth):
protected boolean hasWallAndFloor(){
  return (getChart() instanceof ChartWithAxes) && (getChart().getDimension().getValue() != ChartDimension.TWO_DIMENSIONAL);
}
Program: 66027
Project: 66027
Buggy source:
public void doPreview(){
  final Chart chart=getPreviewChartModel();
  LivePreviewTask lpt=new LivePreviewTask(Messages.getString("String_Node_Str"),null);
  lpt.addTask(new LivePreviewTask(){
    public void run(){
      if (previewPainter != null) {
        setParameter(ChartLivePreviewThread.PARAM_CHART_MODEL,ChartUIUtil.prepareLivePreview(chart,getDataServiceProvider(),((ChartWizardContext)context).getActionEvaluator()));
      }
    }
  }
);
  lpt.addTask(new LivePreviewTask(){
    public void run(){
      if (previewCanvas != null && previewCanvas.getDisplay() != null && !previewCanvas.getDisplay().isDisposed()) {
        previewCanvas.getDisplay().syncExec(new Runnable(){
          public void run(){
            if (previewPainter != null) {
              previewPainter.renderModel((IChartObject)getParameter(ChartLivePreviewThread.PARAM_CHART_MODEL));
            }
          }
        }
);
      }
    }
  }
);
  ((ChartLivePreviewThread)((ChartWizardContext)context).getLivePreviewThread()).setParentShell(getPreviewCanvas().getShell());
  ((ChartLivePreviewThread)((ChartWizardContext)context).getLivePreviewThread()).add(lpt);
}

Fixed version (ground truth):
public void doPreview(){
  try {
    final Chart chart=getPreviewChartModel();
    LivePreviewTask lpt=new LivePreviewTask(Messages.getString("String_Node_Str"),null);
    lpt.addTask(new LivePreviewTask(){
      public void run(){
        if (previewPainter != null) {
          setParameter(ChartLivePreviewThread.PARAM_CHART_MODEL,ChartUIUtil.prepareLivePreview(chart,getDataServiceProvider(),((ChartWizardContext)context).getActionEvaluator()));
        }
      }
    }
);
    lpt.addTask(new LivePreviewTask(){
      public void run(){
        if (previewCanvas != null && previewCanvas.getDisplay() != null && !previewCanvas.getDisplay().isDisposed()) {
          previewCanvas.getDisplay().syncExec(new Runnable(){
            public void run(){
              if (previewPainter != null) {
                previewPainter.renderModel((IChartObject)getParameter(ChartLivePreviewThread.PARAM_CHART_MODEL));
              }
            }
          }
);
        }
      }
    }
);
    ((ChartLivePreviewThread)((ChartWizardContext)context).getLivePreviewThread()).setParentShell(getPreviewCanvas().getShell());
    ((ChartLivePreviewThread)((ChartWizardContext)context).getLivePreviewThread()).add(lpt);
  }
 catch (  ChartException e) {
    WizardBase.showException(e.getMessage());
  }
}
Program: 66028
Project: 66028
Buggy source:
protected Chart getPreviewChartModel(){
  return getCurrentModelState();
}

Fixed version (ground truth):
protected Chart getPreviewChartModel() throws ChartException {
  return getCurrentModelState();
}