Refactor import parser code to use parent classes