/**
 * $Id: ListUtil.java 1152 2015-11-04 01:28:31Z zhangzhongzhong $
 * Copyright(C) 2014-2020 netease - easegame, All Rights Reserved.
 */
package com.liquidnet.commons.lang.util;

import java.util.List;

/**
 *
 * @author <a href="mailto:362639875@qq.com">zhangzhongzhong</a>
 * @version 1.0 2015年11月4日 上午9:24:53
 */
public class ListUtil {

	@SuppressWarnings("unchecked")
	public static <T> List<T> copy(List<T> src){
		List<T> dest;
		try {
			dest = (List<T>) SerializableUtil.unserialize(SerializableUtil.serialize(src));
		} catch (Exception e) {
			throw new RuntimeException("List copy err:", e);
		}
		return dest;
	}
}
