nus-yam/ex-repair huggingface dataset:
Program: 9743
Project: 9743
Buggy source:
@Test public void computeAllNBRsBruteForce(){
  Set<QueryTree<String>> posExampleTrees=DBpediaExample.getPosExampleTrees();
  Set<QueryTree<String>> negExampleTrees=DBpediaExample.getNegExampleTrees();
  LGGGenerator<String> lggGenerator=new LGGGeneratorImpl<String>();
  NBRGenerator<String> nbrGenerator=new NBRGeneratorImpl<String>(new BruteForceNBRStrategy<String>());
  int cnt=1;
  for (  QueryTree<String> tree : posExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump(new PrintWriter(System.out));
    System.out.println("String_Node_Str");
    cnt++;
  }
  QueryTree<String> lgg=lggGenerator.getLGG(posExampleTrees);
  System.out.println("String_Node_Str");
  lgg.dump(new PrintWriter(System.out));
  System.out.println("String_Node_Str");
  cnt=1;
  for (  QueryTree<String> tree : negExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump(new PrintWriter(System.out));
    System.out.println("String_Node_Str");
    cnt++;
  }
  Set<QueryTree<String>> nbrs=nbrGenerator.getNBRs(lgg,negExampleTrees);
  cnt=1;
  for (  QueryTree<String> tree : nbrs) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump(new PrintWriter(System.out));
    System.out.println("String_Node_Str");
    cnt++;
  }
}

Fixed version (ground truth):
@Test public void computeAllNBRsBruteForce(){
  Set<QueryTree<String>> posExampleTrees=DBpediaExample.getPosExampleTrees();
  Set<QueryTree<String>> negExampleTrees=DBpediaExample.getNegExampleTrees();
  LGGGenerator<String> lggGenerator=new LGGGeneratorImpl<String>();
  NBRGenerator<String> nbrGenerator=new NBRGeneratorImpl<String>(new BruteForceNBRStrategy<String>());
  int cnt=1;
  for (  QueryTree<String> tree : posExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump();
    System.out.println("String_Node_Str");
    cnt++;
  }
  QueryTree<String> lgg=lggGenerator.getLGG(posExampleTrees);
  System.out.println("String_Node_Str");
  lgg.dump();
  System.out.println("String_Node_Str");
  cnt=1;
  for (  QueryTree<String> tree : negExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump();
    System.out.println("String_Node_Str");
    cnt++;
  }
  Set<QueryTree<String>> nbrs=nbrGenerator.getNBRs(lgg,negExampleTrees);
  cnt=1;
  for (  QueryTree<String> tree : nbrs) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump();
    System.out.println("String_Node_Str");
    cnt++;
  }
}
Program: 9744
Project: 9744
Buggy source:
@Test public void computeSingleNBRBruteForce(){
  Set<QueryTree<String>> posExampleTrees=DBpediaExample.getPosExampleTrees();
  Set<QueryTree<String>> negExampleTrees=DBpediaExample.getNegExampleTrees();
  LGGGenerator<String> lggGenerator=new LGGGeneratorImpl<String>();
  NBRGenerator<String> nbrGenerator=new NBRGeneratorImpl<String>(new BruteForceNBRStrategy<String>());
  int cnt=1;
  for (  QueryTree<String> tree : posExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump(new PrintWriter(System.out));
    System.out.println("String_Node_Str");
    cnt++;
  }
  QueryTree<String> lgg=lggGenerator.getLGG(posExampleTrees);
  System.out.println("String_Node_Str");
  lgg.dump(new PrintWriter(System.out));
  System.out.println("String_Node_Str");
  cnt=1;
  for (  QueryTree<String> tree : negExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump(new PrintWriter(System.out));
    System.out.println("String_Node_Str");
    cnt++;
  }
  System.out.println("String_Node_Str");
  QueryTree<String> nbr=nbrGenerator.getNBR(lgg,negExampleTrees);
  nbr.dump(new PrintWriter(System.out));
}

Fixed version (ground truth):
@Test public void computeSingleNBRBruteForce(){
  Set<QueryTree<String>> posExampleTrees=DBpediaExample.getPosExampleTrees();
  Set<QueryTree<String>> negExampleTrees=DBpediaExample.getNegExampleTrees();
  LGGGenerator<String> lggGenerator=new LGGGeneratorImpl<String>();
  NBRGenerator<String> nbrGenerator=new NBRGeneratorImpl<String>(new BruteForceNBRStrategy<String>());
  int cnt=1;
  for (  QueryTree<String> tree : posExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump();
    System.out.println("String_Node_Str");
    cnt++;
  }
  QueryTree<String> lgg=lggGenerator.getLGG(posExampleTrees);
  System.out.println("String_Node_Str");
  lgg.dump();
  System.out.println("String_Node_Str");
  cnt=1;
  for (  QueryTree<String> tree : negExampleTrees) {
    System.out.println("String_Node_Str" + cnt);
    tree.dump();
    System.out.println("String_Node_Str");
    cnt++;
  }
  QueryTree<String> nbr=nbrGenerator.getNBR(lgg,negExampleTrees);
  System.out.println("String_Node_Str");
  nbr.dump();
}
Program: 9745
Project: 9745
Buggy source:
private static SortedSet<PropertyContext> getForallContexts(Description description,PropertyContext currentContext){
  if (description instanceof Restriction) {
    Property op=(Property)((Restriction)description).getRestrictedPropertyExpression();
    if (op instanceof ObjectProperty) {
      currentContext.add((ObjectProperty)op);
      if (description instanceof ObjectAllRestriction) {
        TreeSet<PropertyContext> contexts=new TreeSet<PropertyContext>();
        contexts.add(currentContext);
        contexts.addAll(getForallContexts(description.getChild(0),currentContext));
        return contexts;
      }
 else {
        return getForallContexts(description.getChild(0),currentContext);
      }
    }
 else {
      return new TreeSet<PropertyContext>();
    }
  }
 else {
    TreeSet<PropertyContext> contexts=new TreeSet<PropertyContext>();
    for (    Description child : description.getChildren()) {
      contexts.addAll(getForallContexts(child,currentContext));
    }
    return contexts;
  }
}

