PDA

View Full Version : What is fasteset to use?



TheBuzzer
13 Aug 2009, 1:54 PM
I am wondering what type of stuff is fastest to use to code such as vector or arraylist or linkedlist.

And for maps such as treemap or basemodeldata?

I tend to use vector and treemap but I am wondering are those slow and I should be using other type of list and maps?

Arno.Nyhm
14 Aug 2009, 8:00 AM
see also here:

GWT HashMap: FastStringMap No More
http://development.lombardi.com/?p=797

sven
14 Aug 2009, 8:55 AM
GXT includes FastMap and FastSet.

TheBuzzer
14 Aug 2009, 10:39 AM
So there is no FastList ?

Set does not keep order if i remeber

TheBuzzer
14 Aug 2009, 1:08 PM
GXT includes FastMap and FastSet.


I changed all my treemap to fastmap.

I not sure if I can change vectors into fastset.

FastSet seems to only allow strings and not anything else.

sven
14 Aug 2009, 1:12 PM
So there is no FastList ?

Set does not keep order if i remeber


There is no need for a fastlist. Using arraylist is already fast.

TheBuzzer
14 Aug 2009, 1:25 PM
There is no need for a fastlist. Using arraylist is already fast.

how about vector? is that the same as arraylist or is there a speed difference?

Well I just looked what what you used in the gxt lib. It seems like you liek to use ArrayList so I guessing ArrayList is the choice to use.

googelybear
19 Aug 2009, 11:33 AM
Vector in regular java is synchronized and therefore slower than ArrayList. Same for StringBuffer (synched) and StringBuilder (faster). Don't know about how this effects the compiled javasript code.

TheBuzzer
19 Aug 2009, 12:31 PM
Nm nether thats why I asked but it seems like ext js uses arraylist and not vectors so I changed my code to use arraylist