nus-yam/ex-repair huggingface dataset:
Program: 125082
Project: 125082
Buggy source:
public Object[] getChildren(Object parentElement){
  List<IHCatalogNode> nodes=new ArrayList<IHCatalogNode>();
  if (parentElement instanceof HCatalogConnection) {
    try {
      List<TdTable> tables=ExtractMetaDataFromHCatalog.extractTables((HCatalogConnection)parentElement);
      for (      TdTable table : tables) {
        IHCatalogNode node=new HCatalogNode();
        node.setValue(table.getLabel());
        node.setTable(table);
        nodes.add(node);
      }
    }
 catch (    Exception e) {
      ExceptionHandler.process(e);
    }
  }
  return nodes.toArray();
}

Fixed version (ground truth):
@Override public Object[] getChildren(Object parentElement){
  List<IHCatalogNode> nodes=new ArrayList<IHCatalogNode>();
  if (parentElement instanceof HCatalogConnection) {
    try {
      List<TdTable> tables=ExtractMetaDataFromHCatalog.extractTables((HCatalogConnection)parentElement);
      for (      TdTable table : tables) {
        IHCatalogNode node=new HCatalogNode();
        node.setValue(table.getLabel());
        node.setTable(table);
        nodes.add(node);
      }
    }
 catch (    Exception e) {
      ExceptionHandler.process(e);
    }
  }
  return nodes.toArray();
}
Program: 125083
Project: 125083
Buggy source:
public Object getParent(Object element){
  return null;
}

Fixed version (ground truth):
@Override public Object getParent(Object element){
  return null;
}
Program: 125084
Project: 125084
Buggy source:
public Image getColumnImage(Object element,int columnIndex){
  if (columnIndex == 0 && element instanceof IHCatalogNode) {
    return ((IHCatalogNode)element).getImage();
  }
  return null;
}

Fixed version (ground truth):
@Override public Image getColumnImage(Object element,int columnIndex){
  if (columnIndex == 0 && element instanceof IHCatalogNode) {
    return ((IHCatalogNode)element).getImage();
  }
  return null;
}
Program: 125085
Project: 125085
Buggy source:
public boolean hasChildren(Object element){
  if (element instanceof HCatalogConnection) {
    return true;
  }
  return false;
}

Fixed version (ground truth):
@Override public boolean hasChildren(Object element){
  if (element instanceof HCatalogConnection) {
    return true;
  }
  return false;
}
Program: 125086
Project: 125086
Buggy source:
public Object[] getElements(Object inputElement){
  return getChildren(inputElement);
}

Fixed version (ground truth):
@Override public Object[] getElements(Object inputElement){
  return getChildren(inputElement);
}
Program: 125087
Project: 125087
Buggy source:
public String getColumnText(Object element,int columnIndex){
  IHCatalogNode content=(IHCatalogNode)element;
switch (columnIndex) {
case 0:
    return StringUtils.trimToEmpty(content.getValue());
default :
  return "String_Node_Str";
}
}

