jcolibri.method.maintenance
Class CaseResult
java.lang.Object
jcolibri.method.maintenance.QueryResult
jcolibri.method.maintenance.CaseResult
- All Implemented Interfaces:
- java.lang.Comparable
public class CaseResult
- extends QueryResult
- implements java.lang.Comparable
Stores the case result information. It contains a pair.
The result is some double value related to the case.
- Author:
- Lisa Cummins
Method Summary |
CBRCase |
getCase()
Returns the case. |
static java.util.List |
sortResults(boolean ascending,
java.util.List<CaseResult> toSort)
Sorts the given list of CaseResults in the given order and
returns the sorted list. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.lang.Comparable |
compareTo |
CaseResult
public CaseResult(CBRCase _case,
double result)
- Sets up a pair.
- Parameters:
_case
- The case to be storedresult
- The result associated with this case.
getCase
public CBRCase getCase()
- Returns the case.
- Overrides:
getCase
in class QueryResult
- Returns:
- the case.
sortResults
public static java.util.List sortResults(boolean ascending,
java.util.List<CaseResult> toSort)
- Sorts the given list of CaseResults in the given order and
returns the sorted list.
- Parameters:
ascending
- The order in which to sort the elements.toSort
- The list of CaseResults to sort.
- Returns:
- the sorted list.