summaryrefslogtreecommitdiffstats
path: root/src/com/android/providers/downloads/DownloadProvider.java
Commit message (Collapse)AuthorAgeFilesLines
...
* | Fix build - remove reference to ReadOnlyCursorWrapperSteve Howard2010-07-151-3/+2
| | | | | | | | Change-Id: I099c98e310039886990502d63566f3e217738b45
* | am d1bec343: am 88ea0b39: Merge "Support for custom HTTP headers on download ↵Steve Howard2010-07-151-95/+180
|\| | | | | | | | | | | | | | | | | requests" into gingerbread Merge commit 'd1bec343dcbbc555837790119449ff7eea7c5312' * commit 'd1bec343dcbbc555837790119449ff7eea7c5312': Support for custom HTTP headers on download requests
| * Support for custom HTTP headers on download requestsSteve Howard2010-07-151-95/+180
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provider changes: * new many-to-one DB table holding headers for each download. since there was no real migration logic in DownloadProvider, I implemented some. * DownloadProvider.insert() reads request headers out of the ContentValues and puts them into the new table * DownloadProvider.query() supports a new URI form, download/#/headers, to fetch the headers associated with a download * DownloadProvider.delete() removes request headers from this table Service changes: * made DownloadInfo store request headers upon initialization. While I was at it, I refactored the initialization logic into DownloadInfo to get rid of the massive 24-parameter constructor. The right next step would be to move the update logic into DownloadInfo and merge it with the initialization logic; however, I realized that headers don't need to be updatable, and in the future, we won't need the update logic at all, so i didn't bother touching the update code. * made DownloadThread read headers from the DownloadInfo and include them in the request; merged the custom Cookie and Referer logic into this logic Also added a couple new test cases for this stuff. Change-Id: I421ce1f0a694e815f2e099795182393650fcb3ff
* | am 2c80c375: am 6d9b9828: Support for file URI destinations + last modified ↵Steve Howard2010-07-141-3/+20
|\| | | | | | | | | | | | | | | | | timestamp Merge commit '2c80c37546b89dfd31875f6f6e977e9610cdb22b' * commit '2c80c37546b89dfd31875f6f6e977e9610cdb22b': Support for file URI destinations + last modified timestamp
| * Support for file URI destinations + last modified timestampSteve Howard2010-07-141-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | File URI destinations: * permission checking in DownloadProvider * implementation in Helpers.generateSaveFile(). it's a fairly small amount of logic added here, but I did some significant method extraction to simplify this change and clean up the code in general. * added test case Last modified timestamp: * made DownloadProvider use a SystemFacade for getting system time, so I could properly test timestamps * updated test cases to cover last modified time + handle new ordering
* | Stop using private APIs that are going away.Jeff Hamilton2010-05-131-34/+0
|/ | | | Change-Id: Ic675d13e70e8e18af44d71b590f4782559966396
* Create a new permission that allows apps to see downloads from otherLeon Scroggins2010-02-051-7/+34
| | | | | | | | | | | | applications to the SD card. Necessary for http://b/issue?id=2384554 Also create names for files by default, so they do not display as <Untitled>. Remove calls to createTitleFromFilename, which are no longer necessary. Requires a change to frameworks/base.
* Grant access to downloaded packages to default container.Suchi Amalapurapu2010-01-271-3/+33
| | | | | The package name is hardcoded for now but will eventually move to a separate gid guarded by a permission.
* Use the private legacy APIJean-Baptiste Queru2010-01-141-87/+90
| | | | | | | | | | The public API is getting deeply reworked for forward compatibility, but since the Download Manager and the Browser need to continue using the old API, a separate copy is being kept on the side. Bug: 2245521 Change-Id: I85eff6ba9efc68600aa80e8dffa6720b0f2ed155
* Merge commit 'f0fa1cdc' into manualmergeJean-Baptiste Queru2009-07-061-0/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix crash in discardPurgeableFiles with proper selection syntax. The basic crash is that this codepath was doing a query to the download provider without properly quoting its selection arguments (which is mandated by the download provider). A secondary crash is that the DESTINATION column wasn't readable. This fixes bug 1941125. Tested by force-calling discardPurgeableFiles for each download to /cache, locally adding a few debugging statements to be sure that the codepath was getting executed, and doing a market download. Conflicts: src/com/android/providers/downloads/DownloadProvider.java src/com/android/providers/downloads/Helpers.java
| * Fix crash in discardPurgeableFiles with proper selection syntax.Jean-Baptiste Queru2009-07-021-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The basic crash is that this codepath was doing a query to the download provider without properly quoting its selection arguments (which is mandated by the download provider). A secondary crash is that the DESTINATION column wasn't readable. This fixes bug 1941125. Tested by force-calling discardPurgeableFiles for each download to /cache, locally adding a few debugging statements to be sure that the codepath was getting executed, and doing a market download.
| * auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-0/+731
| |
| * auto import from //depot/cupcake/@135843The Android Open Source Project2009-03-031-731/+0
| |
| * auto import from //branches/cupcake/...@130745The Android Open Source Project2009-02-101-8/+14
| |
* | Make the DownloadProvider work in the simulatorJean-Baptiste Queru2009-02-271-1/+2
| |
* | Refine interaction between destination and default visibility.Jean-Baptiste Queru2009-02-061-8/+14
| | | | | | | | | | | | The previous code was hard to read, and relied on the fact that one of the constants was 0 (which is also the default value when reading back uninitialized columns).
* | Use the new download manager APIs introduced in change 7400Jean-Baptiste Queru2009-01-211-70/+70
| |
* | Match the official code style guide.Jean-Baptiste Queru2009-01-201-3/+2
|/ | | | | | This fixes a number of style violations that weren't caught by automated tools and brings those files closer to compliance with the official style guide for this language.
* Code drop from //branches/cupcake/...@124589The Android Open Source Project2008-12-171-85/+278
|
* Initial ContributionThe Android Open Source Project2008-10-211-0/+532