Hi, >From my understand, ArrayList or LinkedList imlementation is an unsynronized collection. This means, if there's multiple thread trying to update this list, it will cause concurent modification exception. In this case, it appears that the way to workaround it is to use the Collection.synchronized method to create the collection. This will force the List implemnetation to be thread safe. Or the other way is to do a synchornized block in the requester to force a thread safe.
So the existing implementation of ArrayList or LinkedList should be used if there's only single thread to access the list. If there's multiple thread which will access the list, it should wrapped the collection with collection.synchronization? Is my understanding correct? Thx. Lawrence -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en
