The first thing to remember is that the average primary classroom is very small. It offers no scope for the bacchanalian element which a party demands if it is really to be a party and not just an uninspiring way of passing one of the last afternoons of term. If at all possible, the children need to get in the playground and play wild all-out chasing games, preferably with an adult as a bear or policeman for the younger ones and in teams for the older ones. Instead of trying to suppress the party energy, adults can tap into it and enjoy it by playing Chain Tag or Statues.
Another excellent game, and very easy to prepare, is a treasure trail. This can be worked in teams, with either real objects, numbered or alphabetised, to collect or merely sights to be ticked off on a sheet. Should it rain, the same kind of game can be translated inside with the whole class calling out answers (in a way that is not, hopefully, usually allowed).
It is very important that all the games have clear rules which are not bent for anyone, that there are occasions either for all to win or for none, and that none of the games go on for too long. The rules give moral and aesthetic satisfaction; competitiveness, by no means alien to the children normally, is not in place in this kind of celebration, which aims to unite the class in a resounding farewell. With the excitement, no one's attention span is long.
For older children, the old kind of party "turn" in which each one tells a riddle or recites or sings or dances, is perfect, as long as enthusiastic applause is given to all.
The food works much better if it is simple and there is not too much of it. Modern children already graze so much that they are rarely able to tuck into substantial repasts. In any case, the party is likely to be in the afternoon between two meals. It would be better to try and persuade parents to offer their presence instead. For children really appreciate adult interest in their parties. They know - and it does not feel particularly good - if they are being fobbed off with a mountain of pre-packed snacks and a blare of music.
If the party is meant to celebrate their class, then it's really lovely if the teacher can show that she or he values that class enough to make the occasion special for them. Decorating the classroom and making the hats can work if it is part of a whole themed event; it needs the context of valued work to focus such activities. A multi-cultural afternoon with parents contributing food and songs is one such idea; everything in one colour or shape is another; a historical period is a third.
Well, does this all seem too much bother? If it is too much bother, why bother at all? And would it really be more trouble than hanging on grimly for a couple of hours till the parents come while you try to contain all that childish energy within a cramped classroom? Selfishly speaking, is it better to end the year thinking, "I really enjoyed that" or "Thank God it's over". And what would you rather the children felt?