Hi Im using the Smack XMPP library for android.
I have figured out how to connect, login and create a user, but if I try to create an account with a username that already exist, i get a 'conflict' error, then if i change the username and try again, im locked out for about 10 mins, with a "not_acceptable - wait" error.
So how would i check if the username exists before creating an account?
You can use Roster as:
Check if the username exists with :
Collection<RosterEntry> re = roster.getEntries();
And then search for the username in "re".
EDIT : Or simply you can use userSearchManager
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.