nus-yam/ex-repair huggingface dataset:
Program: 93361
Project: 93361
Buggy source:
private boolean sameSignature(final IMethodName recMethod,final IMethod jdtMethod) throws JavaModelException {
  if (!(bothConstructors(recMethod,jdtMethod) || sameName(recMethod,jdtMethod))) {
    return false;
  }
  final ITypeName[] recTypes=recMethod.getParameterTypes();
  final String[] jdtTypes=jdtMethod.getParameterTypes();
  if (!sameNumberOfParameters(recMethod,jdtMethod)) {
    return false;
  }
  for (int i=0; i < recTypes.length; i++) {
    final Optional<ITypeName> jdtType=JdtUtils.resolveUnqualifiedJDTType(jdtTypes[i],jdtMethod);
    if (!jdtType.isPresent()) {
      return false;
    }
    if (!sameSimpleTypes(recTypes[i],jdtType.get()) || !sameArrayDimensions(recTypes[i],jdtType.get())) {
      return false;
    }
  }
  return true;
}

Fixed version (ground truth):
private boolean sameSignature(final IMethodName recMethod,final IMethod jdtMethod) throws JavaModelException {
  if (!(bothConstructors(recMethod,jdtMethod) || sameName(recMethod,jdtMethod))) {
    return false;
  }
  final ITypeName[] recTypes=recMethod.getParameterTypes();
  final String[] jdtTypes=jdtMethod.getParameterTypes();
  if (!sameNumberOfParameters(recMethod,jdtMethod)) {
    return false;
  }
  for (int i=0; i < recTypes.length; i++) {
    final Optional<ITypeName> jdtType=JdtUtils.resolveUnqualifiedJDTType(jdtTypes[i],jdtMethod);
    if (!jdtType.isPresent()) {
      return false;
    }
    if (!sameSimpleTypes(recTypes[i],jdtType.get()) || !sameArrayDimensions(recTypes[i],jdtTypes[i])) {
      return false;
    }
  }
  return true;
}
Program: 93362
Project: 93362
Buggy source:
private boolean sameArrayDimensions(final ITypeName t1,final ITypeName t2){
  return t1.getArrayDimensions() == t2.getArrayDimensions();
}

Fixed version (ground truth):
private boolean sameArrayDimensions(final ITypeName t1,final String jdtTypes){
  int dim1=t1.getArrayDimensions();
  int dim2=Signature.getArrayCount(jdtTypes.toCharArray());
  return dim1 == dim2;
}
Program: 93363
Project: 93363
Buggy source:
/** 
 * Returns the   {@link IJavaElement} at the given offset. If no {@link IJavaElement} is selected, the innermostenclosing  {@link IJavaElement} is returned (e.g., the declaring method or type). If both selection resolutionsfail,  {@link Optional#absent()} is returned.
 */
public static Optional<IJavaElement> resolveJavaElementFromTypeRootInEditor(final ITypeRoot root,final int offset){
  ensureIsNotNull(root);
  try {
    final IJavaElement[] elements=root.codeSelect(offset,0);
    if (elements.length > 0) {
      return of(elements[0]);
    }
 else {
      return absent();
    }
  }
 catch (  final JavaModelException e) {
    log(e,"String_Node_Str",root.getHandleIdentifier(),offset);
    return absent();
  }
}

Fixed version (ground truth):
/** 
 * Returns the   {@link IJavaElement} at the given offset. If no {@link IJavaElement} is selected, the innermostenclosing  {@link IJavaElement} is returned (e.g., the declaring method or type). If both selection resolutionsfail,  {@link Optional#absent()} is returned.
 */
public static Optional<IJavaElement> resolveJavaElementFromTypeRootInEditor(final ITypeRoot root,final int offset){
  ensureIsNotNull(root);
  ensureIsGreaterOrEqualTo(offset,0,"String_Node_Str" + offset);
  try {
    final IJavaElement[] elements=root.codeSelect(offset,0);
    if (elements.length > 0) {
      return of(elements[0]);
    }
 else {
      return absent();
    }
  }
 catch (  final JavaModelException e) {
    log(e,"String_Node_Str",root.getHandleIdentifier(),offset);
    return absent();
  }
}
Program: 93364
Project: 93364
Buggy source:
/** 
 * Returns the   {@link IJavaElement} at the given offset. If no {@link IJavaElement} is selected, the innermostenclosing  {@link IJavaElement} is returned (e.g., the declaring method or type). If both selection resolutionsfail,  {@link Optional#absent()} is returned.
 */
public static Optional<IJavaElement> resolveJavaElementFromTypeRootInEditor(final ITypeRoot root,final int offset){
  ensureIsNotNull(root);
  ensureIsGreaterOrEqualTo(offset,0,"String_Node_Str" + offset);
  try {
    final IJavaElement[] elements=root.codeSelect(offset,0);
    if (elements.length > 0) {
      return of(elements[0]);
    }
 else {
      return absent();
    }
  }
 catch (  final JavaModelException e) {
    log(e,"String_Node_Str",root.getHandleIdentifier(),offset);
    return absent();
  }
}

Fixed version (ground truth):
/** 
 * Returns the   {@link IJavaElement} at the given offset. If no {@link IJavaElement} is selected, the innermostenclosing  {@link IJavaElement} is returned (e.g., the declaring method or type). If both selection resolutionsfail,  {@link Optional#absent()} is returned.
 */
public static Optional<IJavaElement> resolveJavaElementFromTypeRootInEditor(final ITypeRoot root,final int offset){
  ensureIsNotNull(root);
  try {
    if (isInvalidSelection(root,offset)) {
      return absent();
    }
    final IJavaElement[] elements=root.codeSelect(offset,0);
    if (elements.length > 0) {
      return of(elements[0]);
    }
 else {
      return absent();
    }
  }
 catch (  final Exception e) {
    if (!isInvalidSelection(root,offset))     log(e,"String_Node_Str",root.getHandleIdentifier(),offset);
    return absent();
  }
}
Program: 93365
Project: 93365
Buggy source:
private static void log(JavaModelException e,String newMessage,Object... args){
  String format=String.format(newMessage,args);
  log.error(format,e);
}

