On Fri, Feb 25, 2011 at 9:32 PM, Dmitry Golubovsky <[email protected]> wrote:
> So, on a "compilant" device getExternalStorageDirectory would return a
> real sdcard mountpoint?

There is no such concept as "a real sdcard mountpoint" in Android.
getExternalStorageDirectory(), on a properly-written ROM, should
return the same directory that the user would see if they mount
external storage on their PC or Mac.

> Well, I need to use what a random/average customer could pick.

As far as I am concerned, your device does not qualify for this
criterion. Pick something that legitimately comes with the Android
Market. Your device does not support third-party apps, at least
according to its manufacturer. Expecting this device to behave
properly for third-party apps, therefore, is a mistake.

> Anyway, if there is no "formal" answer, I'll need to apply more
> heuristics... it is a mountpoint anyway, controlled by vold (sp?), I
> am assuming at least this holds for all devices?

If you want a Linux box, don't get an Android device, or plan to
create your own firmware. Making *any* assumptions about things
outside of the Android SDK -- such as mountpoints, particular daemons,
etc. -- is a recipe for trouble.

> I am worried about the portable
way to tell my program where is the sdcard root directory is mounted
because part of the usage scenario is user being able to upload
certain files to sdcard where my program must be able to find them.

Use getExternalStorageDirectory().

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to *Advanced* Android Development_ Version 1.9
Available!

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" 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-developers?hl=en

Reply via email to