Fixed version (ground truth):
private static SortedSet<PropertyContext> getForallContexts(Description description,PropertyContext currentContext){
  if (description instanceof Restriction) {
    Property op=(Property)((Restriction)description).getRestrictedPropertyExpression();
    if (op instanceof ObjectProperty) {
      PropertyContext currentContextCopy=(PropertyContext)currentContext.clone();
      if (description instanceof ObjectAllRestriction) {
        currentContextCopy.add((ObjectProperty)op);
        TreeSet<PropertyContext> contexts=new TreeSet<PropertyContext>();
        contexts.add(currentContextCopy);
        contexts.addAll(getForallContexts(description.getChild(0),currentContextCopy));
        return contexts;
      }
 else       if (description.getChildren().size() > 0) {
        currentContextCopy.add((ObjectProperty)op);
        return getForallContexts(description.getChild(0),currentContextCopy);
      }
 else {
        return new TreeSet<PropertyContext>();
      }
    }
 else {
      return new TreeSet<PropertyContext>();
    }
  }
 else {
    TreeSet<PropertyContext> contexts=new TreeSet<PropertyContext>();
    for (    Description child : description.getChildren()) {
      contexts.addAll(getForallContexts(child,currentContext));
    }
    return contexts;
  }
}
Program: 9746
Project: 9746
Buggy source:
public void visit(DisjointClassesAxiom axiom){
  Set<Description> descriptions=axiom.getDescriptions();
  Set<OWLClassExpression> owlAPIDescriptions=new HashSet<OWLClassExpression>();
  for (  Description description : descriptions)   owlAPIDescriptions.add(getOWLClassExpression(description));
  OWLAxiom axiomOWLAPI=factory.getOWLDisjointClassesAxiom(owlAPIDescriptions);
  addAxiom(axiomOWLAPI);
}

Fixed version (ground truth):
@Override public void visit(StringDatatypePropertyAssertion axiom){
  throw new UnsupportedOperationException("String_Node_Str");
}
Program: 9747
Project: 9747
Buggy source:
public Set<OWLClass> getInconsistentOWLClasses(){
  return reasoner.getUnsatisfiableClasses().getEntities();
}

Fixed version (ground truth):
public Set<OWLClass> getInconsistentOWLClasses(){
  return reasoner.getUnsatisfiableClasses().getEntitiesMinusBottom();
}
Program: 9750
Project: 9750
Buggy source:
@Override public Set<NamedClass> getInconsistentClassesImpl(){
  Set<NamedClass> concepts=new HashSet<NamedClass>();
  for (  OWLClass concept : reasoner.getUnsatisfiableClasses().getEntities()) {
    concepts.add(new NamedClass(concept.toStringID()));
  }
  return concepts;
}

Fixed version (ground truth):
@Override public Set<NamedClass> getInconsistentClassesImpl(){
  Set<NamedClass> concepts=new HashSet<NamedClass>();
  for (  OWLClass concept : reasoner.getUnsatisfiableClasses().getEntitiesMinusBottom()) {
    concepts.add(new NamedClass(concept.toStringID()));
  }
  return concepts;
}
Program: 9751
Project: 9751
Buggy source:
private SortedSet<Description> getNegClassCandidatesRecursive(Description index,Description lowerClass){
  SortedSet<Description> candidates=new TreeSet<Description>(conceptComparator);
  for (  Description candidate : subHierarchy.getSuperClasses(lowerClass)) {
    if (!isDisjoint(new Negation(candidate),index)) {
      boolean meaningful;
      if (instanceBasedDisjoints) {
        SortedSet<Individual> tmp=rs.getIndividuals(lowerClass);
        tmp.removeAll(rs.getIndividuals(new Negation(candidate)));
        meaningful=tmp.size() != 0;
      }
 else {
        meaningful=!isDisjoint(candidate,index);
      }
      if (meaningful) {
        candidates.add(new Negation(candidate));
      }
 else {
        candidates.addAll(getClassCandidatesRecursive(index,candidate));
      }
    }
  }
  return candidates;
}

Fixed version (ground truth):
private SortedSet<Description> getNegClassCandidatesRecursive(Description index,Description lowerClass){
  SortedSet<Description> candidates=new TreeSet<Description>(conceptComparator);
  for (  Description candidate : subHierarchy.getSuperClasses(lowerClass)) {
    if (!(candidate instanceof Thing)) {
      if (!isDisjoint(new Negation(candidate),index)) {
        boolean meaningful;
        if (instanceBasedDisjoints) {
          SortedSet<Individual> tmp=rs.getIndividuals(index);
          tmp.removeAll(rs.getIndividuals(new Negation(candidate)));
          meaningful=tmp.size() != 0;
        }
 else {
          meaningful=!isDisjoint(candidate,index);
        }
        if (meaningful) {
          candidates.add(new Negation(candidate));
        }
 else {
          candidates.addAll(getNegClassCandidatesRecursive(index,candidate));
        }
      }
    }
  }
  return candidates;
}
Program: 9752
Project: 9752
Buggy source:
private SortedSet<Description> getClassCandidatesRecursive(Description index,Description upperClass){
  SortedSet<Description> candidates=new TreeSet<Description>();
  for (  Description candidate : subHierarchy.getSubClasses(upperClass)) {
    if (!isDisjoint(candidate,index)) {
      boolean meaningful;
      if (instanceBasedDisjoints) {
        SortedSet<Individual> tmp=rs.getIndividuals(upperClass);
        tmp.removeAll(rs.getIndividuals(candidate));
        meaningful=tmp.size() != 0;
      }
 else {
        meaningful=!isDisjoint(new Negation(candidate),index);
      }
      if (meaningful) {
        candidates.add(candidate);
      }
 else {
        candidates.addAll(getClassCandidatesRecursive(index,candidate));
      }
    }
  }
  return candidates;
}

