Cycles shader multiplexer node?
I found a way to do this that takes a fixed number of inputs (it also has the useful property of mixing its inputs given a non-integer):



This is extensible, but only by manually editing the node group.