Fixed version (ground truth):
@Override public String getColumnText(Object element,int columnIndex){
  IHCatalogNode content=(IHCatalogNode)element;
switch (columnIndex) {
case 0:
    return StringUtils.trimToEmpty(content.getValue());
default :
  return "String_Node_Str";
}
}
Program: 125088
Project: 125088
Buggy source:
private void refreshExistItem(final MetadataTable existTable,final TreeItem item){
  Display.getDefault().syncExec(new Runnable(){
    @Override public void run(){
      orgomg.cwm.objectmodel.core.Package pack=(orgomg.cwm.objectmodel.core.Package)existTable.eContainer();
      boolean confirm=MessageDialog.openConfirm(Display.getDefault().getActiveShell(),Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str",existTable.getLabel(),pack.getName()));
      if (confirm) {
        TreeItem existItem=getExistItem(existTable);
        if (existItem != null) {
          clearTreeItem(existItem);
          existItem.setChecked(false);
        }
        item.setText(4,Messages.getString("String_Node_Str"));
        countPending++;
        parentWizardPage.setPageComplete(false);
        refreshTable(item,-1);
      }
 else {
        item.setChecked(false);
        boolean hasCheckedItem=false;
        TreeItem parentItem=item.getParentItem();
        if (parentItem != null) {
          for (          TreeItem i : parentItem.getItems()) {
            if (i.getChecked()) {
              hasCheckedItem=true;
              break;
            }
          }
        }
        if (!hasCheckedItem && parentItem != null) {
          parentItem.setChecked(false);
        }
      }
    }
  }
);
}

Fixed version (ground truth):
private void refreshExistItem(final MetadataTable existTable,final TreeItem item){
  Display.getDefault().syncExec(new Runnable(){
    @Override public void run(){
      orgomg.cwm.objectmodel.core.Package pack=(orgomg.cwm.objectmodel.core.Package)existTable.eContainer();
      boolean confirm=MessageDialog.openConfirm(Display.getDefault().getActiveShell(),Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str",existTable.getLabel(),pack.getName()));
      if (confirm) {
        TreeItem existItem=getExistItem(existTable);
        if (existItem != null) {
          clearTreeItem(existItem);
          existItem.setChecked(false);
        }
        item.setText(4,Messages.getString("String_Node_Str"));
        parentWizardPage.setPageComplete(false);
        refreshTable(item,-1);
      }
 else {
        item.setChecked(false);
        boolean hasCheckedItem=false;
        TreeItem parentItem=item.getParentItem();
        if (parentItem != null) {
          for (          TreeItem i : parentItem.getItems()) {
            if (i.getChecked()) {
              hasCheckedItem=true;
              break;
            }
          }
        }
        if (!hasCheckedItem && parentItem != null) {
          parentItem.setChecked(false);
        }
      }
    }
  }
);
}
Program: 125089
Project: 125089
Buggy source:
@Override public void widgetSelected(final SelectionEvent e){
  if (e.detail == SWT.CHECK) {
    TreeItem treeItem=(TreeItem)e.item;
    IHDFSNode node=(IHDFSNode)treeItem.getData();
    boolean promptNeeded=treeItem.getChecked();
    EHadoopFileTypes type=node.getType();
    if (type != EHadoopFileTypes.FILE) {
      treeItem.setGrayed(true);
    }
    if (type == EHadoopFileTypes.FILE) {
      if (promptNeeded) {
        MetadataTable existTable=HDFSSchemaUtil.getTableByName(getConnection(),treeItem.getText(0));
        if (existTable != null) {
          refreshExistItem(existTable,treeItem);
        }
 else {
          treeItem.setText(3,EMPTY_STRING);
          treeItem.setText(4,Messages.getString("String_Node_Str"));
          countPending++;
          parentWizardPage.setPageComplete(false);
          refreshTable(treeItem,-1);
        }
      }
 else {
        clearTreeItem(treeItem);
        if (treeItem.getText() != null && treeItem.getText().equals(Messages.getString("String_Node_Str"))) {
          countPending--;
        }
      }
    }
 else     if (type == EHadoopFileTypes.FOLDER) {
      fetchAllChildren(node);
      for (      TreeItem tItem : treeItem.getItems()) {
        updateItem(tItem,promptNeeded,true);
      }
    }
  }
}

Fixed version (ground truth):
@Override public void widgetSelected(final SelectionEvent e){
  if (e.detail == SWT.CHECK) {
    TreeItem treeItem=(TreeItem)e.item;
    IHDFSNode node=(IHDFSNode)treeItem.getData();
    boolean promptNeeded=treeItem.getChecked();
    EHadoopFileTypes type=node.getType();
    if (type != EHadoopFileTypes.FILE) {
      treeItem.setGrayed(true);
    }
    if (type == EHadoopFileTypes.FILE) {
      if (promptNeeded) {
        MetadataTable existTable=HDFSSchemaUtil.getTableByName(getConnection(),treeItem.getText(0));
        if (existTable != null) {
          refreshExistItem(existTable,treeItem);
        }
 else {
          treeItem.setText(3,EMPTY_STRING);
          treeItem.setText(4,Messages.getString("String_Node_Str"));
          parentWizardPage.setPageComplete(false);
          refreshTable(treeItem,-1);
        }
      }
 else {
        clearTreeItem(treeItem);
        if (treeItem.getText() != null && treeItem.getText().equals(Messages.getString("String_Node_Str"))) {
        }
      }
    }
 else     if (type == EHadoopFileTypes.FOLDER) {
      fetchAllChildren(node);
      for (      TreeItem tItem : treeItem.getItems()) {
        updateItem(tItem,promptNeeded,true);
      }
    }
  }
}
Program: 125090
Project: 125090
Buggy source:
private void updateItem(final TreeItem item,boolean checked,boolean isEvent){
  IHDFSNode node=(IHDFSNode)item.getData();
  if (node.getType() == EHadoopFileTypes.FOLDER) {
    for (    TreeItem treeItem : item.getItems()) {
      updateItem(treeItem,checked,true);
    }
  }
 else   if (node.getType() == EHadoopFileTypes.FILE) {
    String pattern=getNameFilter();
    SearchPattern matcher=new SearchPattern();
    matcher.setPattern(pattern);
    if (!matcher.matches(node.getValue())) {
      return;
    }
    if (isEvent) {
      Set<MetadataTable> tables=ConnectionHelper.getTables(getConnection());
      for (      MetadataTable table : tables) {
        if (table.getLabel().equals(node.getTable().getName())) {
          item.setChecked(true);
        }
      }
      item.setChecked(!checked);
    }
    if (checked) {
      if (!item.getChecked()) {
        MetadataTable existTable=HDFSSchemaUtil.getTableByName(getConnection(),item.getText(0));
        if (existTable != null) {
          refreshExistItem(existTable,item);
        }
 else {
          item.setText(4,Messages.getString("String_Node_Str"));
          countPending++;
          parentWizardPage.setPageComplete(false);
          refreshTable(item,-1);
        }
      }
 else {
        updateStatus(IStatus.OK,null);
      }
      item.setChecked(true);
    }
 else {
      if (item.getChecked()) {
        clearTreeItem(item);
        item.setChecked(false);
      }
    }
  }
}

Fixed version (ground truth):
private void updateItem(final TreeItem item,boolean checked,boolean isEvent){
  IHDFSNode node=(IHDFSNode)item.getData();
  if (node.getType() == EHadoopFileTypes.FOLDER) {
    for (    TreeItem treeItem : item.getItems()) {
      updateItem(treeItem,checked,true);
    }
  }
 else   if (node.getType() == EHadoopFileTypes.FILE) {
    String pattern=getNameFilter();
    SearchPattern matcher=new SearchPattern();
    matcher.setPattern(pattern);
    if (!matcher.matches(node.getValue())) {
      return;
    }
    if (isEvent) {
      Set<MetadataTable> tables=ConnectionHelper.getTables(getConnection());
      for (      MetadataTable table : tables) {
        if (table.getLabel().equals(node.getTable().getName())) {
          item.setChecked(true);
        }
      }
      item.setChecked(!checked);
    }
    if (checked) {
      if (!item.getChecked()) {
        MetadataTable existTable=HDFSSchemaUtil.getTableByName(getConnection(),item.getText(0));
        if (existTable != null) {
          refreshExistItem(existTable,item);
        }
 else {
          item.setText(4,Messages.getString("String_Node_Str"));
          parentWizardPage.setPageComplete(false);
          refreshTable(item,-1);
        }
      }
 else {
        updateStatus(IStatus.OK,null);
      }
      item.setChecked(true);
    }
 else {
      if (item.getChecked()) {
        clearTreeItem(item);
        item.setChecked(false);
      }
    }
  }
}
Program: 125093
Project: 125093
Buggy source:
public void updateUIInThreadIfThread(){
  if (treeItem.isDisposed()) {
    return;
  }
  if (checkConnectionIsDone) {
    treeItem.setText(3,EMPTY_STRING + metadataColumns.size());
    treeItem.setText(4,Messages.getString("String_Node_Str"));
    countSuccess++;
    tableColumnNums.put(treeItem.getText(0),metadataColumns.size());
  }
 else {
    String msg=Messages.getString("String_Node_Str");
    updateStatus(IStatus.WARNING,msg);
    new ErrorDialogWidthDetailArea(getShell(),Activator.PLUGIN_ID,msg,msg);
  }
  count++;
  updateStatus(IStatus.OK,null);
  parentWizardPage.setPageComplete(threadExecutor.getQueue().isEmpty() && (threadExecutor.getActiveCount() == 0 || countSuccess == countPending));
}

Fixed version (ground truth):
public void updateUIInThreadIfThread(){
  if (treeItem.isDisposed()) {
    return;
  }
  if (checkConnectionIsDone) {
    treeItem.setText(3,EMPTY_STRING + metadataColumns.size());
    treeItem.setText(4,Messages.getString("String_Node_Str"));
    tableColumnNums.put(treeItem.getText(0),metadataColumns.size());
  }
 else {
    String msg=Messages.getString("String_Node_Str");
    updateStatus(IStatus.WARNING,msg);
    new ErrorDialogWidthDetailArea(getShell(),Activator.PLUGIN_ID,msg,msg);
  }
  updateStatus(IStatus.OK,null);
  parentWizardPage.setPageComplete(!threadExecutor.hasThreadRunning());
}
Program: 125094
Project: 125094
Buggy source:
public void checkPerformed(final AbstractForm source){
  if (source.isStatusOnError()) {
    HDFSFileSelectorWizardPage.this.setPageComplete(false);
    setErrorMessage(source.getStatus());
  }
 else {
    HDFSFileSelectorWizardPage.this.setPageComplete(isRepositoryObjectEditable);
    setErrorMessage(null);
    setMessage(source.getStatus(),source.getStatusLevel());
  }
}

Fixed version (ground truth):
@Override public void checkPerformed(final AbstractForm source){
  if (source.isStatusOnError()) {
    HDFSFileSelectorWizardPage.this.setPageComplete(false);
    setErrorMessage(source.getStatus());
  }
 else {
    HDFSFileSelectorWizardPage.this.setPageComplete(isRepositoryObjectEditable);
    setErrorMessage(null);
    setMessage(source.getStatus(),source.getStatusLevel());
  }
}
Program: 125095
Project: 125095
Buggy source:
public void createControl(final Composite parent){
  hdfsFileSelectorForm=new HDFSFileSelectorForm(parent,connectionItem,temConnection,this);
  hdfsFileSelectorForm.setReadOnly(!isRepositoryObjectEditable);
  AbstractForm.ICheckListener listener=new AbstractForm.ICheckListener(){
    public void checkPerformed(    final AbstractForm source){
      if (source.isStatusOnError()) {
        HDFSFileSelectorWizardPage.this.setPageComplete(false);
        setErrorMessage(source.getStatus());
      }
 else {
        HDFSFileSelectorWizardPage.this.setPageComplete(isRepositoryObjectEditable);
        setErrorMessage(null);
        setMessage(source.getStatus(),source.getStatusLevel());
      }
    }
  }
;
  hdfsFileSelectorForm.setListener(listener);
  setControl(hdfsFileSelectorForm);
  if (StringUtils.isNotEmpty(connectionItem.getProperty().getLabel())) {
    hdfsFileSelectorForm.checkFieldsValue();
  }
}

Fixed version (ground truth):
@Override public void createControl(final Composite parent){
  hdfsFileSelectorForm=new HDFSFileSelectorForm(parent,connectionItem,temConnection,this);
  hdfsFileSelectorForm.setReadOnly(!isRepositoryObjectEditable);
  AbstractForm.ICheckListener listener=new AbstractForm.ICheckListener(){
    @Override public void checkPerformed(    final AbstractForm source){
      if (source.isStatusOnError()) {
        HDFSFileSelectorWizardPage.this.setPageComplete(false);
        setErrorMessage(source.getStatus());
      }
 else {
        HDFSFileSelectorWizardPage.this.setPageComplete(isRepositoryObjectEditable);
        setErrorMessage(null);
        setMessage(source.getStatus(),source.getStatusLevel());
      }
    }
  }
;
  hdfsFileSelectorForm.setListener(listener);
  setControl(hdfsFileSelectorForm);
  if (StringUtils.isNotEmpty(connectionItem.getProperty().getLabel())) {
    hdfsFileSelectorForm.checkFieldsValue();
  }
}
Program: 125096
Project: 125096
Buggy source:
@Override protected void doRun(){
  if (repositoryNode == null) {
    repositoryNode=getCurrentRepositoryNode();
  }
  HCatalogConnection connection=null;
  MetadataTable metadataTable=null;
  boolean creation=false;
  if (repositoryNode.getType() == ENodeType.REPOSITORY_ELEMENT) {
    ERepositoryObjectType nodeType=(ERepositoryObjectType)repositoryNode.getProperties(EProperties.CONTENT_TYPE);
    String metadataTableLabel=(String)repositoryNode.getProperties(EProperties.LABEL);
    HCatalogConnectionItem item=null;
    if (nodeType == ERepositoryObjectType.METADATA_CON_TABLE) {
      item=(HCatalogConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HCatalogConnection)item.getConnection();
      metadataTable=TableHelper.findByLabel(connection,metadataTableLabel);
      creation=false;
    }
 else     if (nodeType == HCatalogRepositoryNodeType.HCATALOG) {
      item=(HCatalogConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HCatalogConnection)item.getConnection();
      creation=true;
    }
 else {
      return;
    }
    if (!creation) {
      openHCatalogSchemaWizard(item,metadataTable,false,creation);
    }
 else     if (checkHCatalogConnection((HCatalogConnection)item.getConnection())) {
      openHCatalogSchemaWizard(item,metadataTable,false,creation);
    }
  }
}

Fixed version (ground truth):
@Override protected void doRun(){
  if (repositoryNode == null) {
    repositoryNode=getCurrentRepositoryNode();
  }
  HCatalogConnection connection=null;
  MetadataTable metadataTable=null;
  boolean creation=false;
  if (repositoryNode.getType() == ENodeType.REPOSITORY_ELEMENT) {
    ERepositoryObjectType nodeType=(ERepositoryObjectType)repositoryNode.getProperties(EProperties.CONTENT_TYPE);
    String metadataTableLabel=(String)repositoryNode.getProperties(EProperties.LABEL);
    HCatalogConnectionItem item=null;
    if (nodeType == ERepositoryObjectType.METADATA_CON_TABLE) {
      item=(HCatalogConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HCatalogConnection)item.getConnection();
      metadataTable=TableHelper.findByLabel(connection,metadataTableLabel);
      creation=false;
    }
 else     if (nodeType == HCatalogRepositoryNodeType.HCATALOG) {
      item=(HCatalogConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HCatalogConnection)item.getConnection();
      creation=true;
    }
 else {
      return;
    }
    boolean isOK=true;
    if (creation) {
      isOK=checkHCatalogConnection((HCatalogConnection)item.getConnection());
    }
    if (isOK) {
      openHCatalogSchemaWizard(item,metadataTable,false,creation);
    }
  }
}
Program: 125097
Project: 125097
Buggy source:
@Override protected void doRun(){
  if (repositoryNode == null) {
    repositoryNode=getCurrentRepositoryNode();
  }
  HDFSConnection connection=null;
  MetadataTable metadataTable=null;
  boolean creation=false;
  if (repositoryNode.getType() == ENodeType.REPOSITORY_ELEMENT) {
    ERepositoryObjectType nodeType=(ERepositoryObjectType)repositoryNode.getProperties(EProperties.CONTENT_TYPE);
    String metadataTableLabel=(String)repositoryNode.getProperties(EProperties.LABEL);
    HDFSConnectionItem item=null;
    if (nodeType == ERepositoryObjectType.METADATA_CON_TABLE) {
      item=(HDFSConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HDFSConnection)item.getConnection();
      metadataTable=TableHelper.findByLabel(connection,metadataTableLabel);
      creation=false;
    }
 else     if (nodeType == HDFSRepositoryNodeType.HDFS) {
      item=(HDFSConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HDFSConnection)item.getConnection();
      creation=true;
    }
 else {
      return;
    }
    if (!creation) {
      openHDFSSchemaWizard(item,metadataTable,false,creation);
    }
 else     if (checkHDFSConnection((HDFSConnection)item.getConnection())) {
      openHDFSSchemaWizard(item,metadataTable,false,creation);
    }
  }
}

Fixed version (ground truth):
@Override protected void doRun(){
  if (repositoryNode == null) {
    repositoryNode=getCurrentRepositoryNode();
  }
  HDFSConnection connection=null;
  MetadataTable metadataTable=null;
  boolean creation=false;
  if (repositoryNode.getType() == ENodeType.REPOSITORY_ELEMENT) {
    ERepositoryObjectType nodeType=(ERepositoryObjectType)repositoryNode.getProperties(EProperties.CONTENT_TYPE);
    String metadataTableLabel=(String)repositoryNode.getProperties(EProperties.LABEL);
    HDFSConnectionItem item=null;
    if (nodeType == ERepositoryObjectType.METADATA_CON_TABLE) {
      item=(HDFSConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HDFSConnection)item.getConnection();
      metadataTable=TableHelper.findByLabel(connection,metadataTableLabel);
      creation=false;
    }
 else     if (nodeType == HDFSRepositoryNodeType.HDFS) {
      item=(HDFSConnectionItem)repositoryNode.getObject().getProperty().getItem();
      connection=(HDFSConnection)item.getConnection();
      creation=true;
    }
 else {
      return;
    }
    boolean isOK=true;
    if (creation) {
      isOK=checkHDFSConnection((HDFSConnection)item.getConnection());
    }
    if (isOK) {
      openHDFSSchemaWizard(item,metadataTable,false,creation);
    }
  }
}
Program: 125098
Project: 125098
Buggy source:
private boolean checkHDFSConnection(final HDFSConnection connection){
  final boolean[] result=new boolean[]{true};
  IRunnableWithProgress runnableWithProgress=new IRunnableWithProgress(){
    public void run(    IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
      monitor.beginTask(Messages.getString("String_Node_Str"),IProgressMonitor.UNKNOWN);
      try {
        HDFSConnectionBean connectionBean=HDFSModelUtil.convert2HDFSConnectionBean(connection);
        HadoopOperationManager.getInstance().connectDFS(connectionBean);
      }
 catch (      Exception e) {
        PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable(){
          @Override public void run(){
            String mainMsg=Messages.getString("String_Node_Str");
            String detailMsg=Messages.getString("String_Node_Str",connection.getNameNodeURI());
            new ErrorDialogWidthDetailArea(PlatformUI.getWorkbench().getDisplay().getActiveShell(),Activator.PLUGIN_ID,mainMsg,detailMsg);
            result[0]=false;
            return;
          }
        }
);
      }
 finally {
        monitor.done();
      }
    }
  }
;
  ProgressMonitorDialog dialog=new ProgressMonitorDialog(PlatformUI.getWorkbench().getDisplay().getActiveShell());
  try {
    dialog.run(true,true,runnableWithProgress);
  }
 catch (  Exception e) {
    result[0]=false;
    ExceptionHandler.process(e);
  }
  return result[0];
}

Fixed version (ground truth):
private boolean checkHDFSConnection(final HDFSConnection connection){
  final boolean[] result=new boolean[]{true};
  IRunnableWithProgress runnableWithProgress=new IRunnableWithProgress(){
    public void run(    IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
      monitor.beginTask(Messages.getString("String_Node_Str"),IProgressMonitor.UNKNOWN);
      Object dfs=null;
      try {
        HDFSConnectionBean connectionBean=HDFSModelUtil.convert2HDFSConnectionBean(connection);
        dfs=HadoopOperationManager.getInstance().getDFS(connectionBean);
      }
 catch (      Exception e) {
        ExceptionHandler.process(e);
      }
 finally {
        monitor.done();
      }
      if (dfs == null) {
        PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable(){
          @Override public void run(){
            String mainMsg=Messages.getString("String_Node_Str");
            String detailMsg=Messages.getString("String_Node_Str",connection.getNameNodeURI());
            new ErrorDialogWidthDetailArea(PlatformUI.getWorkbench().getDisplay().getActiveShell(),Activator.PLUGIN_ID,mainMsg,detailMsg);
            result[0]=false;
            return;
          }
        }
);
      }
    }
  }
;
  ProgressMonitorDialog dialog=new ProgressMonitorDialog(PlatformUI.getWorkbench().getDisplay().getActiveShell());
  try {
    dialog.run(true,true,runnableWithProgress);
  }
 catch (  Exception e) {
    result[0]=false;
    ExceptionHandler.process(e);
  }
  return result[0];
}
Program: 125102
Project: 125102
Buggy source:
public Map getConnectionMap(){
  return adminMap;
}

