  The Jaynes-Cummings (JC) system, which describes the interaction between a
cavity and a two-level atom, is one of the most important systems in quantum
optics. We obtain analytic solutions for the one- and two-photon transport in a
waveguide side-coupled to the JC system using input-output formalism in Fock
space. With these results, we discuss the conditions under which the JC system
functions as a photon switch for waveguide photons in both the strong and weak
coupling regimes