Fixed version (ground truth):
private SortedSet<Description> getClassCandidatesRecursive(Description index,Description upperClass){
  SortedSet<Description> candidates=new TreeSet<Description>();
  for (  Description candidate : subHierarchy.getSubClasses(upperClass)) {
    if (!isDisjoint(candidate,index)) {
      boolean meaningful;
      if (instanceBasedDisjoints) {
        SortedSet<Individual> tmp=rs.getIndividuals(index);
        tmp.removeAll(rs.getIndividuals(candidate));
        meaningful=tmp.size() != 0;
      }
 else {
        meaningful=!isDisjoint(new Negation(candidate),index);
      }
      if (meaningful) {
        candidates.add(candidate);
      }
 else {
        candidates.addAll(getClassCandidatesRecursive(index,candidate));
      }
    }
  }
  return candidates;
}
Program: 9754
Project: 9754
Buggy source:
private Set<OWLDisjointClassesAxiom> retrieveDisjointClassAxioms(){
  logger.info("String_Node_Str");
  queryMonitor.start();
  StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str");
  sb.append("String_Node_Str").append("String_Node_Str").append(OWL.disjointWith).append("String_Node_Str").append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str").append(RESULT_LIMIT);
  Query query=QueryFactory.create(sb.toString());
  QueryExecution sparqlQueryExec=QueryExecutionFactory.sparqlService(endpointURI,query,DEFAULT_GRAPH_URI);
  ResultSet sparqlResults=sparqlQueryExec.execSelect();
  Set<OWLDisjointClassesAxiom> axioms=new HashSet<OWLDisjointClassesAxiom>();
  QuerySolution solution;
  RDFNode rdfNodeSubject;
  RDFNode rdfNodeObject;
  OWLClass disjointClass1;
  OWLClass disjointClass2;
  while (sparqlResults.hasNext()) {
    solution=sparqlResults.nextSolution();
    rdfNodeSubject=solution.getResource("String_Node_Str");
    rdfNodeObject=solution.getResource("String_Node_Str");
    if (rdfNodeSubject.isAnon() || rdfNodeObject.isAnon()) {
      continue;
    }
    disjointClass1=factory.getOWLClass(IRI.create(rdfNodeSubject.toString()));
    disjointClass2=factory.getOWLClass(IRI.create(rdfNodeObject.toString()));
    axioms.add(factory.getOWLDisjointClassesAxiom(disjointClass1,disjointClass2));
  }
  queryMonitor.stop();
  logger.info("String_Node_Str" + axioms.size() + "String_Node_Str"+ queryMonitor.getLastValue()+ "String_Node_Str");
  return axioms;
}

Fixed version (ground truth):
private Set<OWLDisjointClassesAxiom> retrieveDisjointClassAxioms(){
  logger.info("String_Node_Str");
  queryMonitor.start();
  StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str");
  sb.append("String_Node_Str").append("String_Node_Str").append(OWL.disjointWith).append("String_Node_Str").append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str").append(RESULT_LIMIT);
  System.out.println(sb);
  Query query=QueryFactory.create(sb.toString());
  QueryExecution sparqlQueryExec=QueryExecutionFactory.sparqlService(endpointURI,query,DEFAULT_GRAPH_URI);
  ResultSet sparqlResults=sparqlQueryExec.execSelect();
  Set<OWLDisjointClassesAxiom> axioms=new HashSet<OWLDisjointClassesAxiom>();
  QuerySolution solution;
  RDFNode rdfNodeSubject;
  RDFNode rdfNodeObject;
  OWLClass disjointClass1;
  OWLClass disjointClass2;
  while (sparqlResults.hasNext()) {
    solution=sparqlResults.nextSolution();
    rdfNodeSubject=solution.getResource("String_Node_Str");
    rdfNodeObject=solution.getResource("String_Node_Str");
    if (rdfNodeSubject.isAnon() || rdfNodeObject.isAnon()) {
      continue;
    }
    disjointClass1=factory.getOWLClass(IRI.create(rdfNodeSubject.toString()));
    disjointClass2=factory.getOWLClass(IRI.create(rdfNodeObject.toString()));
    axioms.add(factory.getOWLDisjointClassesAxiom(disjointClass1,disjointClass2));
  }
  queryMonitor.stop();
  logger.info("String_Node_Str" + axioms.size() + "String_Node_Str"+ queryMonitor.getLastValue()+ "String_Node_Str");
  return axioms;
}
Program: 9761
Project: 9761
Buggy source:
public static Collection<ConfigOption<?>> createConfigOptions(){
  Collection<ConfigOption<?>> options=new LinkedList<ConfigOption<?>>();
  options.add(CommonConfigOptions.useAllConstructor());
  options.add(CommonConfigOptions.useExistsConstructor());
  options.add(CommonConfigOptions.useHasValueConstructor());
  options.add(CommonConfigOptions.useDataHasValueConstructor());
  options.add(CommonConfigOptions.valueFreqencyThreshold());
  options.add(CommonConfigOptions.useCardinalityRestrictions());
  options.add(CommonConfigOptions.cardinalityLimit());
  options.add(CommonConfigOptions.useNegation(false));
  options.add(CommonConfigOptions.useBooleanDatatypes());
  options.add(CommonConfigOptions.useDoubleDatatypes());
  options.add(CommonConfigOptions.maxExecutionTimeInSeconds(10));
  options.add(CommonConfigOptions.getNoisePercentage());
  options.add(CommonConfigOptions.getMaxDepth(7));
  options.add(CommonConfigOptions.maxNrOfResults(10));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(CommonConfigOptions.getInstanceBasedDisjoints());
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  return options;
}

Fixed version (ground truth):
public static Collection<ConfigOption<?>> createConfigOptions(){
  Collection<ConfigOption<?>> options=new LinkedList<ConfigOption<?>>();
  options.add(CommonConfigOptions.useAllConstructor());
  options.add(CommonConfigOptions.useExistsConstructor());
  options.add(CommonConfigOptions.useHasValueConstructor());
  options.add(CommonConfigOptions.useDataHasValueConstructor());
  options.add(CommonConfigOptions.valueFreqencyThreshold());
  options.add(CommonConfigOptions.useCardinalityRestrictions());
  options.add(CommonConfigOptions.cardinalityLimit());
  options.add(CommonConfigOptions.useNegation(false));
  options.add(CommonConfigOptions.useBooleanDatatypes());
  options.add(CommonConfigOptions.useDoubleDatatypes());
  options.add(CommonConfigOptions.maxExecutionTimeInSeconds(10));
  options.add(CommonConfigOptions.getNoisePercentage());
  options.add(CommonConfigOptions.getMaxDepth(7));
  options.add(CommonConfigOptions.maxNrOfResults(10));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(CommonConfigOptions.getInstanceBasedDisjoints());
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  options.add(new StringConfigOption("String_Node_Str","String_Node_Str","String_Node_Str"));
  options.add(new BooleanConfigOption("String_Node_Str","String_Node_Str",false));
  return options;
}
Program: 9763
Project: 9763
Buggy source:
@Override public SortedSet<Individual> getIndividualsImpl(Description concept){
  OWLClassExpression d=OWLAPIDescriptionConvertVisitor.getOWLClassExpression(concept);
  Set<OWLNamedIndividual> individuals=reasoner.getInstances(d,false).getFlattened();
  SortedSet<Individual> inds=new TreeSet<Individual>();
  for (  OWLNamedIndividual ind : individuals)   inds.add(new Individual(ind.toStringID()));
  return inds;
}