Fixed version (ground truth):
@Override public Map getConnectionMap(){
  return adminMap;
}
Program: 125103
Project: 125103
Buggy source:
public Object getParent(Object element){
  TableNode tableNode=(TableNode)element;
  return tableNode.getParent();
}

Fixed version (ground truth):
@Override public Object getParent(Object element){
  TableNode tableNode=(TableNode)element;
  return tableNode.getParent();
}
Program: 125104
Project: 125104
Buggy source:
public ConnectionStatus testConnection(String dbType,String url,String username,String pwd,String schema,String server,String port,String driverClassName,String driverJarPath,String dbVersionString,String additionalParam){
  ConnectionStatus connectionStatus=new ConnectionStatus();
  connectionStatus.setResult(false);
  Configuration config=HBaseConfiguration.create();
  config.set("String_Node_Str",server);
  config.set("String_Node_Str",port);
  try {
    HBaseAdmin.checkHBaseAvailable(config);
    connectionStatus.setResult(true);
  }
 catch (  MasterNotRunningException e) {
    ExceptionHandler.process(e);
    connectionStatus.setMessageException(e.getMessage());
  }
catch (  ZooKeeperConnectionException e) {
    ExceptionHandler.process(e);
    connectionStatus.setMessageException(e.getMessage());
  }
 finally {
    return connectionStatus;
  }
}