Fixed version (ground truth):
private static void log(Exception e,String newMessage,Object... args){
  String format=String.format(newMessage,args);
  log.error(format,e);
}
Program: 93366
Project: 93366
Buggy source:
public static List<String> findAnonymousClassNames(final CharSequence source){
  String declaringType=findClassName(source);
  int num=1;
  List<String> names=newArrayList();
  Pattern p=Pattern.compile("String_Node_Str",Pattern.DOTALL);
  Matcher matcher=p.matcher(source);
  while (matcher.find()) {
    final String name=matcher.group(1);
    if (!name.equals(declaringType)) {
      names.add(declaringType + "String_Node_Str" + num++);
    }
  }
  return names;
}

Fixed version (ground truth):
public static List<String> findAnonymousClassNames(final CharSequence source){
  String declaringType=findClassName(source);
  int num=1;
  List<String> names=newArrayList();
  Pattern p=Pattern.compile("String_Node_Str",Pattern.DOTALL);
  Matcher matcher=p.matcher(source);
  while (matcher.find()) {
    final String name=matcher.group(1);
    if (!name.equals(declaringType)) {
      System.out.println("String_Node_Str" + matcher.group(0));
      names.add(declaringType + "String_Node_Str" + num++);
    }
  }
  return names;
}
Program: 93367
Project: 93367
Buggy source:
@Test public void extractNamesOfAnonymousClasses(){
  StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  List<String> actuals=JavaProjectFixture.findAnonymousClassNames(sb);
  List<String> expecteds=Lists.newArrayList("String_Node_Str","String_Node_Str");
  assertEquals(expecteds,actuals);
}

Fixed version (ground truth):
@Test public void extractNamesOfAnonymousClasses(){
  StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  sb.append("String_Node_Str");
  List<String> actuals=findAnonymousClassNames(sb);
  List<String> expecteds=Lists.newArrayList("String_Node_Str","String_Node_Str");
  assertEquals(expecteds,actuals);
}
Program: 93368
Project: 93368
Buggy source:
private void addHeader(){
  new Label(container,SWT.None);
  final String message=format("String_Node_Str",directive.getPatterns().length,type.getElementName());
  createLabel(container,message,true);
}

Fixed version (ground truth):
private void addHeader(){
  new Label(container,SWT.None);
  final String message=format("String_Node_Str");
  createLabel(container,message,true);
}
Program: 93369
Project: 93369
Buggy source:
public void setSampleCount(int sampleCount){
  this.sampleCount=sampleCount;
}

Fixed version (ground truth):
public void setSampleCount(final int sampleCount){
  this.sampleCount=sampleCount;
}
Program: 93370
Project: 93370
Buggy source:
@Override public void setNetwork(BayesNet bn){
  super.setNetwork(bn);
  sampler.setBN(bn);
}

Fixed version (ground truth):
@Override public void setNetwork(final BayesNet bn){
  super.setNetwork(bn);
  sampler.setBN(bn);
}
Program: 93371
Project: 93371
Buggy source:
private void normalizeBeliefs(){
  for (int i=0; i < beliefs.length; i++)   beliefs[i]=MathUtils.normalize(beliefs[i]);
}

Fixed version (ground truth):
private void normalizeBeliefs(){
  for (int i=0; i < beliefs.length; i++) {
    beliefs[i]=MathUtils.normalize(beliefs[i]);
  }
}
Program: 93372
Project: 93372
Buggy source:
private double computeEvidenceProbability(Map<BayesNode,String> sample){
  double factor=1.0;
  for (  BayesNode n : net.getNodes()) {
    if (evidence.containsKey(n.getId())) {
      factor*=n.marginalize(sample)[n.getOutcomeIndex(evidence.get(n))];
    }
  }
  return factor;
}

Fixed version (ground truth):
private double computeEvidenceProbability(final Map<BayesNode,String> sample){
  double factor=1.0;
  for (  final BayesNode n : net.getNodes()) {
    final int id=n.getId();
    if (evidence.containsKey(id)) {
      factor*=n.marginalize(sample)[n.getOutcomeIndex(evidence.get(n))];
    }
  }
  return factor;
}
Program: 93373
Project: 93373
Buggy source:
@Override protected void updateBeliefs(){
  sampler.setEvidence(evidence);
  for (int i=0; i < sampleCount; i++) {
    Map<BayesNode,String> sample=sampler.sample();
    double weight=computeEvidenceProbability(sample);
    for (    Entry<Integer,Integer> e : BayesUtils.toIntegerMap(sample).entrySet()) {
      beliefs[e.getKey()][e.getValue()]+=weight;
    }
  }
  normalizeBeliefs();
}

Fixed version (ground truth):
@Override protected void updateBeliefs(){
  sampler.setEvidence(evidence);
  for (int i=0; i < sampleCount; i++) {
    final Map<BayesNode,String> sample=sampler.sample();
    final double weight=computeEvidenceProbability(sample);
    for (    final Entry<Integer,Integer> e : BayesUtils.toIntegerMap(sample).entrySet()) {
      beliefs[e.getKey()][e.getValue()]+=weight;
    }
  }
  normalizeBeliefs();
}
Program: 93374
Project: 93374
Buggy source:
public static LoggingEventManager getManager(){
  if (manager == null) {
    manager=new LoggingEventManager();
  }
  return manager;
}

Fixed version (ground truth):
public static synchronized LoggingEventManager getManager(){
  if (manager == null) {
    manager=new LoggingEventManager();
  }
  return manager;
}
Program: 93375
Project: 93375
Buggy source:
@Override public int compareTo(final IFieldName other){
  identifier.compareTo(other.getIdentifier());
  return 0;
}

Fixed version (ground truth):
@Override public int compareTo(final IFieldName other){
  return identifier.compareTo(other.getIdentifier());
}
Program: 93376
Project: 93376
Buggy source:
@Override public int compareTo(final IVariableName other){
  identifier.compareTo(other.getIdentifier());
  return 0;
}

Fixed version (ground truth):
@Override public int compareTo(final IVariableName other){
  return identifier.compareTo(other.getIdentifier());
}
Program: 93377
Project: 93377
Buggy source:
public List<?> getEvents(){
  return events;
}

Fixed version (ground truth):
public synchronized List<Object> getEvents(){
  return _events;
}
Program: 93378
Project: 93378
Buggy source:
private void add(final Object event){
  events.add(event);
}

