Skip to content

IdentifiedAnnotationBuilder

Sean Finan edited this page Feb 9, 2026 · 1 revision

final public class IdentifiedAnnotationBuilder

  • Author: SPF , chip-nlp
  • Version: %I%
  • Since: 9/26/2020

public IdentifiedAnnotationBuilder span( final int begin, final int end )

  • Parameters:
    • begin text span character index
    • end text span character index
  • Returns: this builder

public IdentifiedAnnotationBuilder span( final Pair<Integer> textSpan )

  • Parameters:
    • textSpan text span character indices
  • Returns: this builder

public IdentifiedAnnotationBuilder creator( final Function<JCas, ? extends IdentifiedAnnotation> creator )

Allow for creation of IdentifiedAnnotations outside those created/determined by Semantic Group

  • Parameters:
    • creator some IdentifiedAnnotation creation function, e.g.TimeAnnotation::new
  • Returns: this builder

public IdentifiedAnnotationBuilder group( final SemanticGroup semanticGroup )

  • Parameters:
    • semanticGroup for the annotation
  • Returns: this builder

public IdentifiedAnnotationBuilder group( final String semanticGroup )

  • Parameters:
    • semanticGroup name for the annotation
  • Returns: this builder

public IdentifiedAnnotationBuilder type( final SemanticTui semanticType )

  • Parameters:
    • semanticType for the annotation
  • Returns: this builder

public IdentifiedAnnotationBuilder type( final String semanticType )

  • Parameters:
    • semanticType name for the annotation
  • Returns: this builder

public IdentifiedAnnotationBuilder tui( final int tui )

  • Parameters:
    • tui representing the primary semantic type.
  • Returns: this builder

public IdentifiedAnnotationBuilder tui( final String tui )

  • Parameters:
    • tui representing the primary semantic type.
  • Returns: this builder

@Deprecated public IdentifiedAnnotationBuilder cui( final String cui )

  • Parameters:
    • cui concept unique identifier
  • Returns: this builder
  • Deprecated

@Deprecated public IdentifiedAnnotationBuilder preferredText( final String text )

  • Parameters:
    • text preferred
  • Returns: this builder
  • Deprecated

@Deprecated public IdentifiedAnnotationBuilder addSchemaCode( final String schema, final String code )

Can be used multiple times

  • Parameters:
    • schema name of an encoding schema. e.g. SNOMEDCT_US
    • code code for this annotation in that schema
  • Returns: this builder
  • Deprecated

static private boolean isSpanValid( final Pair<Integer> textSpan, final int docLength )

  • Parameters:
    • textSpan -
    • docLength -
  • Returns: false if the span is unspecified, reversed, or outside the document text.

public IdentifiedAnnotation put( final JCas jcas )

Builds the IdentifiedAnnotation and stores it in the jCas. The same as .build( jcas )

  • Parameters:
    • jcas ye olde ...
  • Returns: an IdentifiedAnnotation with properties specified or null if the cui or span are illegal.

public IdentifiedAnnotation build( final JCas jcas )

Builds the IdentifiedAnnotation and stores it in the jCas. The same as .put( jcas )

  • Parameters:
    • jcas ye olde ...
  • Returns: an IdentifiedAnnotation with properties specified or null if the cui or span are illegal.

Apache cTAKES

ctakes-core API

Python API

ctakes-core

patient
    AbstractPatientConsumer
    AbstractPatientFileWriter
    PatientNoteCollector
    PatientNoteStore
    PatientViewUtil
pipeline
    PipeBitLocator
    PipelineBuilder
    PiperFileReader
    PiperFileRunner
resource
    FileLocator
util
    CalendarUtil
    MutableUimaContext
    NumberedSuffixComparator
    Pair
    RelationArgumentUtil
    StringUtil
     annotation
         ConceptBuilder
         EssentialAnnotationUtil
         IdentifiedAnnotationBuilder
         IdentifiedAnnotationUtil
         OntologyConceptUtil
         SemanticGroup
         SemanticTui
     doc
         DocIdUtil
         JCasBuilder
         TextBySectionBuilder
         TextBySentenceBuilder
     log
         DotLogger
         FinishedLogger
     regex
         RegexSpanFinder
         TimeoutMatcher
     textspan
         DefaultAspanComparator
         DefaultTextSpanComparator
         DefaultTextSpan
         TextSpan



General

Clone this wiki locally