The MIDP High-Level API
Sep 26,2007 00:00 by admin
The MIDP High-Level API
• Command Processing
• Command-Processing Scenario
• Screen Navigation
• Command Organization
At this point, you know how to organize the UI of a basic MIDP application. In any MIDlet more
complicated than the first contrived example you saw, you have to define multiple screens. The
application moves from screen to screen in response to user input from the keypad, soft keys, or
function buttons of a typical mobile device.
To build more complex applications, you need to learn how the MIDP accommodates user input
and does event processing. This chapter covers the MIDP's high-level API, which defines the
abstractions that accommodate handling high-level application events.
The high-level API is the first of two APIs for MIDP UI components. The other is the low-level
API, which you'll learn about in chapter 5. The term high-level refers to the API's high level of
granularity that is provided to the programmer in two areas:
• ability to manipulate the look and feel of UI widgets
• granularity of information about events and event handling
All the UI components under the Screen class hierarchy implement the high-level API. These
widgets don't give you the ability to change their look-and-feel. As for events, the information
available to the application is at a high level of abstraction. Applications don't have access to
concrete input devices. For example, using the Screen abstraction, applications don't have access
to information about what physical keys the user presses.
The high-level API is designed for business applications that must be portable across many
devices. Therefore, the MIDP implementation abstracts the details of things like the
implementation to hardware.
eXTReMe Tracker