Intent usage intent (2)

Source: Internet
Author: User

Intent serves as a bond between activities, and its function is not only limited to simple data transmission. Its built-in attributes allow you to conveniently complete many complex operations. For example, you can directly call the dial-up function and automatically call appropriate programs to open different types of files.

Category:

The category attribute is used to specify the stage in which the current action is executed. Use the addcategory () method or set it in the androidmanifest. xml file of the configuration file. Default Value: category_default.

Constant name

Meaning

Category_default

In the Android system, the default execution method is normal activity execution.

Category_alternative

Specify the action to be performed as an option for the default action to be executed on a specific data type (for example, the default action of a contact is to view its information, the optional action is to edit the information)

Category_car_dock

Run the activity when the mobile phone is inserted into the car base (hardware ).

Category_car_mode

You can set this activity to be used in a vehicle-mounted environment.

Category_assist_dock

Run the activity when the mobile phone is inserted into the desktop base (hardware ).

Category_preference

Set this component to preference.

Category_development_preference

Activity is a set panel

Category_embed

It can run in the activity container.

Category_framework_instrumentation_test

Code used as a test instrument test framework

Category_home

Set this component to home activity.

Category_launcher

Set this component to the activity with the highest priority in the current application initiator. It is usually used with the entry action_main (action.

Category_browsable

You can set this component to start in a browser.

Category_gadget

This component can be embedded in another activity.

Reprinted please indicate the source => csdn fat Tiger: http://blog.csdn.net/ljphhj

Category_info

Used to provide package information

Category_monkey

It can be executed by monkey or other test tools.

Category_openable

Indicates the intent of an action_get_content object. It is expected that contentresolver. openinputstream can open the URI.

Category_sample_code

Used as a simple code example (this is generally not used by users)

Category_selected_alternative

Set whether this activity can be considered a selectable action for the user's currently selected data (for plug-in extension: http://www.cnblogs.com/xirihanlin/archive/2009/07/31/1536055.html)

Category_tab

Used in a tabactivity

Category_test

For general test sample programs (not required by General Users)

Category_unit_test

For Unit Testing


Intent usage intent (2)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.