What is the startApp() method?

November 26th, 2006 by uCertify Leave a reply »

The startApp() method is used to notify the MIDlet that it has entered in the Active state. In this state, it can hold resources. This method will only be called when the MIDlet is in the Paused state. The following is the general form of the method:

protected abstract void startApp()
throws MIDletStateChangeException

It is possible that the startApp() method cannot start the MIDlet. It can happen due to the following two reasons:

  • Transient: To avoid this, the MIDletStateChangeException must be thrown.
  • Non-transient: To avoid this, notifyDestroyed() method should be used.
  • The MIDletStateChangeException is thrown if the MIDlet cannot start immediately, but it can start after some time. If any runtime exception occurs during the process of startApp() method, the MIDlet will be destroyed immediately.

    Become SUN SCJA certified. Click here to download CX310-019 test study guide and practice question.
    • Share/Bookmark
    Advertisement

    Leave a Reply

    uCertify.com | Our Company | Articles | Contact Us | News and Press Release | uCertify India | Entries (RSS)
    MCSE: MCSA, MCTS, MCITP    JAVA Certification: SCJP, SCWCD    Cisco Certification: CCNA, CCENT    A+, Network+, Security+ Project+
    Oracle Certification: OCP 11g, OCP 10g, OCA 11g, OCA 10g    CIW foundation    EC-212-32,    CISSP    Photoshop ACE CS4    Adobe Flash ACE, PMP, CAPM
    © 2008 uCertify.com. All rights reserved. All trademarks are the property of their respective owners.