Classes characterized by best-possible approximation by spline functions