public class DbpediaVerifier extends DbpediaAccessor implements EntityVerifier
Constructor and Description |
---|
DbpediaVerifier() |
Modifier and Type | Method and Description |
---|---|
EntityType |
determineType(java.lang.String term)
Determine the entity type for a particular term.
|
java.lang.String |
getModel()
Get the model string for this verifier.
|
java.util.Set<EntityType> |
getSupportedTypes()
Return the list of types this verifier can verify.
|
java.lang.String |
normalize(java.lang.String term,
EntityType type)
Normalize the term to its standard form.
|
void |
setModel(java.lang.String model)
Set the model for this accessor.
|
boolean |
verifyType(java.lang.String term,
EntityType type)
Verify that the term matches the type.
|
queryResource, queryResource, retrieveRecords, setInitParameters, setLanguage, setQuery
addFieldHandler, addToGraph, addToTree, createReferenceNode, extendGraph, extendTree, getDataset, getFieldHandler, getGraph, getGrid, getMaxRecords, getReasoner, getStructureReasoners, getTree, setMaxRecords, setReasoner, setReasoner
addStructure, addTemplate, getDatasetNames, getGraphNames, getGridNames, getSpec, getStructureType, getTemplate, getTemplateNames, getTreeNames, setConfig, setConfigFile, setConfigFile
public EntityType determineType(java.lang.String term)
determineType
in interface EntityVerifier
term
- the term to check. This is the extracted entitypublic java.lang.String getModel()
getModel
in interface EntityVerifier
public java.util.Set<EntityType> getSupportedTypes()
getSupportedTypes
in interface EntityVerifier
public java.lang.String normalize(java.lang.String term, EntityType type)
normalize
in interface EntityVerifier
term
- the term to normalizetype
- the entity type. Currently ignoredpublic void setModel(java.lang.String model)
setModel
in interface EntityVerifier
model
- the model for this verifierpublic boolean verifyType(java.lang.String term, EntityType type)
determineType
to query
DBPedia for the type, then determines if the returned type matches the
requested type.verifyType
in interface EntityVerifier
term
- the term to check. This is the extracted entitytype
- the type to check against.