@Override protected void initFile(String id) throws FormatException, IOException { super.initFile(id); measurementFiles = new ArrayList<String>(); acquisitionDates = new HashMap<Integer, Timestamp>(); if (checkSuffix(id, FLEX_SUFFIX)) { initFlexFile(id); } else if (checkSuffix(id, RES_SUFFIX)) { initResFile(id); } else initMeaFile(id); if (plateCount == flexFiles.size()) { plateCount /= wellCount; if ((plateCount % fieldCount) == 0) { plateCount /= fieldCount; } } }
@Override protected void initFile(String id) throws FormatException, IOException { super.initFile(id); measurementFiles = new ArrayList<String>(); acquisitionDates = new HashMap<Integer, Timestamp>(); if (checkSuffix(id, FLEX_SUFFIX)) { initFlexFile(id); } else if (checkSuffix(id, RES_SUFFIX)) { initResFile(id); } else initMeaFile(id); if (plateCount == flexFiles.size()) { plateCount /= wellCount; if ((plateCount % fieldCount) == 0) { plateCount /= fieldCount; } } }
/** Initialize the dataset from a .res file. */ private void initResFile(String id) throws FormatException, IOException { LOGGER.debug("initResFile({})", id); parseResFile(id); Location thisFile = new Location(id).getAbsoluteFile(); Location parent = thisFile.getParentFile(); LOGGER.debug(" Looking for an .mea file in {}", parent.getAbsolutePath()); String[] list = parent.list(); for (String file : list) { if (checkSuffix(file, MEA_SUFFIX)) { String mea = new Location(parent, file).getAbsolutePath(); LOGGER.debug(" Found .mea file {}", mea); initMeaFile(mea); if (!measurementFiles.contains(thisFile.getAbsolutePath())) { measurementFiles.add(thisFile.getAbsolutePath()); } return; } } throw new FormatException("Could not find an .mea file."); }
/** Initialize the dataset from a .res file. */ private void initResFile(String id) throws FormatException, IOException { LOGGER.debug("initResFile({})", id); parseResFile(id); Location thisFile = new Location(id).getAbsoluteFile(); Location parent = thisFile.getParentFile(); LOGGER.debug(" Looking for an .mea file in {}", parent.getAbsolutePath()); String[] list = parent.list(); for (String file : list) { if (checkSuffix(file, MEA_SUFFIX)) { String mea = new Location(parent, file).getAbsolutePath(); LOGGER.debug(" Found .mea file {}", mea); initMeaFile(mea); if (!measurementFiles.contains(thisFile.getAbsolutePath())) { measurementFiles.add(thisFile.getAbsolutePath()); } return; } } throw new FormatException("Could not find an .mea file."); }