GithubHelp home page GithubHelp logo

downloadprovider's People

Contributors

geminiwen avatar yxl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

downloadprovider's Issues

why not use RandomAccessFile ?

if i downloading some large file .and then break. and reOpen my app, it will continue last download position or start new file again ???
Thanks.

Can you make it download in a queue?

This download manager will be perfect if it can queued download, and user can set max download threads at a time. If you have free time, please support this feature. Thank you.

SQLiteCantOpenDatabaseException:

android.database.sqlite.SQLiteCantOpenDatabaseException: unable to open database file (code 14)
	at android.database.sqlite.SQLiteConnection.nativeExecuteForChangedRowCount(Native Method)
	at android.database.sqlite.SQLiteConnection.executeForChangedRowCount(SQLiteConnection.java:732)
	at android.database.sqlite.SQLiteSession.executeForChangedRowCount(SQLiteSession.java:754)
	at android.database.sqlite.SQLiteStatement.executeUpdateDelete(SQLiteStatement.java:64)
	at android.database.sqlite.SQLiteDatabase.updateWithOnConflict(SQLiteDatabase.java:1576)
	at android.database.sqlite.SQLiteDatabase.update(SQLiteDatabase.java:1522)
	at com.mozillaonline.providers.downloads.DownloadProvider.update(DownloadProvider.java:925)
	at android.content.ContentProvider$Transport.update(ContentProvider.java:355)
	at android.content.ContentResolver.update(ContentResolver.java:1365)
	at com.mozillaonline.providers.downloads.DownloadThread.notifyThroughDatabase(DownloadThread.java:832)
	at com.mozillaonline.providers.downloads.DownloadThread.notifyDownloadCompleted(DownloadThread.java:807)
	at com.mozillaonline.providers.downloads.DownloadThread.run(DownloadThread.java:202)

Flashing ongoing notification!

In some devices ( like samsung Galaxy S5 ), ongoing notification flashing every time information get update! whats the problem here!

P.s:
Can you provide a sample demo to demonstrate using of pause/resume?!

android.content.ActivityNotFoundException

Exception for id 8: android.content.ActivityNotFoundException: Unable to find explicit activity class {com.mozillaonline.providers.downloads/com.mozillaonline.providers.downloads.SizeLimitActivity}; have you declared this activity in your AndroidManifest.xml?

There is a bug when it run in 3G mobile , and it is ok in wifi.

How to limit concurrent downloads?

i want to limit concurrent downloads to 1 or 2 download and add other download links to queue for download one by one or two by two. how can do it? is there any config ?

pauseDownload

DownloadInfo.java
void startIfReady(long now) a bug in this function
void startIfReady(long now) {
synchronized (this) {
if (!isReadyToStart(now)) { //set download paused will return
return;
}

        if (Constants.LOGV) {
            Log.v(Constants.TAG, "Service spawning thread to handle download " + mId + " mHasActiveThread=" + mHasActiveThread);
        }
        if (mHasActiveThread) {
            return;
            //throw new IllegalStateException("Multiple threads on same download");
        }
        if (mStatus != Downloads.STATUS_RUNNING) {
            mStatus = Downloads.STATUS_RUNNING;
            ContentValues values = new ContentValues();
            values.put(Downloads.COLUMN_STATUS, mStatus);
            mContext.getContentResolver().update(getAllDownloadsUri(), values, null, null);

            if (Constants.LOGV) {
                Log.v(Constants.TAG, "Service startIfReady return " + mId);
            }
            //click 'pause' button here, call pauseDownload(). After that, DownloadThread will never called for mId
            //return;
        }

        DownloadThread downloader = new DownloadThread(mContext, mSystemFacade, this);
        mHasActiveThread = true;
        mSystemFacade.startThread(downloader);
    }
}

exception noclassdeffounderror

I am trying to use the downloadmanager class inside the project instead of the android library but every time i try to use this exception is throne . what should i do?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.