public class ClassificationResult<T> extends Object implements Comparable<ClassificationResult<T>>
Classifier.assignClass(String)
holding an assigned class of type T
and a score.Constructor and Description |
---|
ClassificationResult(T assignedClass,
double score)
Constructor
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(ClassificationResult<T> o) |
T |
getAssignedClass()
retrieve the result class
|
double |
getScore()
retrieve the result score
|
public ClassificationResult(T assignedClass, double score)
assignedClass
- the class T
assigned by a Classifier
score
- the score for the assignedClass as a double
public T getAssignedClass()
T
representing an assigned classpublic double getScore()
double
representing a result scorepublic int compareTo(ClassificationResult<T> o)
compareTo
in interface Comparable<ClassificationResult<T>>
Copyright © 2000-2017 Apache Software Foundation. All Rights Reserved.