Fixed version (ground truth):
@Override public SortedSet<Individual> getIndividualsImpl(Description concept){
  OWLClassExpression d=OWLAPIDescriptionConvertVisitor.getOWLClassExpression(concept);
  Set<OWLNamedIndividual> individuals=reasoner.getInstances(d,false).getFlattened();
  SortedSet<Individual> inds=new TreeSet<Individual>();
  for (  OWLNamedIndividual ind : individuals)   if (ind != null)   inds.add(new Individual(ind.toStringID()));
  return inds;
}
Program: 9764
Project: 9764
Buggy source:
public SuggestionsTable(OWLEditorKit editorKit){
  super(new SuggestionsTableModel());
  progressRenderer=new ProgressBarTableCellRenderer();
  progressRenderer.setBackground(getBackground());
  getColumn(0).setCellRenderer(progressRenderer);
  owlRenderer=new OWLCellRenderer(editorKit,false,false);
  owlRenderer.setHighlightKeywords(true);
  owlRenderer.setHighlightUnsatisfiableClasses(false);
  owlRenderer.setHighlightUnsatisfiableProperties(false);
  owlRenderer.setWrap(false);
  getColumn(2).setCellRenderer(owlRenderer);
  setColumnSizes();
}

Fixed version (ground truth):
public SuggestionsTable(OWLEditorKit editorKit){
  super(new SuggestionsTableModel());
  progressRenderer=new ProgressBarTableCellRenderer();
  progressRenderer.setBackground(getBackground());
  getColumn(0).setCellRenderer(progressRenderer);
  owlRenderer=new OWLCellRenderer(editorKit,false,false);
  owlRenderer.setHighlightKeywords(true);
  owlRenderer.setHighlightUnsatisfiableClasses(false);
  owlRenderer.setHighlightUnsatisfiableProperties(false);
  owlRenderer.setWrap(false);
  getColumn(2).setCellRenderer(owlRenderer);
  setColumnSizes();
  Comparator<Integer> comparator=new Comparator<Integer>(){
    @Override public int compare(    Integer o1,    Integer o2){
      return o1.compareTo(o2);
    }
  }
;
  getColumnExt(0).setComparator(comparator);
}
Program: 9766
Project: 9766
Buggy source:
@Override public Description getRangeImpl(ObjectProperty objectProperty){
  OWLObjectProperty prop=OWLAPIConverter.getOWLAPIObjectProperty(objectProperty);
  NodeSet<OWLClass> set=reasoner.getObjectPropertyRanges(prop,true);
  if (set.isEmpty())   return new Thing();
  OWLClass oc=set.iterator().next().getRepresentativeElement();
  return new NamedClass(oc.toStringID());
}

Fixed version (ground truth):
@Override public Description getRangeImpl(ObjectProperty objectProperty){
  OWLObjectProperty prop=OWLAPIConverter.getOWLAPIObjectProperty(objectProperty);
  NodeSet<OWLClass> set=reasoner.getObjectPropertyRanges(prop,true);
  if (set.isEmpty())   return new Thing();
  OWLClass oc=set.iterator().next().getRepresentativeElement();
  if (oc.isOWLThing()) {
    return Thing.instance;
  }
  return new NamedClass(oc.toStringID());
}
Program: 9768
Project: 9768
Buggy source:
@Override public Description getRangeImpl(ObjectProperty objectProperty){
  OWLObjectProperty prop=OWLAPIConverter.getOWLAPIObjectProperty(objectProperty);
  NodeSet<OWLClass> set=reasoner.getObjectPropertyRanges(prop,true);
  if (set.isEmpty())   return new Thing();
  OWLClass oc=set.iterator().next().getRepresentativeElement();
  return new NamedClass(oc.toStringID());
}

Fixed version (ground truth):
@Override public Description getRangeImpl(ObjectProperty objectProperty){
  OWLObjectProperty prop=OWLAPIConverter.getOWLAPIObjectProperty(objectProperty);
  NodeSet<OWLClass> set=reasoner.getObjectPropertyRanges(prop,true);
  if (set.isEmpty())   return new Thing();
  OWLClass oc=set.iterator().next().getRepresentativeElement();
  return getDescriptionFromReturnedDomain(set);
}
Program: 9769
Project: 9769
Buggy source:
private SortedSet<Description> getNegClassCandidatesRecursive(Description index,Description lowerClass){
  SortedSet<Description> candidates=new TreeSet<Description>();
  for (  Description candidate : subHierarchy.getSuperClasses(lowerClass)) {
    if (!isDisjoint(new Negation(candidate),index)) {
      boolean meaningful;
      if (instanceBasedDisjoints) {
        SortedSet<Individual> tmp=rs.getIndividuals(lowerClass);
        tmp.removeAll(rs.getIndividuals(new Negation(candidate)));
        meaningful=tmp.size() != 0;
      }
 else {
        meaningful=!isDisjoint(candidate,index);
      }
      if (meaningful) {
        candidates.add(new Negation(candidate));
      }
 else {
        candidates.addAll(getClassCandidatesRecursive(index,candidate));
      }
    }
  }
  return candidates;
}

Fixed version (ground truth):
private SortedSet<Description> getNegClassCandidatesRecursive(Description index,Description lowerClass){
  SortedSet<Description> candidates=new TreeSet<Description>(conceptComparator);
  for (  Description candidate : subHierarchy.getSuperClasses(lowerClass)) {
    if (!isDisjoint(new Negation(candidate),index)) {
      boolean meaningful;
      if (instanceBasedDisjoints) {
        SortedSet<Individual> tmp=rs.getIndividuals(lowerClass);
        tmp.removeAll(rs.getIndividuals(new Negation(candidate)));
        meaningful=tmp.size() != 0;
      }
 else {
        meaningful=!isDisjoint(candidate,index);
      }
      if (meaningful) {
        candidates.add(new Negation(candidate));
      }
 else {
        candidates.addAll(getClassCandidatesRecursive(index,candidate));
      }
    }
  }
  return candidates;
}
Program: 9773
Project: 9773
Buggy source:
public void removeSelection(OWLAxiom ax){
  selectedAxioms.remove(ax);
  fireImpactListChanged();
}

Fixed version (ground truth):
public void removeSelection(OWLAxiom ax){
  if (selectedAxioms.remove(ax)) {
    fireImpactListChanged();
  }
}
Program: 9774
Project: 9774
Buggy source:
public LaconicExplanationGenerator(OWLOntologyManager manager,OWLReasonerFactory reasonerFactory,Set<OWLOntology> ontologies){
  this.manager=manager;
  try {
    ontology=manager.createOntology(URI.create(new StringBuilder().append("String_Node_Str").append(System.nanoTime()).toString()),ontologies,true);
  }
 catch (  OWLOntologyCreationException e) {
    e.printStackTrace();
  }
catch (  OWLOntologyChangeException e) {
    e.printStackTrace();
  }
  oPlus=new OPlus(manager.getOWLDataFactory());
  pelletExplanation=new PelletExplanationGenerator(manager,ontologies);
  lastRegularExplanations=new HashSet<Explanation>();
}

