No life without Sun
Another way is as suggested by Sun to have a cat in the house so that they will take care of rats.
To answer your question on what to use, rat traps or rat mats or as Srinivasa Rao suggested rat poison.
The use of rat mats is an inhumane way of getting rid of these creatures. Rats get stuck to the glue and die a slow, torturous death. The use of poison does not cause instant death. The animal suffers from organ failure, suffers internal bleeding and dies a painful death.
Mouse traps are the best way to get rid of these animals. Trap the rats and release them outside. It is also advisable to plug all possible openings that the rats may use as an entryway into homes. That should put an end to the rat menace.
Most rodents dwell in unhygienic conditions. Make sure there are no open drains and sewage is not being drained in the open. Garbage bins should be neatly maintained and regularly cleared.
"A love affair with knowledge will never end in heartbreak." -Michael Garrett Marino