Fixed version (ground truth):
private void add(final Object event){
  getEvents().add(event);
}
Program: 93379
Project: 93379
Buggy source:
public void assertNoMoreEvents(){
  assertTrue(events.isEmpty());
}

Fixed version (ground truth):
public void assertNoMoreEvents(){
  assertTrue(getEvents().isEmpty());
}
Program: 93380
Project: 93380
Buggy source:
/** 
 * asserts that the expected event was posted
 */
public void assertEvent(final Object expected){
  assertFalse(events.isEmpty());
  assertTrue("String_Node_Str",events.remove(expected));
}

Fixed version (ground truth):
/** 
 * asserts that the expected event was posted
 */
public void assertEvent(final Object expected){
  assertFalse(getEvents().isEmpty());
  assertTrue("String_Node_Str",getEvents().remove(expected));
}
Program: 93381
Project: 93381
Buggy source:
/** 
 * asserts that the expected event was posted as the next event
 */
public void assertNextEvent(final Object expected){
  assertFalse(events.isEmpty());
  final Object actual=events.remove(0);
  assertEquals(expected,actual);
}

Fixed version (ground truth):
/** 
 * asserts that the expected event was posted as the next event
 */
public void assertNextEvent(final Object expected){
  assertFalse(getEvents().isEmpty());
  final Object actual=getEvents().remove(0);
  assertEquals(expected,actual);
}
Program: 93382
Project: 93382
Buggy source:
private void waitForFinish(){
  try {
    Thread.sleep(TIME_OF_SLOW_PROVIDERS + 100);
  }
 catch (  final InterruptedException e) {
    Throws.throwUnhandledException(e);
  }
}

Fixed version (ground truth):
private void waitForFinish(){
  try {
    Thread.sleep(TIME_OF_SLOW_PROVIDERS + 200);
  }
 catch (  final InterruptedException e) {
    Throws.throwUnhandledException(e);
  }
}
Program: 93383
Project: 93383
Buggy source:
@Override public void setFocus(){
}

Fixed version (ground truth):
@Override public void setFocus(){
  contentPart.setFocus();
}
Program: 93384
Project: 93384
Buggy source:
private boolean findReceiver(){
  receiverName=ctx.getReceiverName();
  receiverType=ctx.getReceiverType().orNull();
  if ((receiverType == null) && receiverName.isEmpty()) {
    setReceiverToSupertype();
  }
  return receiverType != null;
}

Fixed version (ground truth):
private boolean findReceiver(){
  receiverName=ctx.getReceiverName();
  receiverType=ctx.getReceiverType().orNull();
  if (isReceiverNameThis() || isReceiverNameSuper() || isImplicitThis()) {
    setReceiverToSupertype();
  }
  return receiverType != null;
}
Program: 93385
Project: 93385
Buggy source:
private void createProspsals(){
  final String prefix=ctx.getPrefix();
  for (  final CallsRecommendation r : recommendations) {
    if (!r.method.getName().startsWith(prefix)) {
      continue;
    }
    final IMethod method=jdtResolver.toJdtMethod(r.method);
    if (method == null) {
      continue;
    }
    final int start=ctx.getInvocationOffset() - ctx.getPrefix().length();
    final int end=ctx.getInvocationOffset();
    final CompletionProposal proposal=JdtUtils.createProposal(method,CompletionProposal.METHOD_REF,start,end,end);
    final int proposalPercentage=(int)Math.rint(r.probability * 100);
    final int rating=BASIS_RELEVANCE + proposalPercentage;
    proposal.setRelevance(rating);
    final ParameterGuessingProposal javaProposal=ParameterGuessingProposal.createProposal(proposal,ctx.getJavaContext(),true);
    final CompletionProposalDecorator decorator=new CompletionProposalDecorator(javaProposal,r.probability);
    proposals.add(decorator);
  }
}

Fixed version (ground truth):
private void createProspsals(){
  final String prefix=ctx.getPrefix();
  for (  final CallsRecommendation r : recommendations) {
    final String proposalPrefix=StringUtils.substring(r.method.getName(),0,prefix.length());
    if (!proposalPrefix.equalsIgnoreCase(prefix)) {
      continue;
    }
    final IMethod method=jdtResolver.toJdtMethod(r.method);
    if (method == null) {
      continue;
    }
    final int start=ctx.getInvocationOffset() - ctx.getPrefix().length();
    final int end=ctx.getInvocationOffset();
    final CompletionProposal proposal=JdtUtils.createProposal(method,CompletionProposal.METHOD_REF,start,end,end);
    final int proposalPercentage=(int)Math.rint(r.probability * 100);
    final int rating=BASIS_RELEVANCE + proposalPercentage;
    proposal.setRelevance(rating);
    final ParameterGuessingProposal javaProposal=ParameterGuessingProposal.createProposal(proposal,ctx.getJavaContext(),true);
    final CompletionProposalDecorator decorator=new CompletionProposalDecorator(javaProposal,r.probability);
    proposals.add(decorator);
  }
}
Program: 93386
Project: 93386
Buggy source:
public static Optional<IType> createUnresolvedType(final TypeBinding compilerBinding){
  final IType t=(IType)Util.getUnresolvedJavaElement(compilerBinding,null,EMPTY_NODE_MAP);
  return fromNullable(t);
}

Fixed version (ground truth):
public static Optional<IType> createUnresolvedType(final TypeBinding compilerBinding){
  final JavaElement e=Util.getUnresolvedJavaElement(compilerBinding,null,EMPTY_NODE_MAP);
  if (e instanceof IType) {
    return of((IType)e);
  }
 else   if (e instanceof ITypeParameter) {
    final ITypeParameter t=cast(e);
  }
  return absent();
}
Program: 93387
Project: 93387
Buggy source:
/** 
 * @param parent must be an  {@link IType} or something that has an{@link IType} as parent.
 */
public static Optional<String> resolveUnqualifiedTypeNamesAndStripOffGenericsAndArrayDimension(String typeSignature,final IJavaElement parent){
  ensureIsNotNull(typeSignature);
  ensureIsNotNull(parent);
  try {
    typeSignature=typeSignature.replace('/','.');
    final IType type=(IType)(parent instanceof IType ? parent : parent.getAncestor(IJavaElement.TYPE));
    if (type == null) {
      throwIllegalArgumentException("String_Node_Str",parent);
    }
    String resolvedTypeSignature=JavaModelUtil.getResolvedTypeName(typeSignature,type);
    if (resolvedTypeSignature == null) {
      return of("String_Node_Str");
    }
    resolvedTypeSignature=StringUtils.substringBeforeLast(resolvedTypeSignature,"String_Node_Str");
    return fromNullable(resolvedTypeSignature);
  }
 catch (  final Exception e) {
    log(e);
    return absent();
  }
}