Fixed version (ground truth):
public LaconicExplanationGenerator(OWLOntologyManager manager){
  this.manager=manager;
  oPlus=new OPlus(manager.getOWLDataFactory());
  lastRegularExplanations=new HashSet<Explanation>();
}
Program: 9775
Project: 9775
Buggy source:
@Override public void setValueAt(Object value,int rowIndex,int columnIndex){
  if (columnIndex == 4) {
    OWLAxiom ax=getOWLAxiomAtRow(rowIndex);
    if (impMan.isSelected(ax)) {
      impMan.removeSelection(ax);
      if (!ont.containsAxiom(ax)) {
        List<OWLOntologyChange> changes=new ArrayList<OWLOntologyChange>();
        for (        OWLAxiom source : expMan.getSourceAxioms(ax)) {
          impMan.removeSelection(source);
          changes.add(new RemoveAxiom(ont,source));
          for (          OWLAxiom remain : expMan.getRemainingAxioms(source,ax)) {
            changes.add(new AddAxiom(ont,remain));
          }
        }
        repMan.removeFromRepairPlan(changes);
      }
 else {
        repMan.removeFromRepairPlan(new RemoveAxiom(ont,ax));
      }
    }
 else {
      if (!OREManager.getInstance().isSourceOWLAxiom(ax)) {
        RemainingAxiomsDialog dialog=new RemainingAxiomsDialog(ax,ont);
        int ret=dialog.showDialog();
        if (ret == RemainingAxiomsDialog.OK_RETURN_CODE) {
          impMan.addSelection(ax);
          List<OWLOntologyChange> changes=dialog.getChanges();
          for (          OWLAxiom source : expMan.getLaconicSourceAxioms(ax)) {
            if (repMan.isScheduled2Add(source)) {
              changes.add(new RemoveAxiom(ont,source));
            }
          }
          repMan.addToRepairPlan(changes);
        }
      }
 else {
        impMan.addSelection(ax);
        repMan.addToRepairPlan(new RemoveAxiom(ont,ax));
      }
    }
  }
  super.setValueAt(value,rowIndex,columnIndex);
}

Fixed version (ground truth):
@Override public void setValueAt(Object value,int rowIndex,int columnIndex){
  if (columnIndex == 4) {
    OWLAxiom ax=getOWLAxiomAtRow(rowIndex);
    if (impMan.isSelected(ax)) {
      impMan.removeSelection(ax);
      if (!ont.containsAxiom(ax)) {
        List<OWLOntologyChange> changes=new ArrayList<OWLOntologyChange>();
        for (        OWLAxiom source : expMan.getSourceAxioms(ax)) {
          impMan.removeSelection(source);
          changes.add(new RemoveAxiom(ont,source));
          for (          OWLAxiom remain : expMan.getRemainingAxioms(source,ax)) {
            changes.add(new AddAxiom(ont,remain));
          }
        }
        repMan.removeFromRepairPlan(changes);
      }
 else {
        repMan.removeFromRepairPlan(new RemoveAxiom(ont,ax));
      }
    }
 else {
      if (!OREManager.getInstance().isSourceOWLAxiom(ax)) {
        RemainingAxiomsDialog dialog=new RemainingAxiomsDialog(ax,ont);
        int ret=dialog.showDialog();
        if (ret == RemainingAxiomsDialog.OK_RETURN_CODE) {
          impMan.addSelection(ax);
          List<OWLOntologyChange> changes=dialog.getChanges();
          for (          OWLAxiom source : expMan.getSourceAxioms(ax)) {
            if (repMan.isScheduled2Add(source)) {
              changes.add(new RemoveAxiom(ont,source));
            }
          }
          repMan.addToRepairPlan(changes);
        }
      }
 else {
        impMan.addSelection(ax);
        repMan.addToRepairPlan(new RemoveAxiom(ont,ax));
      }
    }
  }
  super.setValueAt(value,rowIndex,columnIndex);
}
Program: 9777
Project: 9777
Buggy source:
private void handleKeyPressed(KeyEvent e){
  int selRow=getSelectedRow();
  OWLOntologyChange change=((RepairTableModel)getModel()).getChangeAt(selRow);
  if (e.getKeyCode() == KeyEvent.VK_DELETE) {
    RepairManager.getInstance(OREManager.getInstance()).removeFromRepairPlan(change);
    if (ImpactManager.getInstance(OREManager.getInstance()).isSelected(change.getAxiom())) {
      ImpactManager.getInstance(OREManager.getInstance()).removeSelection(change.getAxiom());
    }
  }
  getSelectionModel().clearSelection();
}

Fixed version (ground truth):
private void handleKeyPressed(KeyEvent e){
  int selRow=getSelectedRow();
  OWLOntologyChange change=((RepairTableModel)getModel()).getChangeAt(selRow);
  if (e.getKeyCode() == KeyEvent.VK_DELETE) {
    handleRemoveChange(change);
  }
  getSelectionModel().clearSelection();
}
Program: 9778
Project: 9778
Buggy source:
public void mouseClicked(MouseEvent e){
  int row=rowAtPoint(e.getPoint());
  int column=columnAtPoint(e.getPoint());
  if (row >= 0 && row <= table.getRowCount() && column == 2) {
    OWLOntologyChange change=((RepairTableModel)getModel()).getChangeAt(row);
    if (ImpactManager.getInstance(OREManager.getInstance()).isSelected(change.getAxiom())) {
      ImpactManager.getInstance(OREManager.getInstance()).removeSelection(change.getAxiom());
    }
    RepairManager.getInstance(OREManager.getInstance()).removeFromRepairPlan(change);
    setCursor(null);
  }
}

Fixed version (ground truth):
public void mouseClicked(MouseEvent e){
  int row=rowAtPoint(e.getPoint());
  int column=columnAtPoint(e.getPoint());
  if (row >= 0 && row <= table.getRowCount() && column == 2) {
    OWLOntologyChange change=((RepairTableModel)getModel()).getChangeAt(row);
    handleRemoveChange(change);
    setCursor(null);
  }
}
Program: 9780
Project: 9780
Buggy source:
private TreeSet<DatatypeProperty> getFirstDatatypeProperties(Set<Set<OWLDataProperty>> setOfSets){
  TreeSet<DatatypeProperty> roles=new TreeSet<DatatypeProperty>(roleComparator);
  for (  Set<OWLDataProperty> innerSet : setOfSets) {
    OWLDataProperty property=innerSet.iterator().next();
    roles.add(new DatatypeProperty(property.getURI().toString()));
  }
  return roles;
}

