Class UsermanAPI

Index Home MAE > MAE Architecture > MAE Data Types > Class Index > Class UsermanAPI

Summary
Public Methods
static bool viewHome(device)
static bool userSettings(device)
static bool systemSettings(device)
static bool updateNews(user_id)
static bool drawFeedback(device, feedbackType, region)
static bool feedbackSubmit(device, cbdata)
static bool feedbackCancel(device)
static bool setCurrentApp(device, appname)
static XMLData newUserRequest(name, email, terms, sessionId, confirmationId)
static XMLData confirmUser(name, email, terms, sessionId, confirmationId)
static XMLData resetPassword(email, ipaddr, requestor)
static bool send(request, params)

#include <UsermanAPI.h >

Summary

This class is used by other apps to send messages to the userman channel.

Use this interface instead of sending messages directly to ensure message keywords are spelled correctly, all parameters are specified, and error checked.

The receiving app defined this interface to ensure it receives the messages correctly.

Public Methods

static bool viewHome(device)

UserDevice& device


END if successfully sent

static bool userSettings(device)

UserDevice& device


END

static bool systemSettings(device)

UserDevice& device


END

static bool updateNews(user_id)

DbRecNum user_id

the User id


Refresh the news feed for the identified user. Call this after you have posted news for that user.

Return value: true if successfully sent

static bool drawFeedback(device, feedbackType, region)

UserDevice& device

the end-user's device

const string& feedbackType

must be one of: bug, feature, comment

const string& region

display region area where feedback dialog box can be displayed


Draw feedback dialog box for the user.

Return value: true if successfully sent

static bool feedbackSubmit(device, cbdata)

const UserDevice& device

end user's device

const XMLData& cbdata

the data associated with the action


Send a feedback form response to Userman, which handles it.

Return value: true if successfully sent

static bool feedbackCancel(device)

const UserDevice& device

end user's device


Send a feedback form response to Userman, which handles it.

Return value: true if successfully sent

static bool setCurrentApp(device, appname)

UserDevice& device

the end-user's device

const string& appname

the name of the new app to run


Switch the user from their currently running MAE application to the new application named.

Return value: true if successfully sent

static XMLData newUserRequest(name, email, terms, sessionId, confirmationId)

const string& name

The name of the user

const string& email

The e-mail address of the user

int terms

the terms version that the user accepted

int sessionId

the user's session id

int confirmationId

(future use) the confirmation id

Default value: 0


Send an email to the identified user, asking them to confirm their e-mail address.

Return value: Resulting data from the call.  Use RemoteService::getError(result) to get any error; if no error, then call worked.

static XMLData confirmUser(name, email, terms, sessionId, confirmationId)

const string& name

The name of the user

const string& email

The e-mail address of the user

int terms

the terms version that the user accepted

int sessionId

the user's session id

int confirmationId

(future use) the confirmation id

Default value: 0


The new user is confirming that they received the e-mail we sent to them.

Return value: Resulting data from the call.  Use RemoteService::getError(result) to get any error; if no error, then call worked.

static XMLData resetPassword(email, ipaddr, requestor)

const string& email

(required) The e-mail address of the user

const string& ipaddr

(optional) The IP address where the user is requesting

const string& requestor

(optional) the name of the user requesting the reset

Default value: ""


User is requesting their password to be reset.

Return value: Resulting data from the call.  Use RemoteService::getError(result) to get any error; if no error, then call worked.

static bool send(request, params)

const string& request

the request keyword

const XMLData& params

the data (parameter payload)

Default value: XMLData("")


Send an API message to channel userman.