Fixed version (ground truth):
@Override public ConnectionStatus testConnection(String dbType,String url,String username,String pwd,String schema,String server,String port,String driverClassName,String driverJarPath,String dbVersionString,String additionalParam){
  ConnectionStatus connectionStatus=new ConnectionStatus();
  connectionStatus.setResult(false);
  Configuration config=HBaseConfiguration.create();
  config.set("String_Node_Str",server);
  config.set("String_Node_Str",port);
  try {
    HBaseAdmin.checkHBaseAvailable(config);
    connectionStatus.setResult(true);
  }
 catch (  MasterNotRunningException e) {
    ExceptionHandler.process(e);
    connectionStatus.setMessageException(e.getMessage());
  }
catch (  ZooKeeperConnectionException e) {
    ExceptionHandler.process(e);
    connectionStatus.setMessageException(e.getMessage());
  }
  return connectionStatus;
}
Program: 125105
Project: 125105
Buggy source:
public boolean hasChildren(Object element){
  TableNode tableNode=(TableNode)element;
  int type=tableNode.getType();
  if (type == TableNode.COLUMN_FAMILY || type == TableNode.TABLE) {
    return true;
  }
  return !tableNode.getChildren().isEmpty();
}

Fixed version (ground truth):
@Override public boolean hasChildren(Object element){
  TableNode tableNode=(TableNode)element;
  int type=tableNode.getType();
  if (type == TableNode.COLUMN_FAMILY || type == TableNode.TABLE) {
    return true;
  }
  return !tableNode.getChildren().isEmpty();
}
Program: 125106
Project: 125106
Buggy source:
public void updatePackage(IMetadataConnection metadataConnection){
}

