All Projects → MindorksOpenSource → Prdownloader

MindorksOpenSource / Prdownloader

Licence: apache-2.0
PRDownloader - A file downloader library for Android with pause and resume support

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Prdownloader

Filedownloader
Multitask、MultiThread(MultiConnection)、Breakpoint-resume、High-concurrency、Simple to use、Single/NotSingle-process
Stars: ✭ 10,408 (+253.17%)
Mutual labels:  downloader, breakpoint, filedownloader
Mega-index-heroku
Mega nz heroku index, Serves mega.nz to http via heroku web. It Alters downloading speed and stability
Stars: ✭ 165 (-94.4%)
Mutual labels:  resume, downloader, pause
su-downloader3
nodejs HTTP downloader with pause/resume support and segmented downloading
Stars: ✭ 14 (-99.52%)
Mutual labels:  downloader, download-manager, large-files
Rxdownloader
- Reactive Extension Library for Android to download files
Stars: ✭ 40 (-98.64%)
Mutual labels:  library, downloader
Curl
A command line tool and library for transferring data with URL syntax, supporting DICT, FILE, FTP, FTPS, GOPHER, GOPHERS, HTTP, HTTPS, IMAP, IMAPS, LDAP, LDAPS, MQTT, POP3, POP3S, RTMP, RTMPS, RTSP, SCP, SFTP, SMB, SMBS, SMTP, SMTPS, TELNET and TFTP. libcurl offers a myriad of powerful features
Stars: ✭ 22,875 (+676.21%)
Mutual labels:  library, https
Restinio
Cross-platform, efficient, customizable, and robust asynchronous HTTP/WebSocket server C++14 library with the right balance between performance and ease of use
Stars: ✭ 694 (-76.45%)
Mutual labels:  library, https
Fgdownloader
用于断点下载、任务队列、上传进度、下载进度
Stars: ✭ 143 (-95.15%)
Mutual labels:  downloader, breakpoint
Yt Dlc
media downloader and library for various sites.
Stars: ✭ 2,590 (-12.11%)
Mutual labels:  library, downloader
Instascrape
🚀 A fast and lightweight utility and Python library for downloading posts, stories, and highlights from Instagram.
Stars: ✭ 76 (-97.42%)
Mutual labels:  library, downloader
super-anime-downloader
A program which takes an Anime name or URL and downloads the specified range of episodes.
Stars: ✭ 26 (-99.12%)
Mutual labels:  downloader, download-manager
CocoaDownloader
An powerful download library for iOS, macOS.
Stars: ✭ 22 (-99.25%)
Mutual labels:  downloader, download-manager
Libevhtp
Create extremely-fast and secure embedded HTTP servers with ease.
Stars: ✭ 363 (-87.68%)
Mutual labels:  library, https
Xdm
Powerfull download accelerator and video downloader
Stars: ✭ 3,226 (+9.47%)
Mutual labels:  downloader, download-manager
Mythra
Music retrieval CLI and API using rust
Stars: ✭ 37 (-98.74%)
Mutual labels:  library, downloader
Nacollector
⚔ 一个采集工具箱,据说是一个用于采集各种 WEB 资源的工作站?!你可以认为这是一个框架,可拓展。淘宝、天猫、苏宁、国美 等电商平台数据采集... 一键邀请 一键打包 账号登录获取Cookie 任务多线程 下载内容管理 实时日志 dll 热更新 无边框窗体 Web App, CefSharp, WebDriver
Stars: ✭ 158 (-94.64%)
Mutual labels:  downloader, download-manager
Simple Web Server
A very simple, fast, multithreaded, platform independent HTTP and HTTPS server and client library implemented using C++11 and Boost.Asio. Created to be an easy way to make REST resources available from C++ applications.
Stars: ✭ 2,261 (-23.28%)
Mutual labels:  library, https
Floatplane-Downloader
Project for automatically organizing and downloading Floatplane videos for plex.
Stars: ✭ 94 (-96.81%)
Mutual labels:  downloader, download-manager
dl
Command-line file downloader tool
Stars: ✭ 39 (-98.68%)
Mutual labels:  downloader, download-manager
4chan Downloader
Python3 script to continuously download all images/webms of multiple 4chan thread simultaneously - without installation
Stars: ✭ 136 (-95.39%)
Mutual labels:  downloader, download-manager
Massivedl
Download a large list of files concurrently
Stars: ✭ 141 (-95.22%)
Mutual labels:  downloader, download-manager

