Teacher accused of hitting students with ruler