Fixed version (ground truth):
private TreeSet<DatatypeProperty> getFirstDatatypeProperties(Set<Set<OWLDataProperty>> setOfSets){
  TreeSet<DatatypeProperty> roles=new TreeSet<DatatypeProperty>(roleComparator);
  for (  Set<OWLDataProperty> innerSet : setOfSets) {
    OWLDataProperty property=innerSet.iterator().next();
    roles.add(new DatatypeProperty(property.getURI().toString()));
  }
  roles.remove(new DatatypeProperty("String_Node_Str"));
  roles.remove(new DatatypeProperty("String_Node_Str"));
  return roles;
}
Program: 9781
Project: 9781
Buggy source:
private TreeSet<ObjectProperty> getFirstObjectProperties(Set<Set<OWLObjectProperty>> setOfSets){
  TreeSet<ObjectProperty> roles=new TreeSet<ObjectProperty>(roleComparator);
  for (  Set<OWLObjectProperty> innerSet : setOfSets) {
    OWLObjectProperty property=innerSet.iterator().next();
    roles.add(new ObjectProperty(property.getURI().toString()));
  }
  return roles;
}

Fixed version (ground truth):
private TreeSet<ObjectProperty> getFirstObjectProperties(Set<Set<OWLObjectProperty>> setOfSets){
  TreeSet<ObjectProperty> roles=new TreeSet<ObjectProperty>(roleComparator);
  for (  Set<OWLObjectProperty> innerSet : setOfSets) {
    OWLObjectProperty property=innerSet.iterator().next();
    roles.add(new ObjectProperty(property.getURI().toString()));
  }
  roles.remove(new ObjectProperty("String_Node_Str"));
  roles.remove(new ObjectProperty("String_Node_Str"));
  return roles;
}
Program: 9783
Project: 9783
Buggy source:
@Test public void rhoDownTestPellet(){
  Logger.getRootLogger().setLevel(Level.TRACE);
  ReasonerComponent rs=TestOntologies.getTestOntology(TestOntology.FATHER);
  RhoDRDown rho=new RhoDRDown(rs);
  NamedClass nc=new NamedClass("String_Node_Str");
  Set<Description> refinements=rho.refine(nc,5);
  for (  Description refinement : refinements) {
    System.out.println(refinement);
  }
  assertTrue(refinements.size() == 8);
}

Fixed version (ground truth):
@Test public void rhoDownTestPellet(){
  Logger.getRootLogger().setLevel(Level.TRACE);
  ReasonerComponent rs=TestOntologies.getTestOntology(TestOntology.FATHER);
  RhoDRDown rho=new RhoDRDown(rs);
  NamedClass nc=new NamedClass("String_Node_Str");
  Set<Description> refinements=rho.refine(nc,5);
  for (  Description refinement : refinements) {
    System.out.println(refinement);
  }
  System.out.println(rs.getObjectPropertyHierarchy());
  assertTrue(refinements.size() == 8);
}
Program: 9784
Project: 9784
Buggy source:
public ObjectPropertyHierarchy(Set<ObjectProperty> atomicRoles,TreeMap<ObjectProperty,SortedSet<ObjectProperty>> roleHierarchyUp,TreeMap<ObjectProperty,SortedSet<ObjectProperty>> roleHierarchyDown){
  this.roleHierarchyUp=roleHierarchyUp;
  this.roleHierarchyDown=roleHierarchyDown;
  for (  ObjectProperty role : atomicRoles) {
    if (getMoreGeneralRoles(role).size() == 0)     mostGeneralRoles.add(role);
    if (getMoreSpecialRoles(role).size() == 0)     mostSpecialRoles.add(role);
  }
}

Fixed version (ground truth):
public ObjectPropertyHierarchy(Set<ObjectProperty> atomicRoles,TreeMap<ObjectProperty,SortedSet<ObjectProperty>> roleHierarchyUp,TreeMap<ObjectProperty,SortedSet<ObjectProperty>> roleHierarchyDown){
  this.roleHierarchyUp=roleHierarchyUp;
  this.roleHierarchyDown=roleHierarchyDown;
  for (  ObjectProperty role : atomicRoles) {
    SortedSet<ObjectProperty> moreGen=getMoreGeneralRoles(role);
    SortedSet<ObjectProperty> moreSpec=getMoreSpecialRoles(role);
    if (moreGen.size() == 0 || (moreGen.size() == 1 && moreGen.first().equals(topRole)))     mostGeneralRoles.add(role);
    if (moreSpec.size() == 0 || (moreSpec.size() == 1 && moreSpec.first().equals(botRole)))     mostSpecialRoles.add(role);
  }
}
Program: 9785
Project: 9785
Buggy source:
@Test public void rhoDownTestPellet(){
  Logger.getRootLogger().setLevel(Level.TRACE);
  ReasonerComponent rs=TestOntologies.getTestOntology(TestOntology.FATHER);
  RhoDRDown rho=new RhoDRDown(rs);
  NamedClass nc=new NamedClass("String_Node_Str");
  Set<Description> refinements=rho.refine(nc,5);
  for (  Description refinement : refinements) {
    System.out.println(refinement);
  }
  System.out.println(rs);
  assertTrue(refinements.size() == 8);
}

Fixed version (ground truth):
@Test public void rhoDownTestPellet(){
  Logger.getRootLogger().setLevel(Level.TRACE);
  ReasonerComponent rs=TestOntologies.getTestOntology(TestOntology.FATHER);
  RhoDRDown rho=new RhoDRDown(rs);
  NamedClass nc=new NamedClass("String_Node_Str");
  Set<Description> refinements=rho.refine(nc,5);
  for (  Description refinement : refinements) {
    System.out.println(refinement);
  }
  assertTrue(refinements.size() == 8);
}
Program: 9787
Project: 9787
Buggy source:
public RecentManager(){
  uriList=new ArrayList<URI>();
  file=new File("String_Node_Str");
}

