Home > Store

Wireless J2ME Platform Programming

Register your product to gain access to bonus material or receive a coupon.

Wireless J2ME Platform Programming

Book

  • Sorry, this book is no longer in print.
Not for Sale

Description

  • Copyright 2002
  • Edition: 1st
  • Book
  • ISBN-10: 0-13-044914-8
  • ISBN-13: 978-0-13-044914-6

The authoritative tutorial for wireless J2ME application developers.

  • The essential tutorial for every J2ME platform developer: no wireless experience necessary
  • Complete coverage of architecture, design, coding, debugging, and deployment
  • Advanced topics include-persistent storage, networking, distributed processing, and internationalization
  • The J2ME platform: key terminology, concepts, and application development processes

The Java 2 Micro Edition (J2ME) platform gives developers breakthrough tools for building advanced wireless applications. Now, one of the leading wireless application consultants at Sun has written a step-by-step guide to successful wireless development using the J2ME SDK. Vartan Piroumian illuminates every key feature of the J2ME platform and every step of the development process: planning, architecture, design, coding, compilation, execution, debugging, and deployment. Wireless J2ME Platform Programming covers all this, and more:

  • Using the Mobile Information Device Profile's (MIDP) high-level and low-level APIs
  • Building effective wireless user interfaces with the J2ME platform
  • Leveraging the J2ME platform's facilities for persistent storage
  • Managing, provisioning, and internationalizing wireless applications
  • Integrating complete wireless solutions: Internet portal interfaces, wireless application interfaces, and the wireless Internet environment

Wireless J2ME Platform Programming: The must-have guide for writing robust, highly usable, cross-platform wireless applications.

Back cover box:

Featured topics include:

  • Configurations and profiles
  • User interface components
  • MIDP high-level & low-level APIs
  • MIDP Record Management System (RMS)
  • Event Handling
  • MIDP Generic Connection Framework
  • Application Provisioning systems
  • Application Architecture and the Wireless Internet Environment

Downloads

Downloads

For your convenience, you can download the complete set of code examples from the book in a compressed archive. The code is available in two compression formats:

Sample Content

Online Sample Chapter

Wireless J2ME Platform Programming

Table of Contents

(NOTE: Each chapter concludes with a Summary.)

Foreword.


Preface.


Acknowledgments.


Introduction.


1. Introduction to the Java 2 Micro Edition (J2ME) Platform.

Defining a Java Platform for Pervasive Devices. Configurations and Profiles. The Connected Device Configuration (CDC). Connected, Limited Device Configuration (CLDC). Device Application Management Systems.



2. The MIDP Application Development Process.

Designing and Coding. Compilation. Preverification. Packaging. Creating the JAR Manifest File. Creating the MIDlet Suite JAR File. Creating the MIDlet Suite Application Descriptor File. Deployment and Execution. Using the J2ME Wireless Toolkit. Creating a Project. Placing Source Code in the Project. Compiling the Project. Packaging the Project. Deploying the Application. Executing the Application.



3. MIDP Application Program Structure.

The Application Execution Lifecycle. MIDlet Program Structure. The MIDlet State Model. The MIDP UI Component Model. System Properties. Application Properties.



4. The MIDP High-Level API.

Command Processing. Command-Processing Scenario. Screen Navigation. Command Organization. Command Ordering. Command Semantics.



5. The MIDP UI Components.

MIDP UI Component Hierarchy. Screens and Screen Elements. Screen Navigation. More Item Components. DateField. StringItem. Gauge. Ticker. ImageItem. One More Screen Type.



6. The MIDP Low-Level API.

Command and Event Handling. Key Events. Game Actions. Graphics Drawing. The Graphics Model. The Graphics Class. Basic Geometric Drawing. Clipping. Translation. How Components Are Painted. Double Buffering. Image Display Using a Canvas.



7. Persistent Storage Support in MIDP.

Device Support for Persistent Storage. RMS Data Storage Model. Records. An Example Application. Manipulating byte [] Data. Enumerations. Record Filters. Record Comparators. Record Listeners. Miscellaneous Record Store Features.



8. MIDP Networking and Communications.

The MIDP Networking Model. The MIDP Generic Connection Framework. Connectors and Connections. Generic Connection Framework Classes and Interfaces. Stream Connections. Content Connections. Datagram Connections and Datagrams. Socket Connections. Differences between J2ME and J2SE Networking.



