Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Contributor
Posts: 7
Registered: ‎04-29-2010
My Device: Various
My Carrier: Various

What is the difference between a paused MIDlet and a background CLDC app?

Hi,

I searched for "background MIDlet" on blackberry.com and found statements
like:

"MIDlets do not support background processing.  So it should be expected
that a MIDlet is paused when it is not in the foreground."

and

"Note that if you were to change the application from a MIDlet to a
BlackBerry CLDC application you would have the ability to run the
application in the background and keep it running indefinitely."


But other people suggest that call to notifyPaused or
display.setCurrent(null) does bring the MIDlet to a background or paused
state. So, I tried both ways on my 8330m and now I see that my MIDlets do, indeed, work
on the background, they are shown in the "Switch Application" window, their
threads are working, connections arriving, etc. So, they appear to behave
exactly like CLDC app running on the background.

But then what do these statements quoted above mean? What is the difference
between a paused MIDlet and a background CLDC app?

In particular, what this statement "CLDC ... have the ability to run the
application in the background and keep it running indefinitely" mean? Does
it suggest that a MIDlet would not stay in paused state indefinitely? Would
it be destroyed at some point?

Could someone clarify?

Thank you