Fixed version (ground truth):
@Override public void updatePackage(IMetadataConnection metadataConnection){
}
Program: 125109
Project: 125109
Buggy source:
public void deleteMetadataFromConnection(Object node,DatabaseConnection connection){
  TableNode columnNode=null;
  if (node == null) {
    return;
  }
  if (node instanceof TableNode) {
    columnNode=(TableNode)node;
  }
  List<MetadataTable> tables=ConnectionHelper.getTablesWithOrders(connection);
  TableNode columeFamilyNode=columnNode.getParent();
  TableNode tableNode=columeFamilyNode.getParent();
  String tableName=tableNode.getValue();
  String columnFamilyName=columeFamilyNode.getValue();
  String columnName=columnNode.getValue();
  boolean columnRemoved=false;
  for (  MetadataTable table : tables) {
    if (columnRemoved) {
      break;
    }
    if (table instanceof TdTable) {
      TdTable tdTable=(TdTable)table;
      if (tdTable.getLabel().equals(tableName)) {
        List<MetadataColumn> columns=tdTable.getColumns();
        for (        MetadataColumn column : columns) {
          if (column.getLabel().equals(columnName)) {
            List<TaggedValue> tagValues=column.getTaggedValue();
            for (            TaggedValue tv : tagValues) {
              String tag=tv.getTag();
              String value=tv.getValue();
              if (tag != null && tag.equals(COLUMN_FAMILY)) {
                if (value != null && value.equals(columnFamilyName)) {
                  columns.remove(column);
                  columnRemoved=true;
                  break;
                }
              }
            }
          }
          if (columnRemoved) {
            break;
          }
        }
      }
    }
  }
}

Fixed version (ground truth):
@Override public void deleteMetadataFromConnection(Object node,DatabaseConnection connection){
  TableNode columnNode=null;
  if (node == null) {
    return;
  }
  if (node instanceof TableNode) {
    columnNode=(TableNode)node;
  }
  List<MetadataTable> tables=ConnectionHelper.getTablesWithOrders(connection);
  TableNode columeFamilyNode=columnNode.getParent();
  TableNode tableNode=columeFamilyNode.getParent();
  String tableName=tableNode.getValue();
  String columnFamilyName=columeFamilyNode.getValue();
  String columnName=columnNode.getValue();
  boolean columnRemoved=false;
  for (  MetadataTable table : tables) {
    if (columnRemoved) {
      break;
    }
    if (table instanceof TdTable) {
      TdTable tdTable=(TdTable)table;
      if (tdTable.getLabel().equals(tableName)) {
        List<MetadataColumn> columns=tdTable.getColumns();
        for (        MetadataColumn column : columns) {
          if (column.getLabel().equals(columnName)) {
            List<TaggedValue> tagValues=column.getTaggedValue();
            for (            TaggedValue tv : tagValues) {
              String tag=tv.getTag();
              String value=tv.getValue();
              if (tag != null && tag.equals(COLUMN_FAMILY)) {
                if (value != null && value.equals(columnFamilyName)) {
                  columns.remove(column);
                  columnRemoved=true;
                  break;
                }
              }
            }
          }
          if (columnRemoved) {
            break;
          }
        }
      }
    }
  }
}
Program: 125110
Project: 125110
Buggy source:
/** 
 * returns the node type which will access a runnable when click the node.
 */
public int getRunnableAccessNodeType(){
  return TableNode.COLUMN;
}

Fixed version (ground truth):
/** 
 * returns the node type which will access a runnable when click the node.
 */
@Override public int getRunnableAccessNodeType(){
  return TableNode.COLUMN;
}
Program: 125111
Project: 125111
Buggy source:
public boolean isSupportGuessSchema(){
  return false;
}

