View Javadoc
1   package org.kuali.common.util.xml.jaxb.wrapper;
2   
3   import java.util.Collection;
4   
5   import javax.xml.bind.annotation.XmlAnyElement;
6   
7   import org.kuali.common.util.Assert;
8   
9   import com.google.common.collect.Lists;
10  
11  public class CollectionWrapper<T> {
12  
13  	@XmlAnyElement(lax = true)
14  	private final Collection<T> collection;
15  
16  	@SuppressWarnings("unused")
17  	private CollectionWrapper() {
18  		this(Lists.<T> newArrayList());
19  	}
20  
21  	public CollectionWrapper(Collection<T> collection) {
22  		Assert.noNulls(collection);
23  		this.collection = collection;
24  	}
25  
26  	public Collection<T> getCollection() {
27  		return collection;
28  	}
29  
30  }