Program: 58321
Project: 58321
Buggy source:
/** 
 * Initializes a virtual array with all elements, according to the data filters, as defined in   {@link EDataFilterLevel}.
 */
@Override protected void initFullVA(){
  String sLevel=GeneralManager.get().getPreferenceStore().getString(PreferenceConstants.DATA_FILTER_LEVEL);
  if (sLevel.equals("String_Node_Str")) {
    dataFilterLevel=EDataFilterLevel.COMPLETE;
  }
 else   if (sLevel.equals("String_Node_Str")) {
    dataFilterLevel=EDataFilterLevel.ONLY_MAPPING;
  }
 else   if (sLevel.equals("String_Node_Str")) {
    if (GeneralManager.get().getPathwayManager().size() > 100) {
      dataFilterLevel=EDataFilterLevel.ONLY_CONTEXT;
    }
 else {
      dataFilterLevel=EDataFilterLevel.ONLY_MAPPING;
    }
  }
 else   dataFilterLevel=EDataFilterLevel.COMPLETE;
  ArrayList<Integer> alTempList=new ArrayList<Integer>(set.depth());
  for (int iCount=0; iCount < set.depth(); iCount++) {
    if (dataFilterLevel != EDataFilterLevel.COMPLETE) {
      Integer iDavidID=null;
      Set<Integer> setDavidIDs=GeneralManager.get().getIDMappingManager().getIDAsSet(EIDType.EXPRESSION_INDEX,EIDType.DAVID,iCount);
      if ((setDavidIDs != null && !setDavidIDs.isEmpty())) {
        iDavidID=(Integer)setDavidIDs.toArray()[0];
      }
      if (iDavidID == null) {
        continue;
      }
      if (dataFilterLevel == EDataFilterLevel.ONLY_CONTEXT) {
        PathwayVertexGraphItem tmpPathwayVertexGraphItem=GeneralManager.get().getPathwayItemManager().getPathwayVertexGraphItemByDavidId(iDavidID);
        if (tmpPathwayVertexGraphItem == null) {
          continue;
        }
      }
    }
    alTempList.add(iCount);
  }
  ContentVirtualArray contentVA=new ContentVirtualArray(ContentVAType.CONTENT,alTempList);
  set.setContentVA(ContentVAType.CONTENT,contentVA);
}

Fixed version (ground truth):
/** 
 * Initializes a virtual array with all elements, according to the data filters, as defined in   {@link EDataFilterLevel}.
 */
@Override protected void initFullVA(){
  String sLevel=GeneralManager.get().getPreferenceStore().getString(PreferenceConstants.DATA_FILTER_LEVEL);
  if (sLevel.equals("String_Node_Str")) {
    dataFilterLevel=EDataFilterLevel.COMPLETE;
  }
 else   if (sLevel.equals("String_Node_Str")) {
    dataFilterLevel=EDataFilterLevel.ONLY_MAPPING;
  }
 else   if (sLevel.equals("String_Node_Str")) {
    if (GeneralManager.get().getPathwayManager().size() > 100) {
      dataFilterLevel=EDataFilterLevel.ONLY_CONTEXT;
    }
 else {
      dataFilterLevel=EDataFilterLevel.ONLY_MAPPING;
    }
  }
 else   dataFilterLevel=EDataFilterLevel.COMPLETE;
  ArrayList<Integer> alTempList=new ArrayList<Integer>(set.depth());
  for (int iCount=0; iCount < set.depth(); iCount++) {
    if (dataFilterLevel != EDataFilterLevel.COMPLETE) {
      Integer iDavidID=null;
      Set<Integer> setDavidIDs=GeneralManager.get().getIDMappingManager().getIDAsSet(EIDType.EXPRESSION_INDEX,EIDType.DAVID,iCount);
      if ((setDavidIDs != null && !setDavidIDs.isEmpty())) {
        iDavidID=(Integer)setDavidIDs.toArray()[0];
      }
      if (iDavidID == null) {
        continue;
      }
      if (dataFilterLevel == EDataFilterLevel.ONLY_CONTEXT) {
        PathwayVertexGraphItem tmpPathwayVertexGraphItem=GeneralManager.get().getPathwayItemManager().getPathwayVertexGraphItemByDavidId(iDavidID);
        if (tmpPathwayVertexGraphItem == null) {
          continue;
        }
      }
    }
    alTempList.add(iCount);
  }
}