posted 14 years ago
Hello, everybody.
I'm a beginner of JavaME. Recently, I studied "Beginning J2ME platform: From Novice to Professional" this book.
There is a paragraph at page 56.
You may be tempted to call getDisplay() in a MIDlet's constructor, but according to the specification,
getDisplay() can only be called after the beginning of the MIDlet's startApp() method.
If you try to call it before startApp() is called, your MIDlet may throw an exception and terminate before starting!
Is it true?
I had tried to call getDisplay() method in MIDlet's constructor. But there is no any exception or error occure.
Could someone explain it ?
Thanks!!