The simple answer is "it's complicated".

Just for the record, I wrote most of the download provider, so I'm a
fair bit familiar with it (to say the least).

-The download provider is not proprietary code. It is also considered
a non-optional part of the platform. It is indeed meant to provide
download facilities to several applications. On the T-Mobile G1, it is
used by the browser, gmail, market, and the system updater (the latter
three being proprietary).

-On the other hand, the download provider is currently explicitly set
up such that it cannot be used by third-party applications. The
largest reason for that situation is that the download manager is not
currently solid enough to resist denial-of-service attacks from
malicious applications (including in situations where the user would
install such an application with the explicit purpose of disrupting
the proper operation of the download manager).

-There are a few other concerns, e.g. the API is dusty, dirty and incomplete.


About the "big picture" question: typically, once you have a change in
a source tree, you've got to wait until an official release version is
made out of that source tree, until that release it ported to the
target device, and until the result is either sold in new devices or
pushed/released to existing devices.


If you'd like to contribute in the download provider, there are two
directions that could help you achieve your goal:

-one would be to clean up the code so that it uses fewer non-SDK APIs,
such that the code itself can be re-used in other applications. That's
not as satisfactory, but it might be a lot more practical.

-the other would be to write some test code that would allow to
explicitly test the database upgrade code, which would in turn allow
to clean up the API. That's not gonna be everything that's needed to
make the download provide accessible to your apps, but it'll get us
closer.

JBQ

On Tue, Jan 6, 2009 at 8:30 AM, lummie <[email protected]> wrote:
>
> I have got the Android source from source.android.com.  In the source,
> there is a java package, com.android.providers.downloads, which
> provides by the looks of it a common method of downloading files
> without re-inventing the wheel.
>
> This package does not seem to be available on the Android 1.0 SDK.
>
> I assume this package is available on the G1 phone though as it is
> used for the marketplace.
>
> I seem to be missing something, if it is proprietary, how come it is
> in the opensource android source ?  Is it only shipped by t-mobile on
> the G1, or by google ?  Do google pick and choose from the opensource
> project what ends up on the phone or in the SDK ?
>
> If so, if I was to contribute to the opensource android code, and
> create a common provider that could be used by many applications, at
> what point would that actually make it onto a device so I could use it
> from my applciations?
>
> Any clarification or help to improve my understanding is
> appreciated....
>
> Matt
>
> >
>



-- 
Jean-Baptiste M. "JBQ" Queru
Android Engineer, Google.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"android-framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/android-framework?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to