Advanced Functions UI BizBundle

Last Updated on : 2024-04-01 07:04:54download

The Advanced Functions UI BizBundle provides a container for Android that hosts the app’s advanced functions. The following advanced functions are available.

Integrate with the UI BizBundle

Create a project

Integrate Smart Life App SDK for Android into your project with Android Studio, and add the UI BizBundle to your project. For more information, see Integrate with Framework for Android.

Configure build.gradle

   dependencies {
       api enforcedPlatform("${biz_bom_version}")
       implementation ''
       api "${sdk_version}}"

Obfuscate the code

# Obfuscates the code of all third-party dependencies in build.gradle.

# fastJson
-keep class**{*;}

-keep class com.squareup.okhttp.** { *; }
-keep interface com.squareup.okhttp.** { *; }
-dontwarn com.squareup.okhttp.**

-keep class okio.** { *; }
-dontwarn okio.**

-keep class com.thingclips.**{*;}
-dontwarn com.thingclips.**

Implement functions

Enumerate advanced function types

public enum PersonalThirdServiceType {
    // Short message service
    // Phone notification

    private final String type;

    PersonalThirdServiceType(String type) {
        this.type = type;

    public String getType() {
        return type;

Query advanced functions

Query advanced functions based on types. An asynchronous callback is implemented.

API description

void requestPersonalThirdService(long homeId, PersonalThirdServiceType type, IPersonalThirdServiceCallback callback)


Parameter Description
HomeId The ID of the currently selected home.
PersonalThirdServiceType The type of an advanced function.
IPersonalThirdServiceCallback The asynchronous callback of querying the advanced functions.


AbsPersonalThirdService thirdService = MicroContext.getServiceManager()
thirdService.requestPersonalThirdService(homeId, PersonalThirdServiceType.PUSH_SMS_SERVICE,
    new IPersonalThirdServiceCallback() {
        public void onSuccess(ThirdIntegrationBean bean) {
            String url = bean != null ? bean.getUrl() : null;
            Log.i("third_service", "url = " + url);

        public void onError(String errorCode, String errorMessage) {


Open an advanced function page

Displays an advanced function page by means of activities or fragments.



Intent intent = new Intent(context, WebViewActivity.class);
intent.putExtra("Uri", url);


WebViewFragment fragment = new WebViewFragment();
Bundle args = new Bundle();
args.putString("Uri", url);
args.putBoolean("enableLeftArea", true);
.add(, fragment, WebViewFragment.class.getSimpleName())