Added an AtomFactoryMethod to allow specifying custom atom type to use. TODO : We need to add test scripts for the new AtomFactoryMethod feature.