Fixed version (ground truth):
/** 
 * @param parent must be an  {@link IType} or something that has an {@link IType} as parent.
 */
public static Optional<String> resolveUnqualifiedTypeNamesAndStripOffGenericsAndArrayDimension(String typeSignature,final IJavaElement parent){
  ensureIsNotNull(typeSignature);
  ensureIsNotNull(parent);
  try {
    typeSignature=typeSignature.replace('/','.');
    final IType type=(IType)(parent instanceof IType ? parent : parent.getAncestor(IJavaElement.TYPE));
    if (type == null) {
      throwIllegalArgumentException("String_Node_Str",parent);
    }
    String resolvedTypeSignature=JavaModelUtil.getResolvedTypeName(typeSignature,type);
    if (resolvedTypeSignature == null) {
      return of("String_Node_Str");
    }
    resolvedTypeSignature=StringUtils.substringBeforeLast(resolvedTypeSignature,"String_Node_Str");
    return fromNullable(resolvedTypeSignature);
  }
 catch (  final Exception e) {
    log(e);
    return absent();
  }
}
Program: 93388
Project: 93388
Buggy source:
private void updateSelectionStatus(final JavaSelectionEvent selection){
  final IJavaElement element=selection.getElement();
  String text=JavaElementLinks.getElementLabel(element,LABEL_FLAGS);
  text=stripHtml(text);
  selectionStatus.setText(text);
  selectionStatus.setImage(labelProvider.getImage(element));
}

Fixed version (ground truth):
private void updateSelectionStatus(final JavaSelectionEvent selection){
  final IJavaElement element=selection.getElement();
  final String text=JavaElementLabels.getElementLabel(element,LABEL_FLAGS);
  selectionStatus.setText(text);
  selectionStatus.setImage(labelProvider.getImage(element));
}
Program: 93389
Project: 93389
Buggy source:
private void resizeScrolledComposite(){
  final int newWidth=scrolledContent.getSize().x;
  Point newSize=scrolledContent.computeSize(newWidth,SWT.DEFAULT);
  scrollingComposite.setMinHeight(newSize.y);
}

Fixed version (ground truth):
private void resizeScrolledComposite(){
  final int newWidth=scrolledContent.getSize().x;
  final Point newSize=scrolledContent.computeSize(newWidth,SWT.DEFAULT);
  scrollingComposite.setMinHeight(newSize.y);
}
Program: 93390
Project: 93390
Buggy source:
private void appendTemplateVariable(final String varname,final String varType){
  varNames.add(varname);
  sb.append("String_Node_Str").append(varname);
  final int count=varNames.count(varname);
  if (count > 1) {
    sb.append(count);
  }
  final String resolvedTypeName=JdtUtils.resolveUnqualifiedTypeNamesAndStripOffGenericsAndArrayDimension(varType,context.getCompilationUnit());
  sb.append("String_Node_Str");
}

Fixed version (ground truth):
private void appendTemplateVariable(final String varname,final String varType){
  varNames.add(varname);
  sb.append("String_Node_Str").append(varname);
  final int count=varNames.count(varname);
  if (count > 1) {
    sb.append(count);
  }
  final String resolvedTypeName=JdtUtils.resolveUnqualifiedTypeNamesAndStripOffGenericsAndArrayDimension(varType,context.getCompilationUnit().findPrimaryType());
  sb.append("String_Node_Str");
}
Program: 93391
Project: 93391
Buggy source:
@Test public void testSimpleCase(){
  setupNameCollectors(Names__Field_To_Temp_Local.class);
  verifyLocalNames("String_Node_Str","String_Node_Str");
}

Fixed version (ground truth):
@Test public void testSimpleCase() throws InvalidClassFileException {
  setupNameCollectors(Names__Field_To_Temp_Local.class);
  verifyLocalNames("String_Node_Str","String_Node_Str");
}
Program: 93392
Project: 93392
Buggy source:
private void setupNameCollectors(final Class<?> testCase){
  method=WalaTestUtils.lookupTestMethod(cha,testCase);
  ir=cache.getIR(method);
  sut=new LocalNamesCollectorNaiveEdition(ir);
}

Fixed version (ground truth):
private void setupNameCollectors(final Class<?> testCase) throws InvalidClassFileException {
  method=WalaTestUtils.lookupTestMethod(cha,testCase);
  ir=cache.getIR(method);
  sut=new LocalNamesCollectorNaiveEdition(ir);
}
Program: 93393
Project: 93393
Buggy source:
private void putDocument(final WebServiceClient c,final File couchdbBasedir,final File contentFile) throws IOException {
  String path=removeStart(contentFile.getAbsolutePath(),couchdbBasedir.getAbsolutePath() + "String_Node_Str");
  path=StringUtils.removeEnd(path,"String_Node_Str");
  try {
    final String content=Files.toString(contentFile,Charsets.UTF_8);
    c.createRequestBuilder(path).type(MediaType.TEXT_PLAIN_TYPE).put(content);
  }
 catch (  final Exception e) {
    System.out.printf("String_Node_Str",contentFile,e.getMessage());
  }
}

Fixed version (ground truth):
private void putDocument(final WebServiceClient c,final File couchdbBasedir,final File contentFile) throws IOException {
  String path=removeStart(contentFile.getAbsolutePath(),couchdbBasedir.getAbsolutePath());
  path=path.replace("String_Node_Str","String_Node_Str");
  path=StringUtils.removeStart(path,"String_Node_Str");
  path=StringUtils.removeEnd(path,"String_Node_Str");
  try {
    final String content=Files.toString(contentFile,Charsets.UTF_8);
    c.createRequestBuilder(path).type(MediaType.TEXT_PLAIN_TYPE).put(content);
  }
 catch (  final Exception e) {
    System.out.printf("String_Node_Str",contentFile,e.getMessage());
  }
}
Program: 93395
Project: 93395
Buggy source:
public Option<ClassOverrideDirectives> getClassOverrideDirectives(final ITypeName type){
  final Map<String,String> keyValuePairs=Maps.newHashMap();
  final String url=createViewUrlWithKeyObject("String_Node_Str","String_Node_Str",keyValuePairs);
  final GenericResultObjectView<ClassOverrideDirectives> resultView=client.doGetRequest(url,new GenericType<GenericResultObjectView<ClassOverrideDirectives>>(){
  }
);
  return wrap(CouchUtils.getFirst(resultView,null));
}

