Your SlideShare is downloading. ×
0
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
02 cldc
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

02 cldc

715

Published on

J2ME CLDC

J2ME CLDC

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
715
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
8
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. CLDCConnected, Limited Device Configuration Cornelius Koo - 2005
  • 2. CLDC Devices Characteristics• 160 - 512 kb total memory available for java platform• 16 bit / 32 bit processor• low power consumption, often battery powered• intermitten network connectivity (often wireless), limited bandwith
  • 3. Hardware Requirements• CLDC doesnt have specific hardware requirements• Minimal memory requirements :• 128 kb - for running the JVM and CLDC libraries. This memory must preserve its content, even when the device is powered off. (Nonvolatile memory)• 32 kb - available during application runtime for allocation of objects. (Volatile memory / heap)
  • 4. Software Requirements• The Operating System must be able to running JVM and managing Java applications on the device including : Select and launch application Remove application
  • 5. JVM Specification for CLDC
  • 6. Java Language for CLDC• CLDC doesn’t support floating point type. (double and float)• CLDC doesn’t support finalize() method.• CLDC only support limited set of Exception classes for error handling.
  • 7. Java Virtual Machine for CLDC• JVM doesn’t support floating point operation.• JVM doesn’t support native interface and native method invocation.• Reflection is not available.• JVM must implement the classloader.• finalize() method is not available.• JVM doesn’t suport ThreadGroup class.• JVM doesn’t support weak references.
  • 8. Weak References• Garbage collector recognizes that an object is being referenced, yet the object is still a candidate for garbage collection.
  • 9. Security Handling• Any devices running Java application will need protection from malicious codes that may access system information or resources.• This “Low Level” protection is implemented through class file verification.
  • 10. CLDC Class File Verification• Class file verification is done in 2 steps in CLDC.• 1st Step is pre-verification.• 2nd Step is in-device verification.
  • 11. Pre-Verification• Pre-verification :• A software program is run to insert additional attributes into the class file.• Class file will be approximately 5% larger after pre-verification.• Done as part of development process or before a class file is loaded on a device.• A "Stack Maps" is added to the class file, describing what variables and operands are art of the interpreter stack space.
  • 12. In-Device Verification• In-Device verification :• Once a device loads a pre-verified class file, the in-device verifier runs through each instruction.• There are several checks done to validate the code.• At any point the verifier can report and reject the class file.• Code verifier program for KVM is in the range of 10kb and less than 100 bytes of heap space required.
  • 13. CLDC Package
  • 14. Java Classes
  • 15. System Classes• java.lang.Class• java.lang.Object• java.lang.Runnable• java.lang.Runtime• java.lang.String• java.lang.StringBuffer• java.lang.System• java.lang.Thread• java.lang.Throwable
  • 16. Data Type Classes• java.lang.Boolean• java.lang.Byte• java.lang.Character• java.lang.Integer• java.lang.Long• java.lang.Short
  • 17. Collection Classes• java.util.Enumeration• java.util.Hashtable• java.util.Stack• java.util.Vector
  • 18. I/O Classes• java.io.ByteArrayInputStream• java.io.ByteArrayOutputStream• java.io.DataInput• java.io.DataInputStream• java.io.DataOutput• java.io.DataOutputStream• java.io.InputStream• java.io.InputStreamReader• java.io.OutputStream• java.io.OutputStreamWriter• java.io.PrintStream• java.io.Reader• java.io.Writer
  • 19. Calendar and Time Classes• java,util.Calendar• java.util.Date• java.util.TimeZone
  • 20. Utility Classes• java.util.Math• java.util.Random
  • 21. Exception Classes• java.io.EOFException• java.io.InterruptedIOException• java.io.IOException• java.io.UnsupportedEncodingException• java.io.UTFDataFormatException• java.lang.ArithmeticException• java.lang.ArrayIndexOutOfBoundsException• java.lang.ArrayStoreException• java.lang.ClassCastException• java.lang.ClassNotFoundException• java.lang.Exception• java.lang.IllegalAccessException• java.lang.IllegalArgumentException
  • 22. Exception Classes• java.lang.IllegalMonitorStateException• java.lang.IllegalThreadStateException• java.lang.IndexOutOfBoundsException• java.lang.InstantiationException• java.lang.InterruptedException• java.lang.NegativeArraySizeException• java.lang.NullPointerException• java.lang.NumberFormatException• java.lang.RuntimeException• java.lang.SecurityException• java.lang.StringIndexOutOfBoundsException• java.util.EmptyStackException• java.util.NoSuchElementException
  • 23. Error Classes• java.lang.Error• java.lang.OutOfMemoryError• java.lang.VirtualMachineError
  • 24. Internationalization• java.io.InputStreamReader• java.io.OutputStreamWriter• both can be used to convert from bytes to/from unicode.
  • 25. Reference• Core J2ME Technology and MIDP. John W. Muchow. Prentice Hall PTR, 2002.• Enterprise J2ME: Developing Mobile Java Applications. Michael Juntao Yuan. Prentice Hall PTR, 2003.• J2ME in A Nutshell. Kim Topley. Oreilly, 2002.• Wireless J2ME Platform Programming. Vartan Piroumian. Prentice Hall, 2002.

×