alirezat775 / downloader Goto Github PK
View Code? Open in Web Editor NEWDownloader for android with pause, resume, cancel, queue options
License: Apache License 2.0
Downloader for android with pause, resume, cancel, queue options
License: Apache License 2.0
hello, when using the library, I encountered a problem:
sometimes lib calls onFailure
with such reason message:
java.lang.IllegalStateException: attempt to re-open an already-closed object: SQLiteDatabase: /data/user/0/packagename/databases/downloader_db
If this info will help with understanding:
I'm using this lib for loading images in recyclerview as context I'm using applicationContext
.
Can it be cuz, fast scrolling of recyclerview and, in this reason, several instances of Downloader
, creating?
Noted that some of my downloads were failing because the autogenerated file name was too long.
I was able to trace the source of the issue to the 'DownloadTask.kt' file. After some tries I updated the code on my end to
/**
private fun cleanName(): String{
return DatabaseApp().getDownloadsDao(context.get()!!.applicationContext).getDownloadByUrl(url).name
.replace("[VIDEO ONLY]", "").replace("[AUDIO ONLY]", "").substring(0, 25)
}
This checks the filename size and the cleanName creates a 25 character name to append to the file
i am using this library ...all work is good but when show the download file that time one more extension in end of file
means when i download your url "https://s3-us-west-2.amazonaws.com/uw-s3-cdn/wp-content/uploads/sites/6/2017/11/04133712/waterfall.jpg"
that time i get in suacess download "waterfall.jpg.jpeg"
this also same as pdf files ...pdf file output is ".pdf.pdf"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.