Fixed version (ground truth):
private Option<ClassOverrideDirectives> getClassOverrideDirectives(final ITypeName type){
  final Map<String,String> keyValuePairs=Maps.newHashMap();
  keyValuePairs.put("String_Node_Str",ClassOverrideDirectives.class.getSimpleName());
  keyValuePairs.put("String_Node_Str",type.getIdentifier());
  final String url=createViewUrlWithKeyObject("String_Node_Str","String_Node_Str",keyValuePairs);
  final GenericResultObjectView<ClassOverrideDirectives> resultView=client.doGetRequest(url,new GenericType<GenericResultObjectView<ClassOverrideDirectives>>(){
  }
);
  return wrap(CouchUtils.getFirst(resultView,null));
}
Program: 93396
Project: 93396
Buggy source:
@Override public Set<ITypeName> getSuperclasses(){
  return db.getCompilationUnitSuperclases();
}

Fixed version (ground truth):
@Override public Set<ITypeName> getSuperclasses(){
  return db.getSuperclassNames();
}
Program: 93397
Project: 93397
Buggy source:
public boolean isEmpty(){
  return index.isEmpty();
}

Fixed version (ground truth):
@Override public boolean isEmpty(){
  return index.isEmpty();
}
Program: 93398
Project: 93398
Buggy source:
@Override public Set<T> elements(){
  return new TreeSet<T>(index.keySet());
}

Fixed version (ground truth):
@Override public Set<T> elements(){
  return new HashSet<T>(index.keySet());
}
Program: 93399
Project: 93399
Buggy source:
public ClassOverrideDirectives generate(final ITypeName superclass,final Iterable<CompilationUnit> cus){
  this.superclass=superclass;
  this.overriddenMethods=newTreeBag();
  for (  final CompilationUnit cu : cus) {
    numberOfSubclasses++;
    visitOverriddenMethods(cu);
  }
  filterInfrequentMethods();
  final ClassOverrideDirectives res=toDirective();
  return res;
}

Fixed version (ground truth):
public ClassOverrideDirectives generate(final ITypeName superclass,final Iterable<CompilationUnit> cus){
  this.superclass=superclass;
  this.overriddenMethods=newTreeBag();
  numberOfSubclasses=0;
  System.out.println("String_Node_Str" + superclass);
  System.out.println();
  for (  final CompilationUnit cu : cus) {
    numberOfSubclasses++;
    visitOverriddenMethods(cu);
    System.out.println("String_Node_Str" + cu.primaryType.name);
  }
  filterInfrequentMethods();
  final ClassOverrideDirectives res=toDirective();
  return res;
}
Program: 93400
Project: 93400
Buggy source:
/** 
 * @param javaElement The Java element to identify the location for.
 * @param astNode AST node representing the selected java element.
 * @return The code location of the element represented by the AST node.
 */
protected static JavaElementLocation resolveLocation(final IJavaElement javaElement,final ASTNode astNode){
  if (astNode == null) {
    return null;
  }
  final ASTNode locationNode=getLocationNode(astNode);
  return getLocationForNodeType(locationNode,javaElement);
}

Fixed version (ground truth):
/** 
 * @param javaElement The Java element to identify the location for.
 * @param astNode AST node representing the selected java element.
 * @return The code location of the element represented by the AST node.
 */
protected static JavaElementLocation resolveLocation(final IJavaElement javaElement,final ASTNode astNode){
  if (astNode == null) {
    return null;
  }
  final ASTNode locationNode=getLocationNode(astNode);
  return getLocationForNodeType(javaElement,astNode,locationNode);
}
Program: 93401
Project: 93401
Buggy source:
/** 
 * @param locationNodeType The type of the AST node indicating the element's location.
 * @param javaElement The Java element to identify the location for.
 * @return The {@link JavaElementLocation} for the given Java element andits location node type.
 */
private static JavaElementLocation getLocationForNodeType(final ASTNode locationNode,final IJavaElement javaElement){
switch (locationNode.getNodeType()) {
case ASTNode.BLOCK:
case ASTNode.SUPER_CONSTRUCTOR_INVOCATION:
case ASTNode.CAST_EXPRESSION:
    return JavaElementLocation.METHOD_BODY;
case ASTNode.METHOD_DECLARATION:
  return JavaElementLocation.METHOD_DECLARATION;
case ASTNode.SINGLE_VARIABLE_DECLARATION:
return getLocationForSingleVariable(locationNode);
case ASTNode.FIELD_DECLARATION:
return JavaElementLocation.FIELD_DECLARATION;
case ASTNode.TYPE_DECLARATION:
return getTypeDeclarationLocation(javaElement);
case ASTNode.IMPORT_DECLARATION:
return JavaElementLocation.IMPORT_DECLARATION;
case ASTNode.PACKAGE_DECLARATION:
return JavaElementLocation.PACKAGE_DECLARATION;
default :
return JavaElementLocation.METHOD_BODY;
}
}

Fixed version (ground truth):
/** 
 * @param locationNodeType The type of the AST node indicating the element's location.
 * @param javaElement The Java element to identify the location for.
 * @return The {@link JavaElementLocation} for the given Java element andits location node type.
 */
private static JavaElementLocation getLocationForNodeType(final IJavaElement javaElement,final ASTNode astNode,final ASTNode locationNode){
switch (locationNode.getNodeType()) {
case ASTNode.BLOCK:
case ASTNode.SUPER_CONSTRUCTOR_INVOCATION:
case ASTNode.CAST_EXPRESSION:
    return JavaElementLocation.METHOD_BODY;
case ASTNode.METHOD_DECLARATION:
  return JavaElementLocation.METHOD_DECLARATION;
case ASTNode.SINGLE_VARIABLE_DECLARATION:
return getLocationForSingleVariable(locationNode);
case ASTNode.FIELD_DECLARATION:
return JavaElementLocation.FIELD_DECLARATION;
case ASTNode.TYPE_DECLARATION:
return getTypeDeclarationLocation(javaElement,astNode);
case ASTNode.IMPORT_DECLARATION:
return JavaElementLocation.IMPORT_DECLARATION;
case ASTNode.PACKAGE_DECLARATION:
return JavaElementLocation.PACKAGE_DECLARATION;
default :
return JavaElementLocation.METHOD_BODY;
}
}
Program: 93402
Project: 93402
Buggy source:
/** 
 * @param javaElement The Java element occurring in the type declaration.
 * @return The {@link JavaElementLocation} - the "new" type, part of"extends" or part of "implements" - as identified from the Java element type.
 */
