Re: [android-developers] Re: Broadcast Receiver without Activity.

2010-02-14 Thread Dianne Hackborn
Please don't keep a service running just to register a receiver...!  Publish
the receiver in your manifest, so that the system will launch your app when
needed and not have to keep it running all of the time.

On Sun, Feb 14, 2010 at 3:44 AM, askPrins  wrote:

> Rogerio,
> What do you mean by using a service instead? Should the service
> initiate the receiver, e.g. using registerreceiver() ?
>
>
> On Feb 12, 9:35 pm, Rogério de Souza Moraes 
> wrote:
> > Hi askPrins,
> >
> > you can implement this using a service class instead of an activity
> class.
> > So you don't need the UI.
> >
> > Regards,
> >
> > Rogerio
> >
> > 2010/2/12 askPrins 
> >
> > > A WAP PUSH (Broadcast)receiver basically doesn't need any UI. It is a
> > > silence application which handles the Push messages based on actions/
> > > mimetype without needing any intreaction with user,
> > > I've tried to test it in a SMS receiver by removing the Activity from
> > > the project and it stopped receiving the SMS messages.
> > > My question: Does all android applications "MUST" define a activity?
> > > Is there a way to hide it?
> >
> > > --
> > > 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
>
> --
> 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
>



-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me, as I don't have time to
provide private support, and so won't reply to such e-mails.  All such
questions should be posted on public forums, where I and others can see and
answer them.

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

[android-developers] Re: Broadcast Receiver without Activity.

2010-02-14 Thread askPrins
Rogerio,
What do you mean by using a service instead? Should the service
initiate the receiver, e.g. using registerreceiver() ?


On Feb 12, 9:35 pm, Rogério de Souza Moraes 
wrote:
> Hi askPrins,
>
> you can implement this using a service class instead of an activity class.
> So you don't need the UI.
>
> Regards,
>
> Rogerio
>
> 2010/2/12 askPrins 
>
> > A WAP PUSH (Broadcast)receiver basically doesn't need any UI. It is a
> > silence application which handles the Push messages based on actions/
> > mimetype without needing any intreaction with user,
> > I've tried to test it in a SMS receiver by removing the Activity from
> > the project and it stopped receiving the SMS messages.
> > My question: Does all android applications "MUST" define a activity?
> > Is there a way to hide it?
>
> > --
> > 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

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