Gee, isn't thread safty an issue with Struts?  I
thought I should use synchronized Objects in my
Actions.

Yes, Struts Actions should be thread safe. The approach I suggested is the best practice for creating synchronized Lists.


David


--- David Graham <[EMAIL PROTECTED]> wrote: > Vector was a poorly designed class that has been > replaced by ArrayList. New > code should not use Vector. If you need a > synchronized list do this > instead: > > List myList = Collections.synchronizedList(new > ArrayList()); > > David > > >Without checking the archives for specific > references, > >I'm still sure I've read on multiple occasions, > "Don't > >use Vectors, use ArrayLists". I was under the > >impression that this was because Vectors are not > >synchronized. After refactoring, today, I read > here > >that ArrayLists are not synchronized: > > > >http://java.sun.com/j2se/1.4.1/docs/api/java/util/ArrayList.html > > > >Time to refactor again? I need to be using one of > the > >static Collections.synchronized* methods, right? > >Beyond using Objects that are synchronized, what > >difference does it make which implementation of > >Collection I choose? > > > >m > > > > > >__________________________________ > >Do you Yahoo!? > >Yahoo! Calendar - Free online calendar with sync to > Outlook(TM). > >http://calendar.yahoo.com > > > >--------------------------------------------------------------------- > >To unsubscribe, e-mail: > [EMAIL PROTECTED] > >For additional commands, e-mail: > [EMAIL PROTECTED] > > > > _________________________________________________________________ > Protect your PC - get McAfee.com VirusScan Online > http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] >


__________________________________ Do you Yahoo!? Yahoo! Calendar - Free online calendar with sync to Outlook(TM). http://calendar.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


_________________________________________________________________
Add photos to your messages with MSN 8. Get 2 months FREE*. http://join.msn.com/?page=features/featuredemail



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to