congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
AlignedString.resolve
Code IndexAdd Tabnine to your IDE (free)

How to use
resolve
method
in
de.tudarmstadt.ukp.dkpro.core.api.transform.alignment.AlignedString

Best Java code snippets using de.tudarmstadt.ukp.dkpro.core.api.transform.alignment.AlignedString.resolve (Showing top 2 results out of 315)

origin: de.tudarmstadt.ukp.dkpro.core/de.tudarmstadt.ukp.dkpro.core.castransformation-asl

  private void updateOffsets(CAS sourceView, JCas targetView, AlignedString as, 
      PositiveIntSet aCopiedFs)
    throws CASException, AnalysisEngineProcessException
  {
    // We only update annotations that were copied, nothing that was already there.
    IntListIterator it = aCopiedFs.iterator();
    
    while (it.hasNext()) {
      FeatureStructure fs = targetView.getLowLevelCas().ll_getFSForRef(it.next());
      if (fs instanceof Annotation) {

        // Now we update the offsets
        Annotation a = (Annotation) fs;
//            System.out.printf("Orig   %s %3d %3d : %s%n", a.getType().getShortName(),
//                    a.getBegin(), a.getEnd(),
//                    sourceView.getDocumentText().substring(a.getBegin(), a.getEnd()));
//            System.out.printf("Before %s %3d %3d : %s%n", a.getType().getShortName(),
//                    a.getBegin(), a.getEnd(), a.getCoveredText());
        Interval resolved = as.resolve(new ImmutableInterval(a.getBegin(), a.getEnd()));
        a.setBegin(resolved.getStart());
        a.setEnd(resolved.getEnd());
//            System.out.printf("After  %s %3d %3d : %s%n", a.getType().getShortName(),
//                    a.getBegin(), a.getEnd(), a.getCoveredText());
      }
    }
  }
}
origin: dkpro/dkpro-core

final Interval ulpos = resolve(new ImmutableInterval(seg.getStart(), seg.getEnd()));
de.tudarmstadt.ukp.dkpro.core.api.transform.alignmentAlignedStringresolve

Javadoc

For the given interval on the current data, get the corresponding interval in the wrapped data.

Popular methods of AlignedString

  • <init>
  • delete
  • insert
  • replace
  • get
    Fetch data
  • addChangeListener
  • createBase
  • dataSegmentsToString
    Create a string representation of the segments. This is for debugging purposes.
  • dropSuperflourous
    If the given segment is a zero-length base segment, then it can be dropped. Zero-length oblique segm
  • fireChange
  • getAnchor
    Get an anchor at the specified position. Breaks up the segment at the given point if necessary. If t
  • getFirst
  • getAnchor,
  • getFirst,
  • getSegmentAt,
  • inverseResolve,
  • length,
  • updateCaches

Popular in Java

  • Reactive rest calls using spring rest template
  • compareTo (BigDecimal)
  • onCreateOptionsMenu (Activity)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • HashMap (java.util)
    HashMap is an implementation of Map. All optional operations are supported.All elements are permitte
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Stream (java.util.stream)
    A sequence of elements supporting sequential and parallel aggregate operations. The following exampl
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • PhpStorm for WordPress
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now