Registers the client with the server by automatically creating a user with the help of a pre-defined authentication mechanism.
Synchronous Registration
SMPUserManager* userManager = [SMPUserManager initializeWithConnection:clientConn];
NSError* error = nil;
if([userManager registerUser:"username" password:@"password" error:&error isSyncFlag:YES])
{
// Further processing
} else
{
// Error handling using the error object defined above
}
Asynchronous Registration
SMPUserManager* userManager = [SMPUserManager initializeWithConnection:clientConn];
NSError* error = nil;
[SMPUserManager setDelegate:self]; // The class implementing the listener methods should adhere to <SMPUserManagerDelegate> protocol
[userManager registerUser:"username" password:@"password" error:&error isSyncFlag:NO];