9. Internationalization.

Concepts. Locales and Localization. Character Encoding Sets. Aspects of Internationalization. Internationalization Support in MIDP. I18N Frameworks. Messaging. String Collation. Date, Time, and Numeric Formatting. Calendar and Time Zone Support. Designing an I18N Solution for a MIDP Application. Using MIDlet Attributes to Define L10N Resources. Using Application Text Files to Define L10N Resources. Using Java Class Files to Define I18N Resources. Application Provisioning of L10N Resources.



10. Application Provisioning.

Concepts. The Provisioning Process. Application Registration. Application Search. Compatibility Verification. Purchase Verification and Non-Repudiation. User Authentication. Application Software License Negotiation. Application Download. Application Installation and Installation Verification. Billing Event Generation. Application Update. Application Removal. Preparing Applications for Provisioning Systems.



11. The Wireless Internet Environment.

Background, Terminology, and Concepts. The Wireless Application Environment. Wireless Applications. Messaging. Personal Information Management Applications. Personalization. Location-Based Services. Application Architecture. Architectural Frameworks. Systemic Qualities. Architectural Considerations for the Wireless Internet.



Appendix A.


References.


Glossary.


Index.

Preface

This book teaches you how to develop software for the Sun Microsystems J2ME platform. It follows a tutorial-style approach; it's not a reference manual. The aim is to give you a solid foundation in concepts and techniques that will enable you to venture off and develop quality applications independently.

Consistent with this approach, this book doesn't provide endless pages of API documentation; I leave that offering to the Sun Microsystems Java Software Web site, which maintains the latest and most accurate API documentation. The reader might find it useful, therefore, to have access to the official Java Software J2ME API documentation while reading this book, which can be found at http://java.sun.com/j2me/docs. You can either download the full API documentation or read it online. Additionally, Prentice-Hall publishes as part of its Java series a J2ME reference manual that compliments this book.

Also absent by design from this book are specific details of J2ME development tools offered by third-party vendors. In concert with the book's tutorial approach, I only introduce you to the Sun Microsystems J2ME Wireless Toolkit, which is the reference development toolkit for J2ME. It's available free of charge from Sun Microsystems at the Java Developer Connection Web site, which you must access by logging in. Follow the developer connection link from http://java.sun.com/. In this way, you can become familiar with a J2ME development environment and emulator and build and test real applications.

Device manufacturers often provide development tools of their own that are similar to Sun's J2ME Wireless Toolkit. Additionally, other third party software companies offer J2ME development tools. This book doesn't discuss those tools because they don't add anything to the concepts or pragmatics of how to design and develop J2ME applications.

This book also defines and discusses wireless application provisioning systems and covers application deployment and provisioning from a conceptual perspective, without becoming mired in the details of specific vendor offerings of provisioning server software. The notion of application deployment is more visible-and more critical-with J2ME than with other platforms such as J2SE. In fact, understanding deployment issues is a crucial element of the J2ME application development process.

Finally, I expose the reader to ideas surrounding application architecture. As we rely more heavily on computing devices that are continually becoming more pervasive, it becomes increasingly important for developers to think about reliability, performance, scalability, security, manageability, and so forth. This book gives you an introduction to these concepts and to the notion that developers must think about these characteristics from the outset.

Although this book introduces elements comprising the breadth of the J2ME platform, it focuses on the CLDC and MIDP, which support personal, mobile, independent devices-those with intermittent network connectivity, such as mobile phones. Programming examples and API discussions address this subset of the J2ME platform. The reason for this choice is that, as a J2ME developer, you will most likely be called upon to develop applications for this class of devices.

Book Content and Organization

The book is organized as follows:

  • Chapter 1: Introduction to the Java 2 Micro Edition (J2ME) Platform
  • Chapter 2: The MIDP Application Development Process
  • Chapter 3: MIDP Application Program Structure
  • Chapter 4: The MIDP High-Level API
  • Chapter 5: The MIDP UI Components
  • Chapter 6: The MIDP Low-Level API
  • Chapter 7: Persistent Storage Support in MIDP
  • Chapter 8: MIDP Networking and Communications
  • Chapter 9: Internationalization
  • Chapter 10: Application Provisioning
  • Chapter 11: The Wireless Internet Environment

