If your monitor has 2 inputs then you can just choose which source to display with the options on the monitor.
I have a monitor connected to my pc and do the same with my mbp and an hdmi out, although did use a thunderbolt adapter on my old mbp. One dvi in and the other vga in.
I think it might actually auto-select its own input source if only one if them is turned on, but I suspect this might be monitor dependant.
Edit: Ah, completely over looks the keyboard and mouse part.
Regarding the keyboard and mouse you could get a wireless one and switch the dongle, or maybe even a bluetooth set.