File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java Micro Edition and the fly likes map,Hashmap and synchronized Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "map,Hashmap and synchronized" Watch "map,Hashmap and synchronized" New topic
Author

map,Hashmap and synchronized

kumar Reddy
Greenhorn

Joined: Nov 24, 2004
Posts: 29
hi
I am new to j2me technology

I would like to know whetehr j2me supports Map and HashMap classes and synchronized keyword..

i have a small doubt.
what i think regardign j2me is that it comprises of few packages of j2se and aditional optional packages for specific devices?

i would like to know what are these set of packages of j2se that are in j2me..where can i find this information..please help me in this regard

seesm to be silly, but i could not understand
Thank you
Tomas Conway
Ranch Hand

Joined: Nov 02, 2004
Posts: 45
Map: no
HashMap: no
synchronized: yes

The only Collection style classes are Vector, Stack and Hashtable.



That's it bascially, except that there are also differences between the packages and classes that are common to both. E.g. both J2SE and J2ME have a java.lang.String class, but the J2ME version doesn't have all the methods that J2SE has.
kumar Reddy
Greenhorn

Joined: Nov 24, 2004
Posts: 29
hi
thanks for ur reply..meanwhile i was browsing for information regarding this topic and i have found something interesting which is located at

http://java.sun.com/products/cdc/api.html

from the fig in this page its said that
CDC supports the entire package java.util(which has map and hashmap) just like j2se.

so what i understand is that they must be vaild in CDC environoment.please correct me if i am wrong.

thank you
Tomas Conway
Ranch Hand

Joined: Nov 02, 2004
Posts: 45
Pardon me, I was assuming CLDC not CDC.

Yes, CDC has a much less restricted subset of J2SE, and does indeed include Map and HashMap.

You can find the API for CDC here.
kumar Reddy
Greenhorn

Joined: Nov 24, 2004
Posts: 29
hi tomas

anyhow thank you for your replies..
and also forgivng a link to api of cdc.

and do u know something that CDC have JVMPI from cdc1.0.1 any idea?

thank you
Alexander Traud
Greenhorn

Joined: Jul 07, 2004
Posts: 16
Although it is CDC here, but if you do CLDC and really, really need the Collection package: Sun InfoBus.
This gives the Collection API. Never tried in J2ME but it should work if you have enough heap.
[ November 27, 2004: Message edited by: Alexander Traud ]
Tomas Conway
Ranch Hand

Joined: Nov 02, 2004
Posts: 45


That package extends J2SE classes that are not included in J2ME. In any case packages cannot be installed unless they are part of the your code in the first place. I.e. you would need the full source, and it would have to be entirely in Java (no native code).
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: map,Hashmap and synchronized
 
Similar Threads
Util
Encryption with Midlet
synchroniztion of map
J2ME - highlevel overview
concurrent access to HashMap