PRDownloader

PRDownloader - A file downloader library for Android with pause and resume support

Mindorks Android Store Mindorks Mindorks Community License

Sample Download

Overview of PRDownloader library

  • PRDownloader can be used to download any type of files like image, video, pdf, apk and etc.
  • This file downloader library supports pause and resume while downloading a file.
  • Supports large file download.
  • This downloader library has a simple interface to make download request.
  • We can check if the status of downloading with the given download Id.
  • PRDownloader gives callbacks for everything like onProgress, onCancel, onStart, onError and etc while downloading a file.
  • Supports proper request canceling.
  • Many requests can be made in parallel.
  • All types of customization are possible.

Using PRDownloader Library in your Android application

Add this in your build.gradle

implementation 'com.mindorks.android:prdownloader:0.6.0'

Do not forget to add internet permission in manifest if already not present

<uses-permission android:name="android.permission.INTERNET" />

Then initialize it in onCreate() Method of application class :

PRDownloader.initialize(getApplicationContext());

Initializing it with some customization

// Enabling database for resume support even after the application is killed:
PRDownloaderConfig config = PRDownloaderConfig.newBuilder()
                .setDatabaseEnabled(true)
                .build();
PRDownloader.initialize(getApplicationContext(), config);

// Setting timeout globally for the download network requests:
PRDownloaderConfig config = PRDownloaderConfig.newBuilder()
                .setReadTimeout(30_000)
                .setConnectTimeout(30_000)
                .build();
PRDownloader.initialize(getApplicationContext(), config); 

Make a download request

int downloadId = PRDownloader.download(url, dirPath, fileName)
                        .build()
                        .setOnStartOrResumeListener(new OnStartOrResumeListener() {
                            @Override
                            public void onStartOrResume() {
                               
                            }
                        })
                        .setOnPauseListener(new OnPauseListener() {
                            @Override
                            public void onPause() {
                               
                            }
                        })
                        .setOnCancelListener(new OnCancelListener() {
                            @Override
                            public void onCancel() {
                                
                            }
                        })
                        .setOnProgressListener(new OnProgressListener() {
                            @Override
                            public void onProgress(Progress progress) {
                               
                            }
                        })
                        .start(new OnDownloadListener() {
                            @Override
                            public void onDownloadComplete() {
                               
                            }

                            @Override
                            public void onError(Error error) {
                               
                            }
                        });            

Pause a download request

PRDownloader.pause(downloadId);

Resume a download request

PRDownloader.resume(downloadId);

Cancel a download request

// Cancel with the download id
PRDownloader.cancel(downloadId);
// The tag can be set to any request and then can be used to cancel the request
PRDownloader.cancel(TAG);
// Cancel all the requests
PRDownloader.cancelAll();

Status of a download request

Status status = PRDownloader.getStatus(downloadId);

Clean up resumed files if database enabled

// Method to clean up temporary resumed files which is older than the given day
PRDownloader.cleanUp(days);

TODO

  • Integration with other libraries like OkHttp, RxJava
  • Test Cases
  • And of course many many features and bug fixes

If this library helps you in anyway, show your love ❤️ by putting a on this project ✌️

Learn to build a ride-sharing Android app like Uber, Lyft - Check here

Check out Mindorks awesome open source projects here

License

   Copyright (C) 2017 MINDORKS NEXTGEN PRIVATE LIMITED

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.

Contributing to PRDownloader

All pull requests are welcome, make sure to follow the contribution guidelines when you submit pull request.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].