Android Download Manager

Source: Internet
Author: User

Download Manager, there's a guy who writes well. http://www.trinea.cn/android/android-downloadmanager/

    • Download background Notifications
    • Download Manager Content Interaction

Recently tidied up the internal business logic

A. Processing the content being downloaded

B. Processing the downloaded content

For download business, user sensitivity to events is divided into:

Class A: Whether to start the download, whether the download is complete

Class B: Download progress, about how long it takes to download
1 downloading is a more time-consuming operation, we will not give a screen to show the download progress, but we still want to give the user prompt.

Android notification is specifically to solve this problem, in the Systemui there is a block area to display the notification, it occupies a small place, in the case of minimizing the interruption of user action to give hints.

Notification bar According to the design, the current display strategy is:

For the download to complete, each download to make a prompt, click on the notification, it can go back to launch the download app

For the download there is a situation that shows the specific progress, there are several downloads showing that there are multiple downloads;

The following strategies are used:

Download the completion notification after clicking back to download Provider Downloadreceiver, launch the downloaded app in the broadcast receiver or send downloadmanager.action_notification_clicked broadcast to the corresponding app.

Download notification Click to go directly to the Download Manager interface

The Download Manager manages a series of downloads, which he organizes and proxies for other individual applications, including download control (pause, continue, end), downloads open, and sometimes users who are more concerned about who the content is.

For these, the user sets the policy when the download is initiated and executes here.

For download control, call the Downloadmanager interface to implement the download, download the content through ContentProvider monitoring update

Related Article

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.