This mob sorter can sort the usual enemy mobs (spiders, zombies, creepers, skeletons).
The sorter sorts spiders, zombies, creepers and skeletons. Enderman unfortunately can not be transported with water and therefore not sorted.
You can use the sorter for example to build a CD farm, for which you need a skeleton and creeper separately. Otherwise you can also sort out creepers and let them loose on the opponent or similar.
Instructions:Here's a picture from above:
First, sort out the spiders, as they are only one block high and two blocks wide. After that the zombies, as they try to get to the villager to kill him. After that the creepers are afraid of the cat and then only skeletons are left.
On the small picture above you can see relatively well the structure. The entrance is at the top right by the blue wool.
The exit for the spiders is at the bottom right. All other mobs can pass through the passage. In contrast to the screenshot, you should still place steps above the exit of the spiders, so that no other mobs fit through this exit.
Next comes the exit for the zombies down the middle. They try to get to the villager. In order for the zombies to see the villager but not kill him, the villager stays protected behind steps. You absolutely need a ceiling over the water to prevent zombies from jumping onto the steps and you have to get another villager, which is the biggest difficulty with this structure. The two exits on the top are "error channels", as you unfortunately have to hope that no mobs in the water stream move in the wrong direction. The mobs in the error channel just stay there or you flush them back to the beginning.
The last exit is at the bottom left for creepers and at the left for skeletons. The creepers try to get away from the cat. On the top is again an error channel.
Unfortunately, the acquisition of the villager and the cat is not particularly easy. In addition, it can unfortunately always happen that a mob times wrong moves and is flushed to the wrong exit. Most of the time it works fine though.
I got this setup from SanX.