private static JavaElementLocation getTypeDeclarationLocation(final IJavaElement javaElement){
  if (!(javaElement instanceof IType)) {
    return JavaElementLocation.TYPE_DECLARATION;
  }
 else {
    try {
      if (!((IType)javaElement).isInterface()) {
        return JavaElementLocation.EXTENDS_DECLARATION;
      }
    }
 catch (    final JavaModelException e) {
      throw new IllegalStateException(e);
    }
  }
  return JavaElementLocation.IMPLEMENTS_DECLARATION;
}

Fixed version (ground truth):
/** 
 * @param javaElement The Java element occurring in the type declaration.
 * @return The {@link JavaElementLocation} - the "new" type, part of"extends" or part of "implements" - as identified from the Java element type.
 */
private static JavaElementLocation getTypeDeclarationLocation(final IJavaElement javaElement,final ASTNode astNode){
  if (!(javaElement instanceof IType)) {
    return JavaElementLocation.TYPE_DECLARATION;
  }
  try {
    if (((IType)javaElement).isInterface()) {
      return JavaElementLocation.IMPLEMENTS_DECLARATION;
    }
  }
 catch (  final JavaModelException e) {
    throw new IllegalStateException(e);
  }
  if (astNode.getNodeType() == ASTNode.TYPE_DECLARATION || astNode.getParent().getNodeType() == ASTNode.TYPE_DECLARATION && !(javaElement instanceof IPackageFragment)) {
    return JavaElementLocation.TYPE_DECLARATION;
  }
  return JavaElementLocation.EXTENDS_DECLARATION;
}
Program: 93403
Project: 93403
Buggy source:
@Override public ASTNode getAstNode(){
  if (cachedAstNode == null && getCompilationUnit() != null) {
    cachedAstNode=AstNodeResolver.resolveNode(getCompilationUnit(),invocationOffset);
  }
  return cachedAstNode;
}

Fixed version (ground truth):
@Override public ASTNode getAstNode(){
  if (cachedAstNode == null && getCompilationUnit() != null) {
    final ASTParser parser=ASTParser.newParser(AST.JLS3);
    parser.setResolveBindings(true);
    parser.setSource(Preconditions.checkNotNull(compilationUnit));
    final ASTNode astRoot=parser.createAST(null);
    cachedAstNode=NodeFinder.perform(astRoot,invocationOffset,0);
  }
  return cachedAstNode;
}
Program: 93404
Project: 93404
Buggy source:
private ProviderUiJob displayContentForType(final ITypeName type){
  return displayCodeSnippets(type,server.getTypeCodeExamples(type));
}

Fixed version (ground truth):
private ProviderUiJob displayContentForType(final ITypeName type){
  if (type == null) {
    return null;
  }
  return displayCodeSnippets(type,server.getTypeCodeExamples(type));
}
Program: 93405
Project: 93405
Buggy source:
private static ITypeName resolveTypeSignature(final IType declaringType,final String typeSignature) throws JavaModelException {
  final String resolvedTypeName=JavaModelUtil.getResolvedTypeName(typeSignature,declaringType);
  if (PrimitiveType.fromSrc(resolvedTypeName) != null) {
    return resolvePrimitive(resolvedTypeName);
  }
  final IJavaProject javaProject=declaringType.getJavaProject();
  return ElementResolver.toRecType(javaProject.findType(resolvedTypeName));
}

Fixed version (ground truth):
private static ITypeName resolveTypeSignature(final IType declaringType,final String typeSignature) throws JavaModelException {
  final String resolvedTypeName=JavaModelUtil.getResolvedTypeName(typeSignature,declaringType);
  if (resolvedTypeName == null) {
    return null;
  }
  if (PrimitiveType.fromSrc(resolvedTypeName) != null) {
    return resolvePrimitive(resolvedTypeName);
  }
  final IJavaProject javaProject=declaringType.getJavaProject();
  return ElementResolver.toRecType(javaProject.findType(resolvedTypeName));
}
Program: 93406
Project: 93406
Buggy source:
protected ProviderUiJob updateImplementsDeclarationSelection(final IJavaElementSelection selection,final ILocalVariable local){
  return null;
}

Fixed version (ground truth):
protected ProviderUiJob updateImplementsDeclarationSelection(final IJavaElementSelection selection,final IType type){
  return null;
}
Program: 93407
Project: 93407
Buggy source:
protected ProviderUiJob updateTypeDeclarationSelection(final IJavaElementSelection selection,final ILocalVariable local){
  return null;
}

Fixed version (ground truth):
protected ProviderUiJob updateTypeDeclarationSelection(final IJavaElementSelection selection,final IType type){
  return null;
}
Program: 93408
Project: 93408
Buggy source:
@Override public void elementChanged(final ElementChangedEvent event){
  final IJavaProject javaProject=event.getDelta().getElement().getJavaProject();
  if (javaProject == null || !RecommendersNature.hasNature(javaProject.getProject())) {
    return;
  }
switch (event.getDelta().getKind()) {
case IJavaElementDelta.F_OPENED:
    fireOpenEvent(event.getDelta().getElement().getJavaProject());
  break;
case IJavaElementDelta.F_CLOSED:
fireCloseEvent(event.getDelta().getElement().getJavaProject());
break;
}
}

Fixed version (ground truth):
@Override public void elementChanged(final ElementChangedEvent event){
  final IJavaElementDelta delta=event.getDelta();
  process(delta);
}
Program: 93409
Project: 93409
Buggy source:
@Override public File getJarFile(){
  final IPath fullPath=b.getPath();
  final File file=fullPath.toFile();
  return file;
}