Fixed version (ground truth):
public RecentManager(){
  uriList=new ArrayList<URI>();
}
Program: 9788
Project: 9788
Buggy source:
public void addResults(List<EvaluatedDescriptionClass> resultList){
  this.resultList.clear();
  this.selectionList.clear();
  this.resultList.addAll(resultList);
  for (int i=0; i < resultList.size(); i++) {
    selectionList.add(i,Boolean.FALSE);
  }
  fireTableRowsUpdated(0,this.resultList.size());
}

Fixed version (ground truth):
public void addResults(List<EvaluatedDescriptionClass> resultList){
  this.resultList.clear();
  this.selectionList.clear();
  this.resultList.addAll(resultList);
  for (int i=0; i < resultList.size(); i++) {
    selectionList.add(i,Boolean.FALSE);
  }
  fireTableDataChanged();
}
Program: 9789
Project: 9789
Buggy source:
/** 
 * Closes the dialog and sets the return code to the integer parameter.
 * @param code The return code.
 */
public void close(int code){
  returnCode=code;
  System.out.println("String_Node_Str");
  wizardDialog.dispose();
  System.exit(0);
}

Fixed version (ground truth):
/** 
 * Closes the dialog and sets the return code to the integer parameter.
 * @param code The return code.
 */
public void close(int code){
  RecentManager.getInstance().save();
  returnCode=code;
  System.out.println("String_Node_Str");
  wizardDialog.dispose();
  System.exit(0);
}
Program: 9791
Project: 9791
Buggy source:
@Override public void run(){
  fillClassesList(1);
  TaskManager.getInstance().setTaskFinished();
}

Fixed version (ground truth):
@Override public void run(){
  fillClassesList(3);
  TaskManager.getInstance().setTaskFinished();
}
Program: 9792
Project: 9792
Buggy source:
@Override public void done(){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      fillClassesList(1);
      TaskManager.getInstance().setTaskFinished();
    }
  }
);
}

Fixed version (ground truth):
@Override public void done(){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      fillClassesList(3);
      TaskManager.getInstance().setTaskFinished();
    }
  }
);
}
Program: 9793
Project: 9793
Buggy source:
@Override public Void doInBackground(){
  getWizard().setNextFinishButtonEnabled(false);
  try {
    oreMan.initPelletReasoner();
    RecentManager.getInstance().addURI(currentURI);
    RecentManager.getInstance().serialize();
    if (oreMan.consistentOntology()) {
      oreMan.getReasoner().classify();
      oreMan.getReasoner().realise();
    }
  }
 catch (  URISyntaxException e) {
    cancel(true);
    getWizard().getDialog().setCursor(null);
    JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    return null;
  }
catch (  OWLOntologyCreationException e) {
    cancel(true);
    getWizard().getDialog().setCursor(null);
    if (e.getClass().equals(UnparsableOntologyException.class)) {
      JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    }
 else {
      JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str" + "String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    }
  }
  return null;
}

Fixed version (ground truth):
@Override public Void doInBackground(){
  getWizard().setNextFinishButtonEnabled(false);
  try {
    oreMan.initPelletReasoner();
    RecentManager.getInstance().add(currentURI);
    if (oreMan.consistentOntology()) {
      oreMan.getReasoner().classify();
      oreMan.getReasoner().realise();
    }
  }
 catch (  URISyntaxException e) {
    cancel(true);
    getWizard().getDialog().setCursor(null);
    TaskManager.getInstance().setTaskFinished();
    JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    return null;
  }
catch (  OWLOntologyCreationException e) {
    cancel(true);
    getWizard().getDialog().setCursor(null);
    TaskManager.getInstance().setTaskFinished();
    if (e.getClass().equals(UnparsableOntologyException.class)) {
      JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    }
 else {
      JOptionPane.showMessageDialog(getWizard().getDialog(),"String_Node_Str" + "String_Node_Str","String_Node_Str",JOptionPane.ERROR_MESSAGE);
    }
  }
  return null;
}
Program: 9794
Project: 9794
Buggy source:
public void setSelectedClass(int rowIndex){
  classesTable.setSelectedClass(rowIndex);
}

Fixed version (ground truth):
public void setSelectedClass(int rowIndex){
  classesTable.setSelectedClass(rowIndex);
  String renderedClassName=OREManager.getInstance().getManchesterSyntaxRendering(classesTable.getSelectedClass(rowIndex));
  superPanel.setTitle(SUPERCLASS_PANEL_TITLE + renderedClassName);
  equivalentPanel.setTitle(EQUIVALENTCLASS_PANEL_TITLE + renderedClassName);
}
Program: 9795
Project: 9795
Buggy source:
private JComponent createSuperPanel(){
  GridBagConstraints c=new GridBagConstraints();
  superPanel=new JPanel();
  superPanel.setLayout(new GridBagLayout());
  c.weightx=1.0;
  c.weighty=1.0;
  c.fill=GridBagConstraints.BOTH;
  c.gridx=0;
  c.gridy=0;
  superClassResultsTable=new SelectableClassExpressionsTable();
  superClassResultsTable.setName("String_Node_Str");
  superPanel.add(new JScrollPane(superClassResultsTable),c);
  c.weightx=0.0;
  c.weighty=0.0;
  c.gridx=1;
  c.gridy=0;
  superClassCoveragePanel=new GraphicalCoveragePanel("String_Node_Str");
  superPanel.add(new JScrollPane(superClassCoveragePanel),c);
  superPanel.setBorder(BorderFactory.createTitledBorder("String_Node_Str"));
  c.gridx=0;
  c.gridy=1;
  superInconsistencyLabel=new JLabel("String_Node_Str");
  superPanel.add(superInconsistencyLabel,c);
  return superPanel;
}

Fixed version (ground truth):
private JComponent createSuperPanel(){
  GridBagConstraints c=new GridBagConstraints();
  superPanel=new JXTitledPanel(SUPERCLASS_PANEL_TITLE);
  superPanel.getContentContainer().setLayout(new GridBagLayout());
  c.weightx=1.0;
  c.weighty=1.0;
  c.fill=GridBagConstraints.BOTH;
  c.gridx=0;
  c.gridy=0;
  superClassResultsTable=new SelectableClassExpressionsTable();
  superClassResultsTable.setName("String_Node_Str");
  superPanel.getContentContainer().add(new JScrollPane(superClassResultsTable),c);
  c.weightx=0.0;
  c.weighty=0.0;
  c.gridx=1;
  c.gridy=0;
  superClassCoveragePanel=new GraphicalCoveragePanel("String_Node_Str");
  superPanel.getContentContainer().add(new JScrollPane(superClassCoveragePanel),c);
  c.gridx=0;
  c.gridy=1;
  superInconsistencyLabel=new JLabel("String_Node_Str");
  superPanel.getContentContainer().add(superInconsistencyLabel,c);
  return superPanel;
}
Program: 9796
Project: 9796
Buggy source:
private JComponent createClassesPanel(){
  classesTable=new MarkableClassesTable();
  classesTable.setBorder(null);
  JScrollPane classesScroll=new JScrollPane(classesTable);
  classesScroll.setBorder(new MatteBorder(null));
  return classesScroll;
}

