Class CasAnnotationViewer.DefaultEntityResolver

java.lang.Object
org.apache.uima.tools.viewer.CasAnnotationViewer.DefaultEntityResolver
All Implemented Interfaces:
EntityResolver
Enclosing class:
CasAnnotationViewer

public class CasAnnotationViewer.DefaultEntityResolver extends Object implements EntityResolver
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.
  • Constructor Details

    • DefaultEntityResolver

      public DefaultEntityResolver()
  • Method Details

    • getEntity

      public EntityResolver.Entity getEntity(Annotation inAnnotation)
      Description copied from interface: EntityResolver
      Returns the Entity to which an annotation refers. Returns the canonical form String for an annotation.

      For two annotations that refer to the same Entity, this should return Entity objects that are equal.

      If the annotation does not represent an entity at all, null should be returned.

      Specified by:
      getEntity in interface EntityResolver
      Parameters:
      inAnnotation - the annotation to resolve
      Returns:
      the Entity to which the annotation refers, null if the annotation does not represent an