public final class CBApp
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
com.eyro.cubeacon.helper.ImageLoader |
imageLoader |
Modifier and Type | Method and Description |
---|---|
void |
createService()
Creating Cubeacon SDK service.
|
static void |
enableDebugLogging()
Enable Cubeacon SDK debug logging.
|
static void |
enableDebugLogging(boolean isDebugMode)
Deprecated.
Use
enableDebugLogging() instead. |
static void |
enableDownloadImage(boolean flag)
Deprecated.
Method to initialize flag of download brochure image on
CBApp#refreshBeaconInBackground . |
static void |
exitSDK(android.app.Activity activity)
Deprecated.
Use
stopService instead. |
void |
getDataInBackground(RequestCallback callback)
Request the latest beacon and storyline data in background thread.
|
static CBApp |
getInstance()
Gets the instance of Cubeacon SDK.
|
static java.lang.String |
getSDKVersion()
Shows Cubeacon SDK version
|
static void |
initialize(android.content.Context context,
java.lang.String propertiesFile)
Initialize Cubeacon SDK.
|
static void |
initialize(android.content.Context applicationContext,
java.lang.String propertiesFile,
java.lang.String cbId,
java.lang.String cbKey,
java.lang.String kiiAppId,
java.lang.String kiiAppKey,
java.lang.String kiiSite)
Initialize Cubeacon SDK.
|
static void |
refreshBeaconInBackground(android.content.Context context,
com.eyro.cubeacon.CBConstant.RefreshCallback callback)
Deprecated.
Use
getDataInBackground instead. |
void |
setBeaconListener(android.content.Context context)
Setting up beacon listener for internal activity.
|
void |
setBeaconListener(android.content.Context context,
BeaconListener listener)
Setting up beacon listener for external activity.
|
void |
setScanPeriod(ScanningMode mode)
Setting up beacon scan period for foreground and background scanning.
|
static void |
setup(android.content.Context context,
java.lang.String propertiesFile)
Deprecated.
Use
initialize(Context, String) instead. |
static void |
setup(android.content.Context applicationContext,
java.lang.String cbId,
java.lang.String cbKey,
java.lang.String kiiAppId,
java.lang.String kiiAppKey,
java.lang.String kiiSite,
boolean applyStoryline,
boolean showBackgroundAlert,
boolean showForegroundAlert,
boolean showAlertOnEnter,
boolean showAlertOnExit,
java.lang.String defaultAlertTitle,
java.lang.String defaultAlertMessage)
Deprecated.
|
void |
startService()
Starting Cubeacon SDK service.
|
void |
stopService()
Stopping all Cubeacon SDK service.
|
@Deprecated public static void setup(android.content.Context applicationContext, java.lang.String cbId, java.lang.String cbKey, java.lang.String kiiAppId, java.lang.String kiiAppKey, java.lang.String kiiSite, boolean applyStoryline, boolean showBackgroundAlert, boolean showForegroundAlert, boolean showAlertOnEnter, boolean showAlertOnExit, java.lang.String defaultAlertTitle, java.lang.String defaultAlertMessage)
initialize(Context, String, String, String, String, String, String)
instead.applicationContext
- the application contextcbId
- the Cubeacon App IdcbKey
- the Cubeacon App KeykiiAppId
- the Kii App IdkiiAppKey
- the Kii App KeykiiSite
- the Kii SiteapplyStoryline
- boolean to indicate if storyline mode is appliedshowBackgroundAlert
- boolean to indicate if showing background alertshowForegroundAlert
- boolean to indicate if showing foreground alertshowAlertOnEnter
- boolean to indicate if showing alert on enter beaconshowAlertOnExit
- boolean to indicate if showing alert on exit beacondefaultAlertTitle
- default String of alert titledefaultAlertMessage
- default String of alert message@Deprecated public static void setup(android.content.Context context, java.lang.String propertiesFile)
initialize(Context, String)
instead.context
- the application contextpropertiesFile
- the properties filepublic static void initialize(android.content.Context context, java.lang.String propertiesFile)
context
- the application contextpropertiesFile
- the properties filepublic static void initialize(android.content.Context applicationContext, java.lang.String propertiesFile, java.lang.String cbId, java.lang.String cbKey, java.lang.String kiiAppId, java.lang.String kiiAppKey, java.lang.String kiiSite)
applicationContext
- the application contextpropertiesFile
- the properties filecbId
- the Cubeacon App IdcbKey
- the Cubeacon App KeykiiAppId
- the Kii App IdkiiAppKey
- the Kii App KeykiiSite
- the Kii Sitepublic static CBApp getInstance()
public static java.lang.String getSDKVersion()
String
of Cubeacon SDK version@Deprecated public static void enableDebugLogging(boolean isDebugMode)
enableDebugLogging()
instead.isDebugMode
- the boolean status to enable/disable debug loggingpublic static void enableDebugLogging()
@Deprecated public static void enableDownloadImage(boolean flag)
CBApp#refreshBeaconInBackground
.flag
- the boolean status to enable/disable download brochure image@Deprecated public static void refreshBeaconInBackground(android.content.Context context, com.eyro.cubeacon.CBConstant.RefreshCallback callback)
getDataInBackground
instead.context
- the context from activitycallback
- the callback function that called after refreshBeaconInBackground completepublic void setBeaconListener(android.content.Context context)
context
- context where beacon listener usedpublic void setBeaconListener(android.content.Context context, BeaconListener listener)
context
- context where beacon listener usedlistener
- beacon listenerpublic void setScanPeriod(ScanningMode mode)
mode
- the Enum ScanningMode
public void createService()
@Deprecated public static void exitSDK(android.app.Activity activity)
stopService
instead.activity
- Activity where Cubeacon SDK exitpublic void stopService()
public void startService()
public void getDataInBackground(RequestCallback callback)
callback
- callback interface that called when getting data complete