}
private static Mol2 openAndReadMol2File(String mol2FileName) {
InputStream inputStream = null;
Mol2 mol2 = null;
try {
inputStream = new FileInputStream(mol2FileName);
} catch (FileNotFoundException e) {
System.out.println("Cannot open file" + mol2FileName);
e.printStackTrace();
}
try {
mol2 = new Mol2(inputStream);
} catch (IOException e) {
System.out.println("Cannot parse mol2 file" + mol2FileName);
e.printStackTrace();
}
LOG.debug(mol2.getMolName());
return mol2;
}