ok thanks.  I apologize for the redundant question, I just did more
google searches and I found a thread that discussed this already right
after I sent out my last response.

On Mar 10, 10:57 am, Mark Murphy <[email protected]> wrote:
> RCP2278 wrote:
> > Thanks for the quick reply.  What I mean "get an Activity object"
> > basically is getting a reference to that Activity, something like the
> > Instrumentation class does when it calls startActivitySync(), except
> > I'm not using Instrumentation.  For example:
>
> > Activity a = <what non-instrumentation API to use to get this>
>
> > Is this at all possible?  The reason I ask is because I notice that
> > some of the methonds of an Activity are declared public, and I want to
> > be able to access these methods from another class (that resides in
> > the same package as that Activity and resides in the same process, so
> > I'm not worried about security), but I can't do so unless I have a
> > reference to an Activity object.
>
> :: shrug ::
>
> As I said, I do not think there is an API for this, outside of
> Instrumentation. Leastways, I've never seen one, and I'm real sure there
> isn't one for services, based on prior list discussions.
>
> Pass the Activity object into the other class from the Activity itself
> via some sort of registration method. Or maintain your own static
> HashMap. Just be careful not to leak Activity instances.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Android Online Training: 26-30 April 2010:http://onlc.com

-- 
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