Fixed version (ground truth):
@Override public boolean isSupportGuessSchema(){
  return false;
}
Program: 125113
Project: 125113
Buggy source:
public AbstractMetadataExtractorViewProvider getMetadataViewProvider(){
  HBaseMetadataViewProvider provider=new HBaseMetadataViewProvider();
  return provider;
}

Fixed version (ground truth):
@Override public AbstractMetadataExtractorViewProvider getMetadataViewProvider(){
  HBaseMetadataViewProvider provider=new HBaseMetadataViewProvider();
  return provider;
}
Program: 125114
Project: 125114
Buggy source:
public List getTableNodeInfo(IMetadataConnection metadataConnection){
  List<TableNode> tableNodes=new ArrayList<TableNode>();
  try {
    HBaseAdmin hAdmin=getAdmin(metadataConnection);
    HTableDescriptor[] allTables=hAdmin.listTables();
    for (    HTableDescriptor td : allTables) {
      TdTable tb=RelationalFactory.eINSTANCE.createTdTable();
      tb.setLabel(td.getNameAsString());
      tb.setName(td.getNameAsString());
      tb.setTableType(ETableTypes.TABLETYPE_TABLE.getName());
      TableNode tableNode=new TableNode();
      tableNode.setType(TableNode.TABLE);
      tableNode.setValue(tb.getLabel());
      tableNode.setItemType(tb.getTableType());
      tableNode.setMetadataConn(metadataConnection);
      tableNode.setTable(tb);
      tableNodes.add(tableNode);
    }
  }
 catch (  MasterNotRunningException e) {
    ExceptionHandler.process(e);
  }
catch (  ZooKeeperConnectionException e) {
    ExceptionHandler.process(e);
  }
catch (  IOException e) {
    ExceptionHandler.process(e);
  }
  return tableNodes;
}

Fixed version (ground truth):
@Override public List getTableNodeInfo(IMetadataConnection metadataConnection){
  List<TableNode> tableNodes=new ArrayList<TableNode>();
  try {
    HBaseAdmin hAdmin=getAdmin(metadataConnection);
    HTableDescriptor[] allTables=hAdmin.listTables();
    for (    HTableDescriptor td : allTables) {
      TdTable tb=RelationalFactory.eINSTANCE.createTdTable();
      tb.setLabel(td.getNameAsString());
      tb.setName(td.getNameAsString());
      tb.setTableType(ETableTypes.TABLETYPE_TABLE.getName());
      TableNode tableNode=new TableNode();
      tableNode.setType(TableNode.TABLE);
      tableNode.setValue(tb.getLabel());
      tableNode.setItemType(tb.getTableType());
      tableNode.setMetadataConn(metadataConnection);
      tableNode.setTable(tb);
      tableNodes.add(tableNode);
    }
  }
 catch (  MasterNotRunningException e) {
    ExceptionHandler.process(e);
  }
catch (  ZooKeeperConnectionException e) {
    ExceptionHandler.process(e);
  }
catch (  IOException e) {
    ExceptionHandler.process(e);
  }
  return tableNodes;
}
Program: 125115
Project: 125115
Buggy source:
public Image getColumnImage(Object element,int columnIndex){
  return null;
}

Fixed version (ground truth):
@Override public Image getColumnImage(Object element,int columnIndex){
  return null;
}
Program: 125116
Project: 125116
Buggy source:
public boolean isSupportRetrieveSchema(){
  return true;
}

Fixed version (ground truth):
@Override public boolean isSupportRetrieveSchema(){
  return true;
}
Program: 125117
Project: 125117
Buggy source:
public Object[] getElements(Object inputElement){
  List list=(List)inputElement;
  return list.toArray();
}

Fixed version (ground truth):
@Override public Object[] getElements(Object inputElement){
  List list=(List)inputElement;
  return list.toArray();
}
Program: 125119
Project: 125119
Buggy source:
public String getColumnText(Object element,int columnIndex){
  TableNode tableNode=(TableNode)element;
  int type=tableNode.getType();
switch (columnIndex) {
case 0:
    String value=tableNode.getValue();
  if (value == null) {
    return "String_Node_Str";
  }
return value;
case 1:
if (type == TableNode.CATALOG) {
return "String_Node_Str";
}
 else if (type == TableNode.SCHEMA) {
return "String_Node_Str";
}
 else {
return tableNode.getItemType();
}
default :
return "String_Node_Str";
}
}

Fixed version (ground truth):
@Override public String getColumnText(Object element,int columnIndex){
  TableNode tableNode=(TableNode)element;
  int type=tableNode.getType();
switch (columnIndex) {
case 0:
    String value=tableNode.getValue();
  if (value == null) {
    return "String_Node_Str";
  }
return value;
case 1:
if (type == TableNode.CATALOG) {
return "String_Node_Str";
}
 else if (type == TableNode.SCHEMA) {
return "String_Node_Str";
}
 else {
return tableNode.getItemType();
}
default :
return "String_Node_Str";
}
}
Program: 125120
Project: 125120
Buggy source:
public String getDefaultCatalogName(){
  return CATALOG_NAME;
}

Fixed version (ground truth):
@Override public String getDefaultCatalogName(){
  return CATALOG_NAME;
}
Program: 125121
Project: 125121
Buggy source:
public void inputChanged(Viewer viewer,Object oldInput,Object newInput){
}

