Use a map to figure out class of the command