Skip to content

Commit

Permalink
Fixed coordinates check.
Browse files Browse the repository at this point in the history
  • Loading branch information
javadev committed Sep 2, 2021
1 parent 8bfa372 commit 23087c9
Showing 1 changed file with 20 additions and 20 deletions.
40 changes: 20 additions & 20 deletions src/main/java/maygen/MAYGEN.java
Original file line number Diff line number Diff line change
Expand Up @@ -1676,13 +1676,13 @@ public int[][] forward(
if (writeSDF || printSDF) {
IAtomContainer ac =
buildContainer4SDF(addHydrogens(A, hIndex, hydrogens));
if (coordinates) {
try {
try {
if (coordinates) {
structureDiagramGenerator.generateCoordinates(ac);
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
} else if (writeSMILES) {
write2smiles(addHydrogens(A, hIndex, hydrogens));
Expand Down Expand Up @@ -2121,13 +2121,13 @@ public void writeSingleAtom(int[] hydrogens) throws IOException {
count.incrementAndGet();
if (writeSDF || printSDF) {
IAtomContainer ac = buildContainer4SDF(addHydrogens(A, hIndex, hydrogens));
if (coordinates) {
try {
try {
if (coordinates) {
structureDiagramGenerator.generateCoordinates(ac);
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
} else if (writeSMILES) {
write2smiles(addHydrogens(A, hIndex, hydrogens));
Expand Down Expand Up @@ -3431,13 +3431,13 @@ public void degree2graph() throws IOException {
initAC(symbol);
if (writeSDF || printSDF) {
IAtomContainer ac = buildContainer4SDF(mat);
if (coordinates) {
try {
try {
if (coordinates) {
structureDiagramGenerator.generateCoordinates(ac);
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
} else if (writeSMILES) {
smilesOut.write("Formula is not supported" + "\n");
Expand Down Expand Up @@ -3530,13 +3530,13 @@ else if (nodeLabels[nextSize - 1]
count.incrementAndGet();
if (writeSDF || printSDF) {
IAtomContainer ac = buildContainer4SDF(buildOnSm(build()));
if (coordinates) {
try {
try {
if (coordinates) {
structureDiagramGenerator.generateCoordinates(ac);
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
sdfOut.write(ac);
} catch (CDKException ex) {
throw new UnsupportedOperationException(ex);
}
}
}
Expand Down

0 comments on commit 23087c9

Please sign in to comment.