Fixed version (ground truth):
@Override public void inputChanged(Viewer viewer,Object oldInput,Object newInput){
}
Program: 125122
Project: 125122
Buggy source:
public List<String> returnTablesFormConnection(IMetadataConnection metadataConnection){
  List<String> toReturn=new ArrayList<String>();
  try {
    HBaseAdmin hAdmin=getAdmin(metadataConnection);
    HTableDescriptor[] allTables=hAdmin.listTables();
    for (    HTableDescriptor td : allTables) {
      toReturn.add(td.getNameAsString());
    }
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
  return toReturn;
}

Fixed version (ground truth):
@Override public List<String> returnTablesFormConnection(IMetadataConnection metadataConnection){
  List<String> toReturn=new ArrayList<String>();
  try {
    HBaseAdmin hAdmin=getAdmin(metadataConnection);
    HTableDescriptor[] allTables=hAdmin.listTables();
    for (    HTableDescriptor td : allTables) {
      toReturn.add(td.getNameAsString());
    }
  }
 catch (  IOException e) {
    e.printStackTrace();
  }
  return toReturn;
}
Program: 125123
Project: 125123
Buggy source:
public void fillConnection(DatabaseConnection connection){
  Catalog defaultCatalog=CatalogHelper.createCatalog(getDefaultCatalogName());
  ConnectionHelper.addPackage(defaultCatalog,connection);
  connection.setSID(getDefaultCatalogName());
}

Fixed version (ground truth):
@Override public void fillConnection(DatabaseConnection connection){
  Catalog defaultCatalog=CatalogHelper.createCatalog(getDefaultCatalogName());
  ConnectionHelper.addPackage(defaultCatalog,connection);
  connection.setSID(getDefaultCatalogName());
}
Program: 125125
Project: 125125
Buggy source:
/** 
 * When clicking the "Run" button, this action will be invoked.<br> Workflow job state valid transitions: <li>--> PREP <li>PREP --> RUNNING | KILLED <li>RUNNING --> SUSPENDED | SUCCEEDED | KILLED | FAILED <li>SUSPENDED --> RUNNING | KILLED
 */
public void doRunAction(){
  try {
    JobContext jobContext=initJobCotextForOozie(JobSubmissionType.REMOTE);
    String jobIdInOozie=CorePlugin.getDefault().getPreferenceStore().getString("String_Node_Str" + jobContext.getJobName());
    if (jobIdInOozie != null)     traceManager.removeTrace(jobIdInOozie);
    doRunJob(jobContext);
  }
 catch (  Exception e) {
    ExceptionHandler.process(e);
  }
}

Fixed version (ground truth):
/** 
 * When clicking the "Run" button, this action will be invoked.<br> Workflow job state valid transitions: <li>--> PREP <li>PREP --> RUNNING | KILLED <li>RUNNING --> SUSPENDED | SUCCEEDED | KILLED | FAILED <li>SUSPENDED --> RUNNING | KILLED
 * @param iContext
 */
public void doRunAction(IContext iContext){
  try {
    JobContext jobContext=initJobContextForOozie(JobSubmissionType.REMOTE,iContext);
    String jobIdInOozie=CorePlugin.getDefault().getPreferenceStore().getString("String_Node_Str" + jobContext.getJobName());
    if (jobIdInOozie != null)     traceManager.removeTrace(jobIdInOozie);
    doRunJob(jobContext);
  }
 catch (  Exception e) {
    ExceptionHandler.process(e);
  }
}
Program: 125126
Project: 125126
Buggy source:
private void deployJobOnHadoop(StringBuffer output,JobContext jobContext) throws OozieJobDeployException {
  String jobIdInOozie=CorePlugin.getDefault().getPreferenceStore().getString("String_Node_Str" + jobContext.getJobName());
  output.append(outputCurrentDate());
  output.append(OutputMessages.MSG_OUTPUT_DEPLOYING + OutputMessages.LINE_BREAK_CHAR);
  updateOutputTextContents(output.toString(),jobContext.getJobName());
  try {
    OozieJobDeployer.deployJob(OozieJobTrackerListener.getProcess(),new NullProgressMonitor());
    output.append(outputCurrentDate());
    output.append(OutputMessages.MSG_OUTPUT_DEPLOY_COMPLETE);
    output.append(OutputMessages.LINE_BREAK_CHAR);
  }
 catch (  OozieJobDeployException e) {
    output.append(outputCurrentDate());
    output.append(OutputMessages.MSG_OUTPUT_DEPLOY_FAILED);
    output.append(OutputMessages.LINE_BREAK_CHAR);
    output.append(outputCurrentDate());
    output.append(e.getMessage());
    output.append(OutputMessages.LINE_BREAK_CHAR);
    output.append(outputCurrentDate());
    output.append(e.getCause().getMessage());
    output.append(OutputMessages.LINE_BREAK_CHAR);
    updateOutputTextContents(output.toString(),jobContext.getJobName());
    throw e;
  }
  updateOutputTextContents(output.toString(),jobContext.getJobName());
}

Fixed version (ground truth):
private void deployJobOnHadoop(StringBuffer output,JobContext jobContext) throws OozieJobDeployException {
  output.append(outputCurrentDate());
  output.append(OutputMessages.MSG_OUTPUT_DEPLOYING + OutputMessages.LINE_BREAK_CHAR);
  updateOutputTextContents(output.toString(),jobContext.getJobName());
  try {
    OozieJobDeployer.deployJob(OozieJobTrackerListener.getProcess(),new NullProgressMonitor());
    output.append(outputCurrentDate());
    output.append(OutputMessages.MSG_OUTPUT_DEPLOY_COMPLETE);
    output.append(OutputMessages.LINE_BREAK_CHAR);
  }
 catch (  OozieJobDeployException e) {
    output.append(outputCurrentDate());
    output.append(OutputMessages.MSG_OUTPUT_DEPLOY_FAILED);
    output.append(OutputMessages.LINE_BREAK_CHAR);
    output.append(outputCurrentDate());
    output.append(e.getMessage());
    output.append(OutputMessages.LINE_BREAK_CHAR);
    output.append(outputCurrentDate());
    output.append(e.getCause().getMessage());
    output.append(OutputMessages.LINE_BREAK_CHAR);
    updateOutputTextContents(output.toString(),jobContext.getJobName());
    throw e;
  }
  updateOutputTextContents(output.toString(),jobContext.getJobName());
}
Program: 125127
Project: 125127
Buggy source:
/** 
 * When clicking the "Schedule" button, this action will open a dialog to provide some configurations for scheduling. If <code>Window.OK == Dialog.open</code>, will invoke the method.
 */
public void doScheduleAction(){
  Shell shell=executeJobComposite.getShell();
  schedulingDialog=new SchedulingDialog(shell);
  initScheduling(schedulingDialog);
  if (Window.OK == schedulingDialog.open()) {
    try {
      OozieJobDeployer.deployJob(OozieJobTrackerListener.getProcess(),new NullProgressMonitor());
      JobContext jobContext=initJobCotextForOozie(JobSubmissionType.SCHEDULED);
      updateAllEnabledOrNot(OozieJobProcessStatus.PREP,OozieJobTrackerListener.getProcess().getLabel());
      doScheduleJob(jobContext);
    }
 catch (    Exception e) {
      ExceptionHandler.process(e);
    }
  }
}

Fixed version (ground truth):
/** 
 * When clicking the "Schedule" button, this action will open a dialog to provide some configurations for scheduling. If <code>Window.OK == Dialog.open</code>, will invoke the method.
 */
public void doScheduleAction(IContext context){
  Shell shell=executeJobComposite.getShell();
  schedulingDialog=new SchedulingDialog(shell);
  initScheduling(schedulingDialog);
  if (Window.OK == schedulingDialog.open()) {
    String jobName=null;
    try {
      JobContext jobContext=initJobContextForOozie(JobSubmissionType.SCHEDULED,context);
      jobName=jobContext.getJobName();
      OozieJobDeployer.deployJob(OozieJobTrackerListener.getProcess(),new NullProgressMonitor());
      updateAllEnabledOrNot(OozieJobProcessStatus.PREP,OozieJobTrackerListener.getProcess().getLabel());
      doScheduleJob(jobContext);
    }
 catch (    Exception e) {
      StringBuffer output=new StringBuffer();
      output.append(e.getMessage());
      output.append(OutputMessages.LINE_BREAK_CHAR);
      output.append(e.getCause().getMessage());
      output.append(OutputMessages.LINE_BREAK_CHAR);
      updateOutputTextContents(output.toString(),jobName);
    }
  }
}
Program: 125130
Project: 125130
Buggy source:
protected void regScheduleBtnListener(){
  scheduleBtn.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      executeJobCompController.doScheduleAction();
    }
  }
);
}

