e martë, 12 qershor 2007

Synchronize a list.

String [] str = new String("A", "B", "C", "D");
List list = Arrays.asList(str);

// sort the list
Collections.sort(list);

// synchronize the list
list = (List)Collections.synchronizedList(list);

Nuk ka komente: