A Classification of Trapezoidal Words