O'Reilly logo

Programming Wireless Devices with the Java™ 2 Platform, Micro Edition, Second Edition by Jim Holliday - Editor, Aleksi Uotila, Mark Patel, Jyri Huopaniemi, Jim Van Peursem, Antero Taivalsaari, Roger Riggs

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

20.1. Timer Support

MIDlets may need to delay or schedule activities to be performed at a later time. The MIDP Specification provides two mechanisms to enable this:

  • Timers are used for time-based events while a MIDlet is running. For example, a timer used to change the frame being shown in an animation sequence. Timers are covered in this section.

  • Alarms provide a one-shot time for MIDlets to be launched if they are not already running. Automatic launching can be convenient, for example, to register the next appointment in a calendar. Alarm-based MIDlet launching is covered in Section 17.1, “Alarm-Based MIDlet Launch.”

The MIDP Specification

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required