Class SegmentOffsetTree

java.lang.Object
com.vladsch.flexmark.util.sequence.builder.tree.SegmentTree
com.vladsch.flexmark.util.sequence.builder.tree.SegmentOffsetTree

public class SegmentOffsetTree extends SegmentTree
Segment tree which uses offsets instead of aggregated length of segments

Used to find original base offsets in SegmentedSequence result

NOTE: although it is a SegmentTree, most of the SegmentTree functions use index into sequence for context and cannot be used with offset data. Their use will throw IllegalStateException if invoked.

  • Field Details

    • startIndices

      @NotNull protected final @org.jetbrains.annotations.NotNull int[] startIndices
  • Constructor Details

    • SegmentOffsetTree

      protected SegmentOffsetTree(@NotNull @org.jetbrains.annotations.NotNull int[] treeData, @NotNull @org.jetbrains.annotations.NotNull byte[] segmentBytes, @NotNull @org.jetbrains.annotations.NotNull int[] startIndices)
  • Method Details