Class CollectionItem
java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.watson.natural_language_classifier.v1.model.CollectionItem
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
public class CollectionItem
extends com.ibm.cloud.sdk.core.service.model.GenericModel
Response from the classifier for a phrase in a collection.
-
Constructor Summary
Constructors Constructor Description CollectionItem()
-
Method Summary
Modifier and Type Method Description List<ClassifiedClass>
getClasses()
Gets the classes.String
getText()
Gets the text.String
getTopClass()
Gets the topClass.Methods inherited from class com.ibm.cloud.sdk.core.service.model.GenericModel
equals, hashCode, toString
-
Constructor Details
-
CollectionItem
public CollectionItem()
-
-
Method Details
-
getText
Gets the text.The submitted phrase. The maximum length is 2048 characters.
- Returns:
- the text
-
getTopClass
Gets the topClass.The class with the highest confidence.
- Returns:
- the topClass
-
getClasses
Gets the classes.An array of up to ten class-confidence pairs sorted in descending order of confidence.
- Returns:
- the classes
-