Chapter 1 introduces you to the J2ME computing platform. It defines much of the J2ME terminology and gives you a general orientation to the concepts that surround the design and organization of the J2ME platform.

Chapter 2 describes the J2ME application development process. You learn how to create, compile, prepare, execute, and debug J2ME applications. This chapter doesn't cover the toolkit or APIs. Coverage of those items begins in Chapter 3.

Chapter 3 describes the J2ME MIDP platform from the software developer's point of view. Here you learn the organization of the APIs and the basic programming abstractions and models defined by the MIDP platform.

Chapter 4 continues where Chapter 3 left off. It covers the MIDP high-level API, which encompasses the bulk of the UI components defined by the MIDP. You learn how to manipulate the various UI components and also how to do event handling, called command processing in MIDP terminology.

Chapter 5 covers the MIDP user interface (UI) components. After learning the basic abstractions defined by the MIDP in Chapter 4, you're ready to learn how to use the components that are built upon those abstractions.

Chapter 6 covers the MIDP low-level API, which is implemented by the balance of the MIDP UI components not covered in Chapter 5.

Chapter 7 covers the persistent storage mechanisms available to you using the MIDP.

Chapter 8 is dedicated to networking and communications. Here you learn how to use the networking and distributed processing services and functionality defined by the CLDC and MIDP. You will also acquire some insight on the decisions for design and support of connectivity services in J2ME.

Chapter 9 gives you an introduction to internationalization. This is a topic of considerable breadth and depth that requires more than even a single, dedicated volume. Here, you'll learn about some of the issues that you'll encounter while building real-world MIDP applications. This chapter covers the extent of the internationalization support in the CLDC and MIDP and shows some examples of how to employ their features. You'll also learn how to configure your device environment to support internationalization and localization.

Chapter 10 covers application management and provisioning systems. Conceptual familiarity with these systems is important to the J2ME application developer, particularly MIDP developers, because these systems affect your interaction with application and content providers, wireless network carriers, and even end users.

Chapter 11 discusses the wireless Internet environment. It discusses the integration between wireless and fixed networks, the wireless Internet from the application developer's perspective, and the context in which applications execute. You'll get an introduction to wireless Internet gateways, Internet portal interfaces, and wireless application interfaces and services-all things that you're likely to encounter as a wireless application developer. This chapter also introduces basic architectural concepts and how they influence the J2ME application developer.

Audience

This book is intended for Java developers. It's suitable for professional software developers and advanced students alike. More precisely, this book expects the reader to be fluent with the Java programming language but doesn't assume programming experience with particular APIs beyond the core Java APIs. Notwithstanding a lack of experience in any particular area of Java programming beyond fluency with the language, it's helpful if readers have at least an understanding of the concepts and vernacular that surrounds various Java technologies, such as those terms related to virtual machines, garbage collection, class loading, class verification, native code interfaces, just-in-time compilation, AWT, RMI, JDK, JRE, and so forth.

I also assume, however, that the reader has a decent background in object-oriented programming. For this reason, I don't explain object-oriented concepts when they arise during the process of discussing the J2ME APIs, classes, programming idioms, and so forth.

Of course, the more experience the reader has, the better. Throughout the book, various references are made to AWT and Swing. A significant part of MIDP programming involves manipulating user-interface components. The reader with knowledge of AWT or Swing toolkit abstractions can quickly glean useful insights into the organization and abstractions of the MIDP's UI programming model. Notwithstanding the benefits of AWT and Swing experience, you don't need to have any previous background in Java UI development.

Where to Download J2ME

You can download the J2ME Wireless Toolkit and full API documentation by following the links to the Java Developer Connection from http://java.sun.com/. There, you'll find full API documentation for CDC, the Foundation Profile and the CLDC/MIDP, as well as the toolkit for all platforms such as Solaris, Linux, Windows NT, and Windows 2000.

Where to Find the Code Examples From This Book

All the code examples that you encounter in this book can be found on the Prentice-Hall Web site at http://www.phptr.com/piroumian/

Updates

Submit Errata

More Information

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.

Overview


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information


To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.

Surveys

Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.

Newsletters

If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information


Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.

Security


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.

Children


This site is not directed to children under the age of 13.

Marketing


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information


If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.

Choice/Opt-out


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information


Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents


California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure


Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.

Links


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact


Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice


We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020