Program: 80465
Project: 80465
Buggy source:
@SuppressWarnings("String_Node_Str") private <T>SurrogateContent checkForSurrogates(FillModelContext<T> context,FieldMapping fm,FieldKind fieldKind,CompoundObjectType compoundType){
  SurrogateContent ret=new SurrogateContent();
  DomainState ds=domainAccessHandler.getDomainState();
  if (fieldKind == FieldKind.COLLECTION) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Collection) {
      ret.collection=((iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject).getContent();
    }
    if (ret.collection == null) {
      String classFieldName=fm.getClassFieldName();
      ret.collection=(Collection<Object>)domainAccessHandler.createInstance(MappingUtil.internalDomainAccess.get().getConcreteFieldType(classFieldName).getType());
      ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Collection) {
        ((iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject).setContent(ret.collection);
        ds.getSurrogateState().addOriginal2Surrogate(ret.collection,(iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject);
      }
    }
  }
 else   if (fieldKind == FieldKind.ARRAY) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Array) {
      ret.array=((iot.jcypher.domain.mapping.surrogate.Array)context.parentObject).getListContent();
    }
    if (ret.array == null) {
      String classFieldName=fm.getClassFieldName();
      ret.array=new ObservableList<Object>();
      ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Array) {
        ((iot.jcypher.domain.mapping.surrogate.Array)context.parentObject).setListContent(ret.array);
      }
    }
  }
 else   if (fieldKind == FieldKind.MAP) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Map) {
      ret.map=((iot.jcypher.domain.mapping.surrogate.Map)context.parentObject).getContent();
    }
    if (ret.map == null) {
      String classFieldName=fm.getClassFieldName();
      ret.map=(Map<Object,Object>)domainAccessHandler.createInstance(MappingUtil.internalDomainAccess.get().getConcreteFieldType(classFieldName).getType());
      ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Map) {
        ((iot.jcypher.domain.mapping.surrogate.Map)context.parentObject).setContent(ret.map);
        ds.getSurrogateState().addOriginal2Surrogate(ret.map,(iot.jcypher.domain.mapping.surrogate.Map)context.parentObject);
      }
    }
  }
  return ret;
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private <T>SurrogateContent checkForSurrogates(FillModelContext<T> context,FieldMapping fm,FieldKind fieldKind,CompoundObjectType compoundType){
  SurrogateContent ret=new SurrogateContent();
  DomainState ds=domainAccessHandler.getDomainState();
  if (fieldKind == FieldKind.COLLECTION) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Collection) {
      ret.collection=((iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject).getContent();
    }
    String classFieldName=fm.getClassFieldName();
    ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
    if (ret.collection == null) {
      ret.collection=(Collection<Object>)domainAccessHandler.createInstance(MappingUtil.internalDomainAccess.get().getConcreteFieldType(classFieldName).getType());
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Collection) {
        ((iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject).setContent(ret.collection);
        ds.getSurrogateState().addOriginal2Surrogate(ret.collection,(iot.jcypher.domain.mapping.surrogate.Collection)context.parentObject);
      }
    }
  }
 else   if (fieldKind == FieldKind.ARRAY) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Array) {
      ret.array=((iot.jcypher.domain.mapping.surrogate.Array)context.parentObject).getListContent();
    }
    String classFieldName=fm.getClassFieldName();
    ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
    if (ret.array == null) {
      ret.array=new ObservableList<Object>();
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Array) {
        ((iot.jcypher.domain.mapping.surrogate.Array)context.parentObject).setListContent(ret.array);
      }
    }
  }
 else   if (fieldKind == FieldKind.MAP) {
    if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Map) {
      ret.map=((iot.jcypher.domain.mapping.surrogate.Map)context.parentObject).getContent();
    }
    String classFieldName=fm.getClassFieldName();
    ret.compoundType=MappingUtil.internalDomainAccess.get().getFieldComponentType(classFieldName);
    if (ret.map == null) {
      ret.map=(Map<Object,Object>)domainAccessHandler.createInstance(MappingUtil.internalDomainAccess.get().getConcreteFieldType(classFieldName).getType());
      if (context.parentObject instanceof iot.jcypher.domain.mapping.surrogate.Map) {
        ((iot.jcypher.domain.mapping.surrogate.Map)context.parentObject).setContent(ret.map);
        ds.getSurrogateState().addOriginal2Surrogate(ret.map,(iot.jcypher.domain.mapping.surrogate.Map)context.parentObject);
      }
    }
  }
  return ret;
}