public Dilution getDilutionByIdAndPlatform(long dilutionId, PlatformType platformType) throws IOException {
if (platformType.equals(PlatformType.ILLUMINA)) {
return getLibraryDilutionById(dilutionId);
}
else if (platformType.equals(PlatformType.LS454) || platformType.equals(PlatformType.SOLID)) {
Dilution a = getEmPCRDilutionById(dilutionId);
Dilution b = getLibraryDilutionById(dilutionId);
if (a != null && a.getLibrary().getPlatformName().equals(platformType.getKey())) {
return a;
}
else if (b != null && b.getLibrary().getPlatformName().equals(platformType.getKey())) {
return b;
}
return null;
}
else {