Uploaded image for project: 'UIMA'
  1. UIMA
  2. UIMA-6284

select.following() fails to find adjacent annotations

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.1.1SDK
    • 3.2.0SDK
    • Core Java Framework
    • None

    Description

      Select following(x) fails to return an annotation which starts at the end position of x - or otherwise said, the test below fails.

        @Test
        public void thatSelectFollowingReturnsAdjacentAnnotation()
        {
          Annotation a1 = cas.createAnnotation(cas.getCasType(Sentence.class), 10, 20);
          Annotation a2 = cas.createAnnotation(cas.getCasType(Sentence.class), 20, 30);
          
          asList(a1, a2).forEach(cas::addFsToIndexes);
          
          List<Annotation> selection = cas.<Annotation>select(cas.getCasType(Sentence.class))
              .following(a1)
              .asList();
          
          assertThat(selection)
                  .containsExactly(a2);
        }
      

      Attachments

        Issue Links

          Activity

            People

              rec Richard Eckart de Castilho
              rec Richard Eckart de Castilho
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: