public final class Slot extends Object
Some NLU services allow user-specified types. If present, the
user-specified type can be accessed via the type
field, and the
runtime type can be accessed by calling getClass()
on the slot's
value
.
Constructor and Description |
---|
Slot(String n,
String original,
Object parsed)
Create a new slot.
|
Slot(String n,
String userType,
String original,
Object parsed)
Create a new slot with a user-specified type.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
String |
getName() |
String |
getRawValue() |
String |
getType() |
Object |
getValue() |
int |
hashCode() |
String |
toString() |
public Slot(String n, String original, Object parsed)
n
- The slot's name.original
- The slot's original string value.parsed
- The slot's parsed value.public String getName()
public String getType()
public String getRawValue()
public Object getValue()
Copyright © 2021. All rights reserved.