Fixed version (ground truth):
@Override public File getJarFile(){
  File res=null;
  final IResource resource=b.getResource();
  if (resource != null) {
    IPath location=resource.getLocation();
    res=location.toFile();
  }
 else {
    final IPath path=b.getPath();
    res=path.toFile();
  }
  return res;
}
Program: 93410
Project: 93410
Buggy source:
private void simulateProjectOpenEvents(){
  for (  final IProject project : getAllOpenProjects()) {
    if (RecommendersNature.hasNature(project)) {
      final IJavaProject javaProject=toJavaProject(project);
      fireOpenEvent(javaProject);
    }
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private void simulateProjectOpenEvents(){
  for (  final IProject project : getAllOpenProjects()) {
    if (RecommendersNature.hasNature(project) && JavaProject.hasJavaNature(project)) {
      final IJavaProject javaProject=toJavaProject(project);
      fireOpenEvent(javaProject);
    }
  }
}
Program: 93411
Project: 93411
Buggy source:
private File getLocation(final IPackageFragmentRoot packageRoot){
  final IResource resource=packageRoot.getResource();
  if (resource != null) {
    return resource.getLocation().toFile().getAbsoluteFile();
  }
  if (packageRoot.isExternal()) {
    return packageRoot.getPath().toFile().getAbsoluteFile();
  }
  throw Throws.throwIllegalArgumentException("String_Node_Str" + packageRoot);
}

Fixed version (ground truth):
private File getLocation(final IPackageFragmentRoot packageRoot){
  final IResource resource=packageRoot.getResource();
  if (resource != null) {
    if (resource.getLocation() == null) {
      return resource.getRawLocation().toFile().getAbsoluteFile();
    }
 else {
      return resource.getLocation().toFile().getAbsoluteFile();
    }
  }
  if (packageRoot.isExternal()) {
    return packageRoot.getPath().toFile().getAbsoluteFile();
  }
  throw Throws.throwIllegalArgumentException("String_Node_Str" + packageRoot);
}
Program: 93412
Project: 93412
Buggy source:
private void displayProposal(final Tuple<IMethodName,Double> proposal,final TableListing table,final IJavaElement element,final boolean isMethodDeclaration){
  table.startNewRow();
  table.addLabelItem(formatMethodCall(element,proposal.getFirst(),isMethodDeclaration),false,true,SWT.COLOR_BLACK);
  table.addLabelItem(Math.round(proposal.getSecond() * 100) + "String_Node_Str",false,false,SWT.COLOR_BLUE);
}

Fixed version (ground truth):
private void displayProposal(final Tuple<IMethodName,Double> proposal,final TableListing table,final IJavaElement element,final boolean isMethodDeclaration){
  table.startNewRow();
  table.addCell(formatMethodCall(element,proposal.getFirst(),isMethodDeclaration),false,true,SWT.COLOR_BLACK);
  table.addCell(Math.round(proposal.getSecond() * 100) + "String_Node_Str",false,false,SWT.COLOR_BLUE);
}
Program: 93413
Project: 93413
Buggy source:
@Override public void run(final Composite composite){
  disposeChildren(composite);
  final TextAndFeaturesLine line=new TextAndFeaturesLine(composite,text,features);
  line.createStyleRange(12 + action.length(),elementName.length(),SWT.NORMAL,false,true);
  displayProposals(element,isMethodDeclaration,proposals,calledMethods,composite);
  if (maxProbabilitiesFromMethods != null) {
    new TextAndFeaturesLine(composite,text2,features);
    final TableListing calls=new TableListing(composite,4);
    for (    final Tuple<IMethodName,Tuple<IMethodName,Double>> proposal : maxProbabilitiesFromMethods) {
      calls.startNewRow();
      calls.addLabelItem(formatMethodCall(element,proposal.getFirst(),isMethodDeclaration),false,true,SWT.COLOR_BLACK);
      final int probability=(int)Math.round(proposal.getSecond().getSecond() * 100);
      final String origin=Names.vm2srcSimpleMethod(proposal.getSecond().getFirst());
      calls.addLabelItem(probability + "String_Node_Str",false,false,SWT.COLOR_BLUE);
      final StyledText styled=SwtFactory.createStyledText(calls,"String_Node_Str" + origin,SWT.COLOR_BLACK,true);
      SwtFactory.createStyleRange(styled,3,origin.length(),SWT.NORMAL,false,true);
    }
  }
}

Fixed version (ground truth):
@Override public void run(final Composite composite){
  disposeChildren(composite);
  final TextAndFeaturesLine line=new TextAndFeaturesLine(composite,text,features);
  line.createStyleRange(12 + action.length(),elementName.length(),SWT.NORMAL,false,true);
  displayProposals(element,isMethodDeclaration,proposals,calledMethods,composite);
  if (maxProbabilitiesFromMethods != null) {
    new TextAndFeaturesLine(composite,text2,features);
    final TableListing calls=new TableListing(composite,4);
    for (    final Tuple<IMethodName,Tuple<IMethodName,Double>> proposal : maxProbabilitiesFromMethods) {
      calls.startNewRow();
      calls.addCell(formatMethodCall(element,proposal.getFirst(),isMethodDeclaration),false,true,SWT.COLOR_BLACK);
      final String origin=Names.vm2srcSimpleMethod(proposal.getSecond().getFirst());
      final int probability=(int)Math.round(proposal.getSecond().getSecond() * 100);
      calls.addCell(probability + "String_Node_Str",false,false,SWT.COLOR_BLUE);
      final StyledText styled=SwtFactory.createStyledText(calls,"String_Node_Str" + origin,SWT.COLOR_BLACK,true);
      SwtFactory.createStyleRange(styled,3,origin.length(),SWT.NORMAL,false,true);
    }
  }
}
Program: 93414
Project: 93414
Buggy source:
private void displayProposals(final IJavaElement element,final boolean isMethodDeclaration,final SortedSet<Tuple<IMethodName,Double>> proposals,final Set<IMethodName> calledMethods,final Composite composite){
  final TableListing table=new TableListing(composite,3);
  for (  final IMethodName method : calledMethods) {
    table.startNewRow();
    table.addLabelItem(formatMethodCall(element,method,isMethodDeclaration),false,true,SWT.COLOR_DARK_GRAY);
    table.addLabelItem("String_Node_Str",false,false,SWT.COLOR_DARK_GRAY);
  }
  for (  final Tuple<IMethodName,Double> proposal : proposals) {
    displayProposal(proposal,table,element,isMethodDeclaration);
  }
}

Fixed version (ground truth):
private void displayProposals(final IJavaElement element,final boolean isMethodDeclaration,final SortedSet<Tuple<IMethodName,Double>> proposals,final Set<IMethodName> calledMethods,final Composite composite){
  final TableListing table=new TableListing(composite,3);
  for (  final IMethodName method : calledMethods) {
    table.startNewRow();
    table.addCell(formatMethodCall(element,method,isMethodDeclaration),false,true,SWT.COLOR_DARK_GRAY);
    table.addCell("String_Node_Str",false,false,SWT.COLOR_DARK_GRAY);
  }
  for (  final Tuple<IMethodName,Double> proposal : proposals) {
    displayProposal(proposal,table,element,isMethodDeclaration);
  }
}
Program: 93415
Project: 93415
Buggy source:
private void displayAddArea(final IJavaElement element,final Composite composite,final Composite addComposite,final List<SocialBookmark> bookmarks){
  disposeChildren(addComposite);
  final Text title=SwtFactory.createText(addComposite,"String_Node_Str",300);
  final Text url=SwtFactory.createText(addComposite,"String_Node_Str",200);
  SwtFactory.createButton(addComposite,"String_Node_Str",new SelectionAdapter(){
    @Override public void widgetSelected(    final SelectionEvent e){
      addBookmark(title.getText(),url.getText(),element,composite,bookmarks);
    }
  }
);
  SwtFactory.createButton(addComposite,"String_Node_Str",new SelectionAdapter(){
    @Override public void widgetSelected(    final SelectionEvent e){
      disposeChildren(addComposite);
      displayAddControl(element,composite,bookmarks);
      layout(composite);
    }
  }
);
  layout(composite);
}

Fixed version (ground truth):
private void displayAddArea(final IJavaElement element,final Composite composite,final Composite addComposite,final List<SocialBookmark> bookmarks){
  final Text title=SwtFactory.createText(addComposite,"String_Node_Str",300);
  final Text url=SwtFactory.createText(addComposite,"String_Node_Str",200);
  SwtFactory.createButton(addComposite,"String_Node_Str",new SelectionAdapter(){
    @Override public void widgetSelected(    final SelectionEvent e){
      addBookmark(title.getText(),url.getText(),element,composite,bookmarks);
    }
  }
);
  SwtFactory.createButton(addComposite,"String_Node_Str",new SelectionAdapter(){
    @Override public void widgetSelected(    final SelectionEvent e){
      disposeChildren(addComposite);
      displayAddControl(element,composite,bookmarks);
      layout(composite);
    }
  }
);
  layout(composite);
}
Program: 93416
Project: 93416
Buggy source:
private void displayAddControl(final IJavaElement element,final Composite composite,final List<SocialBookmark> bookmarks){
  final Composite addComposite=SwtFactory.createGridComposite(composite,4,6,0,0,0);
  SwtFactory.createLink(addComposite,"String_Node_Str",null,ExtDocPlugin.getIcon("String_Node_Str"),false,new MouseAdapter(){
    @Override public void mouseUp(    final MouseEvent e){
      displayAddArea(element,composite,addComposite,bookmarks);
    }
  }
);
}

Fixed version (ground truth):
private void displayAddControl(final IJavaElement element,final Composite composite,final List<SocialBookmark> bookmarks){
  final Composite addComposite=SwtFactory.createGridComposite(composite,4,6,0,0,0);
  SwtFactory.createLink(addComposite,"String_Node_Str",null,ExtDocPlugin.getIcon("String_Node_Str"),false,new MouseAdapter(){
    @Override public void mouseUp(    final MouseEvent e){
      disposeChildren(addComposite);
      displayAddArea(element,composite,addComposite,bookmarks);
    }
  }
);
}
Program: 93417
Project: 93417
Buggy source:
@Override public void mouseUp(final MouseEvent e){
  displayAddArea(element,composite,addComposite,bookmarks);
}

Fixed version (ground truth):
@Override public void mouseUp(final MouseEvent e){
  disposeChildren(addComposite);
  displayAddArea(element,composite,addComposite,bookmarks);
}
Program: 93418
Project: 93418
Buggy source:
private static void displayDirectives(final Map<IMethodName,Integer> directives,final String actionKeyword,final int definitions,final Composite composite){
  final TableListing table=new TableListing(composite,4);
  for (  final Entry<IMethodName,Integer> directive : orderDirectives(directives).entrySet()) {
    final int percent=(int)Math.round(directive.getValue().doubleValue() * 100.0 / definitions);
    table.startNewRow();
    table.addLabelItem(getLabel(percent),true,false,SWT.COLOR_BLACK);
    table.addLabelItem(actionKeyword + "String_Node_Str" + Names.vm2srcSimpleMethod(directive.getKey()),false,true,SWT.COLOR_BLACK);
    final StyledText text=SwtFactory.createStyledText(table,"String_Node_Str" + directive.getValue() + "String_Node_Str"+ percent+ "String_Node_Str",SWT.COLOR_BLACK,true);
    SwtFactory.createStyleRange(text,10 + getLength(directive.getValue()),getLength(percent) + 1,SWT.NORMAL,true,false);
  }
}

Fixed version (ground truth):
private static void displayDirectives(final Map<IMethodName,Integer> directives,final String actionKeyword,final int definitions,final Composite composite){
  final TableListing table=new TableListing(composite,4);
  for (  final Entry<IMethodName,Integer> directive : orderDirectives(directives).entrySet()) {
    final int percent=(int)Math.round(directive.getValue().doubleValue() * 100.0 / definitions);
    table.startNewRow();
    table.addCell(getLabel(percent),true,false,SWT.COLOR_BLACK);
    table.addCell(actionKeyword + "String_Node_Str" + Names.vm2srcSimpleMethod(directive.getKey()),false,true,SWT.COLOR_BLACK);
    final StyledText text=SwtFactory.createStyledText(table,"String_Node_Str" + directive.getValue() + "String_Node_Str"+ percent+ "String_Node_Str",SWT.COLOR_BLACK,true);
    SwtFactory.createStyleRange(text,10 + getLength(directive.getValue()),getLength(percent) + 1,SWT.NORMAL,true,false);
  }
}