On Wed, Jan 12, 2011 at 4:53 PM, Mark Murphy <mmur...@commonsware.com>wrote:

> On Wed, Jan 12, 2011 at 5:58 PM, John Lussmyer <johnlussm...@gmail.com>
> wrote:
> > 3) Internal Storage - separate apps can't write to each others area, even
> if they have the same userid.
>
> AFAIK, they can. What proof do you have to the contrary? Not that this
> is particularly a good strategy for SDK apps, mind you.
>


You can't specify a path in the call to openFileOutput().  (Fails if there
are any path separators)
Hard to specify another apps directory if you can't use path separators.



>
> > So, in order to send 10 bytes of data to another app, it seems that I'll
> > have to create a new Activity and have it respond to an Intent().
>
> That is not the proper use of an Activity.
>
> > Is that really the only way to do this?
>
> -- Create a service, exposing an API through AIDL, consumed via
> bindService()
>
> -- Create a service, exposing an API through an Intent (sent via
> startService()) and returning results via a Messenger, or
> createPendingResult()'s PendingIntent, etc.
>
> -- Create a content provider
>
> There may be other options depending on what the "10 bytes of data"
> actually is, but those should get you started.
>
>
10 bytes of data is 10 bytes of data.  10 binary bytes.  Not text.
Only needs to be transferred occasionally, but does need to be transferred.

So, what you are saying is there is NO easy way to transfer a tiny bit of
data.
App X just needs to send it to App Y when the user does certain actions.
sigh.
(In this case there are 2 apps, either of which can be used independently,
but if both are on the phone, they can work together.)

A SharedPreference would have been perfect - but the "Shared" prefix seems
to have a different meaning than what you would think.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to