Classes of Terminating Logic Programs