Good design can always find a solution -- off the top of my head, integrating some kind of sterile recyclable mouthpiece dispenser would assuage most concerns
In the case of potable water valves, this is accomplished by preventing backflow and being made out of a hard smooth material. When you turn on a drinking fountain, the stream of water flushes any loose dirt and debris, so as long as you avoid contact with the fountain (the stream should be adjusted so that this is easy), there isn't going to be significant transfer of anything.