Skip to main content

Module tree

Module tree 

Expand description

A general b-tree structure suitable for ropes and the like.

Structs§

Cursor
A data structure for traversing boundaries in a tree.
CursorIter
An iterator generated by a Cursor, for some Metric.
Node
A b-tree node storing leaves at the bottom, and with info retained at each node. It is implemented with atomic reference counting and copy-on-write semantics, so an immutable clone is a very cheap operation, and nodes can be shared across threads. Even so, it is designed to be updated in place, with efficiency similar to a mutable data structure, using uniqueness of reference count to detect when this operation is safe.
TreeBuilder
A builder for creating new trees.

Enums§

UnitAffinity

Traits§

DefaultMetric
A trait indicating the default metric of a NodeInfo.
Leaf
A trait for the leaves of trees of type Node.
Metric
A trait for quickly processing attributes of a NodeInfo.
NodeInfo
UnitConverter
A trait for NodeInfo to convert between base units and measured units for example, for a Rope, the base unit can be the bytes and the measured units can be line number The base unit is usize and measured units is a generic type