Completed refactoring per issue #5. Separates connector code from importer.