The InsightIntent framework provides an intent debugging tool for debugging intents after they access the framework. This tool can be used to query and execute intents.
Intent debugging is supported only on mobile phones, and the corresponding API version must be 20 or later.
Enable the intent debugging capability.
View intents. On the InsightIntent debugging page, tap View all InsightIntents on device.
You can view all registered intents on the current page.
Debug intents.
Set intent parameters.
Tap Execute InsightIntent.
If the intent implemented is correct, the execution is successful. The execution results of different types of intents are as follows:
| Decorator | Execution Mode | Intent Call Result |
|---|---|---|
| @InsightIntentLink | UI_ABILITY_FOREGROUND | The page is redirected. A semi-modal window appears in the lower part to display the intent call return result. |
| @InsightIntentPage | UI_ABILITY_FOREGROUND | The page is redirected. A semi-modal window appears in the lower part to display the intent call return result. |
| @InsightIntentEntry | UI_ABILITY_FOREGROUND | The page is redirected. A semi-modal window appears in the lower part to display the intent call return result. |
| @InsightIntentEntry | UI_ABILITY_BACKGROUND | A semi-modal window appears in the lower part to display the intent call return result. |
| @InsightIntentEntry | UI_EXTENSION_ABILITY | A semi-modal window appears in the lower part to display the embedded UIExtensionAbility page. |
| @InsightIntentFunctionMethod | UI_ABILITY_BACKGROUND | A semi-modal window appears in the lower part to display the intent call return result. |
| @InsightIntentForm | - | An embedded widget page. You can tap the widget to go to the application. |