How to register to other IM gateway from Smack client?

Hello guys out there,

I manage to build a small chat client using Smack API … thank you Jive for this…

Currently … everytime I want to list my Yahoo Messenger friends to my Roster list, is by: first I open admin page and register my YM id + password + nick … at gateway-registrations.jsp … I want to be able to register/unregister my self to any available gateway through my Chat client using Smack API …