We analyze the transport through a narrow ballistic superconductor-normal-m
etal-superconductor Josephson contact with nonideal transmission at the sup
erconductor-normal-metal interfaces, e.g., due to insulating layers, effect
ive mass steps, or band misfits (SIN interfaces). The electronic spectrum i
n the normal wire is determined through the combination of Andreev reflecti
on and normal reflection at the SIN interfaces. Strong normal scattering at
the SIN interfaces introduces electron- and holelike resonances in the nor
mal region that show up in the quasiparticle spectrum. These resonances hav
e strong implications for the critical supercurrent I-c that we find to be
determined by the lowest quasiparticle level: tuning the potential mu (xo)
to the points where electron- and holelike resonances cross, we find sharp
peaks in I-c, resulting in a transistor effect. We compare the performance
of this resonant Josephson-transistor with that of a superconducting single
electron transistor.