Text sequence data structures
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.circleci
c++
common
gap-list
gradle/wrapper
impl-builder
impl-fsb
impl-gap
impl-line
test-common
.gitignore
LICENSE
README.md
appveyor.yml
build.gradle.kts
gradlew
gradlew.bat
settings.gradle.kts

README.md

Text Sequence

Read this paper

Windows Linux Coverage Bintray

Architecture

  • Interface class org.ice1000.textseq.TextSequence in common
  • Trivial implementations in common
  • Implementations in their own subproject
  • Standalone GapList<T> (with no dependencies) that uses a gap buffer to maintain elements, which is more efficient than ArrayList<T>.
    • C++ version (C++17 with dependency on cstddef, cassert and cstring)

Build

repositories { jcenter() }
dependencies {
  String textseq_version = "v0.3"
  compile "org.ice1000.textseq:gap-list:$textseq_version" // standalone GapList impl
  compile "org.ice1000.textseq:common:$textseq_version" // common + trivial impl
  compile "org.ice1000.textseq:impl-builder:$textseq_version" // array method, depends on common
  compile "org.ice1000.textseq:impl-gap:$textseq_version" // gap method, depends on common
  compile "org.ice1000.textseq:impl-line:$textseq_version" // line span method, depends on impl-gap
}

Progress

  • Trivial implementations (using ArrayList, LinkedList), say, the linked list method
  • StringBuilderTextSequence implementation, say, the array method, DevKt
  • GapBuffer implementation, say, the gap method, Emacs, Scintilla, Java Swing
  • LineSpan implementation, say, the line span method, Hemlock
    • The active line is a gap buffer, other lines are simple string, discussed in this paper
  • FixedSizeBuffer implementation, say, fixed size buffer
  • PieceTable implementation, say, the piece table method, VSCode, AbiWord
  • Rope (aka Balanced Tree), Vim