Android SDK

Be sure to read Android: Getting Started

Source code for the SDK is here: https://github.com/pauluxprobe/uxprobeClientSDK

API

init

Description
Called once to initialize the logger and set the account ID and a context
Method
public void init(String accountID, Context ctx)
Arguments
String accountID
Context ctx

Returns
void

setEnabled

Description
Disable all logging by setting false, default is true
Method
public synchronized void setEnabled(Boolean enabled)
Arguments
Boolean enabled
Returns
void

pauseSending

Description
Pause the sending of events but not the recording of events, default is false
Method
public synchronized void pauseSending(boolean pause)
Arguments
boolean pause
Returns
void

setWifiOnly

Description
Send events when in wifi but not 3g/4g
Method
public synchronized void setWifiOnly(boolean wifi)
Arguments
boolean wifi
Returns
void

setTimerFrequency

Description
The time between sending events in seconds, default is 10,000 milliseconds
Method
public synchronized void setTimerFrequency(int millisecs)
Arguments
int millisecs
Returns
void

setSessionTimeout

Description
Default is 0, no timeout. Value is in seconds. If two events are separated by a time greater than this value then a new session start will be sent
Method
public synchronized void setSessionTimeout(int seconds)
Arguments
int seconds
Returns
void

setMaxBatchSize

Description
Number of events to send each batch, default is 50
Method
public synchronized void setMaxBatchSize(int size)
Arguments
int size
Returns
void

logStartSession

Description
Call this once at the beginning of the user session. It is critical that this is called prior to any other UXprobe log methods
Method
public synchronized void logStartSession(String product, String version, String userID, Map<String, String> tags)
Arguments
String product
String version
String userID
Map<String, String> tags

Returns
void

logEndSession

Description
Stop the user session, the last UXprobe call that should be made, not mandatory
Method
public synchronized void logEndSession(Map<String, String> tags)
Arguments
None
Returns
void

logStartTask

Description
Marks the start of a new task
Method
public synchronized void logStartTask(String taskID, Map<String, String> tags)
Arguments
String taskID
Map<String, String> tags

Returns
void

logEndTask

Description
Mark the completion of a task
Method
public synchronized void logEndTask(String taskID, Map<String, String> tags)
Arguments
String taskID
Map<String, String> tags

Returns
void

logScreen

Description
Record the user visiting a screen, dialog etc
Method
public synchronized void logScreen(String screenID, Map<String, String> tags)
Arguments
String screenID
Map<String, String> tags

Returns
void

logFeature

Description
Record a feature a user has selected, e.g. menu item selected or button click
Method
public synchronized void logFeature(String featureID, Map<String, String> tags)
Arguments
String featureID
Map<String, String> tags

Returns
void

logError

Description
Record an error, can be a user error, e.g. a form field that was not filled out correctly, or a system error, e.g. exception
Method
public synchronized void logError(String errorID, String uiElement, String userInput, String errorMessage, Map<String, String> tags)
Arguments
String errorID
String uiElement
String userInput
String errorMessage
Map<String, String> tags

Returns
void

logFeedback

Description
Record the active user feedback
Method
public synchronized void logFeedback(String type, String comment, Map<String, String> tags)
Arguments
String type, String comment
Map<String, String> tags

Returns
void

logSurveyWithUI

Description
Show native UI and record the answers to the specified survey
Method
public void logSurveyWithUI(final String surveyID, String title, String[] questions, boolean showCancel, final Map<String, String> tags)
Arguments
final String surveyID
String title
String[] questions
boolean showCancel
final Map<String, String> tags

Returns
void

logSurvey

Description
Record the answers for a survey (after showing your own UI)
Method
public void logSurvey(String surveyID, String[] answers, Map<String, String> tags)
Arguments
String surveyID
String[] answers
Map<String, String> tags

Returns
void

getSurvey

Description
Return a URL with which you can display an html survey
Method
public String getSurvey(String surveyID)
Arguments
String surveyID
Returns
String

getAllSurveys

Description
URL which will return a JSON dictionary of all surveys
Method
public String getAllSurveys()
Arguments
Arguments
None
Returns
String