edu.illinois.cs.cogcomp.lbj.coref.ir.solutions
Class ListSolution<T>

java.lang.Object
  extended by edu.illinois.cs.cogcomp.lbj.coref.ir.solutions.ListSolution<T>
All Implemented Interfaces:
Solution, java.io.Serializable
Direct Known Subclasses:
MentionSolution

public class ListSolution<T>
extends java.lang.Object
implements Solution, java.io.Serializable

A solution containing a set of objects of some type T

Author:
Eric Bengtson
See Also:
Serialized Form

Field Summary
private  java.util.List<T> m_items
           
private static long serialVersionUID
           
 
Constructor Summary
ListSolution()
          Constructs an empty ListSolution.
ListSolution(java.util.Collection<T> items)
          Constructs a solution containing items as a list.
 
Method Summary
 java.util.List<T> getItems()
          Gets the items.
 java.lang.String toString()
          Get a string representation of the items.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

m_items

private java.util.List<T> m_items
Constructor Detail

ListSolution

public ListSolution()
Constructs an empty ListSolution.


ListSolution

public ListSolution(java.util.Collection<T> items)
Constructs a solution containing items as a list.

Parameters:
items - The items (copied defensively into a list).
Method Detail

getItems

public java.util.List<T> getItems()
Gets the items.

Returns:
An unmodifiable view of the items.

toString

public java.lang.String toString()
Get a string representation of the items.

Overrides:
toString in class java.lang.Object