The procedure is called castration, and it involves surgically removing both testicles. This prevents the cat from producing testosterone, which in turn eliminates the possibility of the cat fathering kittens and reduces the likelihood of certain behavioral issues associated with hormones.
It's important to remember that the testicles are not left in place during castration.