Re: FileTransfer download null-target

2013-12-05 Thread Tommy Williams
If I understand this correctly, then I am very much +1. There is currently a layer of callback hell and a painful procedure just to download a file you won't care about 10 minutes later, heh. On 06/12/2013 2:44 am, "Ian Clelland" wrote: > On Thu, Dec 5, 2013 at 9:56 AM, Axel Nennker > wrote: >

Re: FileTransfer download null-target

2013-12-05 Thread Ian Clelland
On Thu, Dec 5, 2013 at 9:56 AM, Axel Nennker wrote: > Exposing a mkstemp like function would be another issue. > Where would you put it? The W3C File API does not have this. > http://www.w3.org/TR/FileAPI/ I just mean that it has similar semantics to mkstemp -- without the template, I suppose:

Re: FileTransfer download null-target

2013-12-05 Thread Axel Nennker
Exposing a mkstemp like function would be another issue. Where would you put it? The W3C File API does not have this. http://www.w3.org/TR/FileAPI/ I think that implementing "target==null" for FileTransfer.download on Android is super simple. I guess that it is simple an other platforms too. I st

Re: FileTransfer download null-target

2013-12-05 Thread Ian Clelland
This could be really useful -- like a mkstemp() function -- to avoid any possibility of name collision, and save the user from the hassle of managing names that they don't really care about anyway. I wonder how many developers have had to independently implement some kind of "generate random filen

FileTransfer download null-target

2013-12-05 Thread Axel.Nennker
Hi, I think a developer who uses FileTransfer's download does not always care to which file the remote content is downloaded to. I suggest to allow a target parameter of "null" to denote some temporary file. https://github.com/apache/cordova-plugin-file-transfer/blob/master/src/android/FileTrans