Commits

Anonymous committed 4ed7f9a

added additional convert method to OpenBabelConverter

  • Participants
  • Parent commits 343ebe8

Comments (0)

Files changed (1)

File gigatools-extra/src/main/java/gigatools/extra/openbabel/OpenBabelConverter.java

     }
 
     public static String convert(String cmlMolecule, OBFormat obformat) throws OpenBabelException {
+        return convert(cmlMolecule, obformat, "");
+    }
+
+    public static String convert(String cmlMolecule, OBFormat obformat, String aruguments) throws OpenBabelException {
         if (!executableExists) {
             throw new OpenBabelException("babel command not found on your system. If you have just"
                     + " installed Open Babel, please restart your application or redeploy your web application"
         map.put("input", input);
         map.put("obformat", obformat.getObformat());
         map.put("output", output);
-        CommandLine commandLine = CommandLine.parse("babel -icml ${input} -o${obformat} ${output}", map);
+        map.put("arguments", aruguments);
+        CommandLine commandLine = CommandLine.parse("babel -icml ${input} -o${obformat} ${output} ${arguments}", map);
 
         // initialize input file
         try {