Here we generate two kinds of import wrappers based on whether it is a class or not.