public class DialogFlowEntityMapper extends EntityMapper
EntityMapper initialized with DialogFlow's system entities.
This class provides a mapping of EntityTypes to DialogFlow's system entities. Mapped
entities can be accessed by calling EntityMapper.getMappingFor(EntityDefinition).
entities, FALLBACK_ENTITY_KEY| Constructor and Description |
|---|
DialogFlowEntityMapper()
Constructs a
DialogFlowEntityMapper initialized with DialogFlow's system entities. |
| Modifier and Type | Method and Description |
|---|---|
void |
addCustomEntityMapping(com.xatkit.intent.CustomEntityDefinition entityDefinition,
String concreteEntity)
This method is disabled for
DialogFlowEntityMapper. |
protected String |
getMappingForCustomEntity(com.xatkit.intent.CustomEntityDefinition customEntityDefinition)
Maps the provided
customEntityDefinition to its DialogFlow implementation. |
addEntityMapping, addEntityMapping, getMappingFor, getMappingFor, removeMappingFor, setFallbackEntityMappingpublic DialogFlowEntityMapper()
DialogFlowEntityMapper initialized with DialogFlow's system entities.public void addCustomEntityMapping(com.xatkit.intent.CustomEntityDefinition entityDefinition,
String concreteEntity)
DialogFlowEntityMapper.
DialogFlow entities are registered independently from the intents. This two-step process allows to reference
entities with their names, and do not require to store any mapping information in the
DialogFlowEntityMapper.
addCustomEntityMapping in class EntityMapperentityDefinition - the CustomEntityDefinition to mapconcreteEntity - the mapped value associated to the provided entityDefinitionEntityMapper.getMappingFor(EntityDefinition)protected String getMappingForCustomEntity(com.xatkit.intent.CustomEntityDefinition customEntityDefinition)
customEntityDefinition to its DialogFlow implementation.
DialogFlow entities are registered independently from the intents. This two-step process allows to reference
entities with their names, and do not require to store any mapping information in the
DialogFlowEntityMapper.
getMappingForCustomEntity in class EntityMappercustomEntityDefinition - the CustomEntityDefinition to retrieve the concrete entity
String fromString identifying the DialogFlow entity corresponding to the provided customEntityDefinitionCopyright © 2020 SOM Research Lab. All rights reserved.