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.
| Modifier and Type | Field and Description |
|---|---|
| protected final @NotNull int[] |
| Access | Constructor and Description |
|---|---|
| protected | SegmentOffsetTree(@NotNull int[] treeData, @NotNull byte[] segmentBytes, @NotNull int[] startIndices)
|
| startIndices | back to summary |
|---|---|
| protected final @NotNull int[] startIndices
| |
| SegmentOffsetTree | back to summary |
|---|---|
| protected SegmentOffsetTree(@NotNull int[] treeData, @NotNull byte[] segmentBytes, @NotNull int[] startIndices) | |
| addSegments | back to summary |
|---|---|
| public void addSegments(@NotNull IBasedSegmentBuilder<?> builder, @NotNull SegmentTreeRange treeRange)
Deprecated
| |
| addSegments | back to summary |
|---|---|
| public void addSegments(@NotNull IBasedSegmentBuilder<?> builder, int startIndex, int endIndex, int startOffset, int endOffset, int startPos, int endPos)
Deprecated
| |
| aggrLength | back to summary |
|---|---|
| public int aggrLength(int pos) Overrides com. Deprecated
| |
| build | back to summary |
|---|---|
public static @NotNull SegmentOffsetTree build(@NotNull Iterable<Seg> segments, @NotNull CharSequence allText)
| |
| build | back to summary |
|---|---|
public static @NotNull SegmentOffsetTree build(@NotNull BasedSegmentBuilder builder)
| |
| build | back to summary |
|---|---|
public static @NotNull SegmentOffsetTree build(@NotNull BasedSequence baseSeq)
| |
| endOffset | back to summary |
|---|---|
| public int endOffset(int pos) | |
| findSegment | back to summary |
|---|---|
| public @Nullable Segment findSegment(int index, @NotNull BasedSequence baseSeq, @Nullable Segment hint)
Deprecated
| |
| findSegment | back to summary |
|---|---|
| public @Nullable Segment findSegment(int index, int startPos, int endPos, @NotNull BasedSequence baseSeq, @Nullable Segment hint)
Deprecated
| |
| findSegmentByOffset | back to summary |
|---|---|
public @Nullable Segment findSegmentByOffset(int offset, @NotNull BasedSequence baseSeq, @Nullable Segment hint)
| |
| findSegmentPos | back to summary |
|---|---|
| public @Nullable SegmentTreePos findSegmentPos(int index) Overrides com. Deprecated
| |
| findSegmentPos | back to summary |
|---|---|
| public @Nullable SegmentTreePos findSegmentPos(int index, int startPos, int endPos) Overrides com. Deprecated
| |
| findSegmentPosByOffset | back to summary |
|---|---|
public @Nullable SegmentTreePos findSegmentPosByOffset(int offset)
| |
| getNextText | back to summary |
|---|---|
public @Nullable Segment getNextText(@NotNull Segment segment, @NotNull BasedSequence baseSeq)
| |
| getPrevAnchor | back to summary |
|---|---|
| public @Nullable Segment getPrevAnchor(int pos, @NotNull BasedSequence baseSeq)
Deprecated
| |
| getPreviousText | back to summary |
|---|---|
public @Nullable Segment getPreviousText(@NotNull Segment segment, @NotNull BasedSequence baseSeq)
| |
| getSegment | back to summary |
|---|---|
public @NotNull Segment getSegment(int pos, @NotNull BasedSequence baseSeq)
| |
| getSegmentRange | back to summary |
|---|---|
| public @NotNull SegmentTreeRange getSegmentRange(int startIndex, int endIndex, int startPos, int endPos, @NotNull BasedSequence baseSeq, @Nullable Segment hint)
Deprecated
| |
| getStartIndex | back to summary |
|---|---|
| public int getStartIndex(int pos) | |
| hasPreviousAnchor | back to summary |
|---|---|
| public boolean hasPreviousAnchor(int pos) Overrides com. Deprecated
| |
| previousAnchorOffset | back to summary |
|---|---|
| public int previousAnchorOffset(int pos) Overrides com. Deprecated
| |
| toString | back to summary |
|---|---|
public @NotNull String toString(@NotNull BasedSequence baseSeq)
| |