Patches item #3411037, was opened at 2011-09-17 21:21 Message generated for change (Tracker Item Submitted) made by th9 You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=428742&aid=3411037&group_id=40728
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: My Th (th9) Assigned to: Nobody/Anonymous (nobody) Summary: Move plugin loading, load all plugins on first request Initial Comment: Now plugins are loaded only in the constructor of OBConversion and forcefields are not found if OBConversion() hasn't been run. Not all of the plugins are for file format conversion, so it is not appropriate to load all plugins in OBConversion::OBConversion(). In following attachment a sample program which demonstrates the issue. It can also be demonstrated using Python: >>> import openbabel as ob >>> print(ob.OBForceField.FindForceField("UFF")) None >>> This patch moves the plugin loading from OBConversion::OBConversion() to OBPlugin class. Variable "AllPluginsLoaded" keeps track if plugins have been loaded. Function "LoadAllPlugins()" loads all plugins the same way as .OBConversion constructor did. These functions have to check if plugins have been loaded: - OBPlugin::BaseFindType() - OBPlugin::ListAsVector() Comments are welcome. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=428742&aid=3411037&group_id=40728 ------------------------------------------------------------------------------ BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA http://p.sf.net/sfu/rim-devcon-copy2 _______________________________________________ OpenBabel-Devel mailing list OpenBabel-Devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openbabel-devel