Fixed version (ground truth):
protected void regScheduleBtnListener(){
  scheduleBtn.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      executeJobCompController.doScheduleAction(contextComposite.getSelectedContext());
    }
  }
);
}
Program: 125131
Project: 125131
Buggy source:
protected void regRunBtnListener(){
  runBtn.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      executeJobCompController.doRunAction();
    }
  }
);
}

Fixed version (ground truth):
protected void regRunBtnListener(){
  runBtn.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      executeJobCompController.doRunAction(contextComposite.getSelectedContext());
    }
  }
);
}
Program: 125132
Project: 125132
Buggy source:
public void setPathValue(String pathValue){
  if (getEditor() != null && !pathValue.equals(getPathValue()) && !OozieJobTrackerListener.getProcess().isReadOnly()) {
    IProcess2 process=OozieJobTrackerListener.getProcess();
    getCommandStack().execute(new PropertyChangeCommand(process,"String_Node_Str",pathValue));
  }
}

Fixed version (ground truth):
public void setPathValue(String pathValue){
  if (getEditor() != null && !pathValue.equals(getPathValue()) && !OozieJobTrackerListener.getProcess().isReadOnly()) {
    IProcess2 process=OozieJobTrackerListener.getProcess();
    getCommandStack().execute(new PropertyChangeCommand(process,"String_Node_Str",pathValue.trim()));
  }
}
Program: 125133
Project: 125133
Buggy source:
public void refresh(){
  IProcess2 process=OozieJobTrackerListener.getProcess();
  if (process != null) {
    String label=process.getLabel();
    if (executeJobComposite != null && !executeJobComposite.isDisposed()) {
      executeJobComposite.initValues();
    }
    tabFactory.setTitle(Messages.getString("String_Node_Str",label),null);
    setPartName(Messages.getString("String_Node_Str",label));
    contextComposite.setProcess(process);
  }
 else {
    tabFactory.setTitle(Messages.getString("String_Node_Str"),null);
    setPartName(Messages.getString("String_Node_Str"));
    if (executeJobComposite != null && !executeJobComposite.isDisposed()) {
      executeJobComposite.initValues();
    }
    contextComposite.setProcess(null);
  }
}

Fixed version (ground truth):
public void refresh(){
  IProcess2 process=OozieJobTrackerListener.getProcess();
  if (process != null) {
    String label=process.getLabel();
    if (executeJobComposite != null && !executeJobComposite.isDisposed()) {
      executeJobComposite.initValues();
      executeJobComposite.setContextComposite(contextComposite);
    }
    tabFactory.setTitle(Messages.getString("String_Node_Str",label),null);
    setPartName(Messages.getString("String_Node_Str",label));
    contextComposite.setProcess(process);
  }
 else {
    tabFactory.setTitle(Messages.getString("String_Node_Str"),null);
    setPartName(Messages.getString("String_Node_Str"));
    if (executeJobComposite != null && !executeJobComposite.isDisposed()) {
      executeJobComposite.initValues();
    }
    contextComposite.setProcess(null);
  }
}
Program: 125134
Project: 125134
Buggy source:
public void setMultiPageTalendEditor(AbstractMultiPageTalendEditor multiPageTalendEditor){
  this.multiPageTalendEditor=multiPageTalendEditor;
  executeJobCompController.setMultiPageTalendEditor(multiPageTalendEditor);
  checkScheduleBtnValid();
  checkRunBtnValid();
  checkKillBtnValid();
  if (multiPageTalendEditor != null) {
    pathText.setEnabled(true);
    pathText.setText(getPathValue());
    outputTxt.setEnabled(true);
  }
 else {
    pathText.setEnabled(false);
    pathText.setText("String_Node_Str");
    outputTxt.setText("String_Node_Str");
    outputTxt.setEnabled(false);
  }
}

Fixed version (ground truth):
public void setMultiPageTalendEditor(AbstractMultiPageTalendEditor multiPageTalendEditor){
  this.multiPageTalendEditor=multiPageTalendEditor;
  executeJobCompController.setMultiPageTalendEditor(multiPageTalendEditor);
  checkScheduleBtnValid();
  checkRunBtnValid();
  checkKillBtnValid();
  if (!pathText.isDisposed() && !outputTxt.isDisposed()) {
    if (multiPageTalendEditor != null) {
      pathText.setEnabled(true);
      pathText.setText(getPathValue());
      outputTxt.setEnabled(true);
    }
 else {
      pathText.setEnabled(false);
      pathText.setText("String_Node_Str");
      outputTxt.setText("String_Node_Str");
      outputTxt.setEnabled(false);
    }
  }
}
Program: 125135
Project: 125135
Buggy source:
@Override public void refresh(){
}

Fixed version (ground truth):
@Override public void refresh(){
  if (!isDisposed()) {
    getParent().layout();
  }
}
Program: 125136
Project: 125136
Buggy source:
@Override public IMultiPageTalendEditor getPart(){
  return null;
}

Fixed version (ground truth):
@Override public IMultiPageTalendEditor getPart(){
  return multiPageTalendEditor;
}