Package org.apache.uima.tools.viewer
Class CasAnnotationViewer.DefaultEntityResolver
java.lang.Object
org.apache.uima.tools.viewer.CasAnnotationViewer.DefaultEntityResolver
- All Implemented Interfaces:
EntityResolver
- Enclosing class:
- CasAnnotationViewer
Trivial entity resolver that's applied if the user turns on entity mode without specifying
their own entity resolver. Returns the covered text as the canonical form, and treats
annotations with equal covered text as belonging to the same entity.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.uima.tools.viewer.EntityResolver
EntityResolver.Entity -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetEntity(Annotation inAnnotation) Returns theEntityto which an annotation refers.
-
Constructor Details
-
DefaultEntityResolver
public DefaultEntityResolver()
-
-
Method Details
-
getEntity
Description copied from interface:EntityResolverReturns theEntityto which an annotation refers. Returns the canonical form String for an annotation.For two annotations that refer to the same Entity, this should return
Entityobjects that areequal.If the annotation does not represent an entity at all,
nullshould be returned.- Specified by:
getEntityin interfaceEntityResolver- Parameters:
inAnnotation- the annotation to resolve- Returns:
- the Entity to which the annotation refers, null if the annotation does not represent an
-