Java tutorial
//package com.java2s; import java.util.ArrayList; import java.util.Iterator; import java.util.Set; public class Main { /** * Parse Set to ArrayList * * @param set * @return ArrayList */ public static <T> ArrayList<T> setToArrayList(Set<T> set) { if (set == null) return null; ArrayList<T> tArray = new ArrayList<T>(); Iterator<T> it = set.iterator(); while (it.hasNext()) { T t = it.next(); tArray.add(t); } return tArray; } }