No doubt that the teacher was WAY out of line, but I can't help but wonder if the kid has been day-cared to the point that he hasn't been potty trained.
My mother runs a daycare and at a certain point, she will not take untrained kids in her group.