This covers the basic types, we've seen some oddball ones over the years that have to be sussed out with a meter, including the Ibanez "OTAX" and import switches with 7 lugs (only one commons). While this is for 3-ways, the lugs are the same on a 5-way, just remember the internal connections at 2 and 4.
Also note that when people (including me) draw diagrams, we often reverse where the commons are!
Moreover, Input and Output are not cast in stone - any one or more pins can be assigned by the designer to achieve a given function. newey will tell you that he's lost count of how many times I've told him to "think outside of the box".