Giant resonances of stable and exotic nuclei in relativistic RPA