Quantum and Classical Statistical Mechanics of the Integrable Models in 1 + 1 Dimensions