Fixed version (ground truth):
private JComponent createClassesPanel(){
  JXTitledPanel classesPanel=new JXTitledPanel("String_Node_Str");
  classesPanel.getContentContainer().setLayout(new BorderLayout());
  classesTable=new MarkableClassesTable();
  classesTable.setBorder(null);
  JScrollPane classesScroll=new JScrollPane(classesTable);
  classesScroll.setBorder(new MatteBorder(null));
  classesPanel.getContentContainer().add(classesScroll);
  return classesPanel;
}
Program: 9797
Project: 9797
Buggy source:
private JComponent createEquivalentPanel(){
  GridBagConstraints c=new GridBagConstraints();
  equivalentPanel=new JPanel();
  equivalentPanel.setLayout(new GridBagLayout());
  c.weightx=1.0;
  c.weighty=1.0;
  c.fill=GridBagConstraints.BOTH;
  c.gridx=0;
  c.gridy=0;
  equivalentClassResultsTable=new SelectableClassExpressionsTable();
  equivalentClassResultsTable.setName("String_Node_Str");
  equivalentPanel.add(new JScrollPane(equivalentClassResultsTable),c);
  c.weightx=0.0;
  c.weighty=0.0;
  c.gridx=1;
  c.gridy=0;
  equivalentClassCoveragePanel=new GraphicalCoveragePanel("String_Node_Str");
  equivalentPanel.add(new JScrollPane(equivalentClassCoveragePanel),c);
  equivalentPanel.setBorder(BorderFactory.createTitledBorder("String_Node_Str"));
  c.gridx=0;
  c.gridy=1;
  equivalentInconsistencyLabel=new JLabel("String_Node_Str");
  equivalentPanel.add(equivalentInconsistencyLabel,c);
  return equivalentPanel;
}

Fixed version (ground truth):
private JComponent createEquivalentPanel(){
  GridBagConstraints c=new GridBagConstraints();
  equivalentPanel=new JXTitledPanel(EQUIVALENTCLASS_PANEL_TITLE);
  equivalentPanel.getContentContainer().setLayout(new GridBagLayout());
  c.weightx=1.0;
  c.weighty=1.0;
  c.fill=GridBagConstraints.BOTH;
  c.gridx=0;
  c.gridy=0;
  equivalentClassResultsTable=new SelectableClassExpressionsTable();
  equivalentClassResultsTable.setName("String_Node_Str");
  equivalentPanel.getContentContainer().add(new JScrollPane(equivalentClassResultsTable),c);
  c.weightx=0.0;
  c.weighty=0.0;
  c.gridx=1;
  c.gridy=0;
  equivalentClassCoveragePanel=new GraphicalCoveragePanel("String_Node_Str");
  equivalentPanel.getContentContainer().add(new JScrollPane(equivalentClassCoveragePanel),c);
  c.gridx=0;
  c.gridy=1;
  equivalentInconsistencyLabel=new JLabel("String_Node_Str");
  equivalentPanel.getContentContainer().add(equivalentInconsistencyLabel,c);
  return equivalentPanel;
}
Program: 9798
Project: 9798
Buggy source:
@Override public String toManchesterSyntaxString(String baseURI,Map<String,String> prefixes){
  return literal;
}

Fixed version (ground truth):
@Override public String toManchesterSyntaxString(String baseURI,Map<String,String> prefixes){
  if (datatype.equals(Datatype.INT) || datatype.equals(Datatype.DOUBLE)) {
    if (Double.valueOf(literal) >= 0) {
      return "String_Node_Str" + literal;
    }
 else {
      return "String_Node_Str" + literal;
    }
  }
 else   if (datatype.equals(Datatype.STRING)) {
    return "String_Node_Str" + literal + "String_Node_Str";
  }
 else {
    return "String_Node_Str" + literal + "String_Node_Str"+ datatype.toManchesterSyntaxString(baseURI,prefixes);
  }
}
Program: 9799
Project: 9799
Buggy source:
@Override public String toManchesterSyntaxString(String baseURI,Map<String,String> prefixes){
  if (hasLang)   return literal + "String_Node_Str" + lang;
 else   return literal;
}

Fixed version (ground truth):
@Override public String toManchesterSyntaxString(String baseURI,Map<String,String> prefixes){
  if (hasLang)   return "String_Node_Str" + literal + "String_Node_Str"+ lang;
 else   return "String_Node_Str" + literal + "String_Node_Str";
}
Program: 9800
Project: 9800
Buggy source:
public void updateRecentList(ActionListener aL){
  recentLinkBox.removeAll();
  openFromRecentLinks.clear();
  LinkLabel link;
  for (  final URI uri : RecentManager.getInstance().getURIs()) {
    link=new LinkLabel(uri.toString());
    link.setName("String_Node_Str");
    openFromRecentLinks.add(link);
    recentLinkBox.add(link);
    link.addLinkListener(aL);
  }
}

Fixed version (ground truth):
public void updateRecentList(ActionListener aL){
  if (recentLinkBox == null) {
    recentLinkBox=new Box(BoxLayout.Y_AXIS);
    recentLinkBox.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createTitledBorder(BorderFactory.createMatteBorder(1,1,1,1,Color.GRAY),"String_Node_Str",0,0,getFont().deriveFont(Font.BOLD),Color.GRAY),BorderFactory.createEmptyBorder(20,20,20,20)));
    box.add(recentLinkBox);
  }
  recentLinkBox.removeAll();
  openFromRecentLinks.clear();
  LinkLabel link;
  for (  final URI uri : RecentManager.getInstance().getURIs()) {
    link=new LinkLabel(uri.toString());
    link.setName("String_Node_Str");
    openFromRecentLinks.add(link);
    recentLinkBox.add(link);
    link.addLinkListener(aL);
  }
}
Program: 9801
Project: 9801
Buggy source:
@Override public Description getCurrentlyBestDescription(){
  return getCurrentlyBestEvaluatedDescription().getDescription();
}

Fixed version (ground truth):
@Override public Description getCurrentlyBestDescription(){
  EvaluatedDescription ed=getCurrentlyBestEvaluatedDescription();
  return ed == null ? null : ed.getDescription();
}