swappable data structures for arraylist, linkedlist, set and hashmap