Expand description
A Unicode string backed by an RRB vector.
Similarly to the standard library String type, a Rope owns its
storage and guarantees that its contents are valid Unicode. Unlike
a String, it is backed not by a Vec<u8> but by an
im::Vector<u8>. These in turn are backed by a balanced tree structure
known as an an RRB tree, which makes a wide variety of operations asymptotically
efficient. In particular, ropes can be cloned in constant time, and can be
split or concatenated in logarithmic time.
Modules§
- accessor
- Lending iterators over vectors, with flexible ownership.
- pattern
- Implementing types for pattern search
- proptest
- Test strategies for ropes
Structs§
- Bytes
- An iterator over the bytes of a rope.
- Char
Indices - An iterator over the
chars of aRopeand their indices. - Chars
- An iterator over the
chars of aRope. - Chunks
- An iterator over chunks of a
Rope. - FindAll
- An iterator returned by
find_all. - From
Utf8 Error - A possible error value when converting a
Vector<u8>into aRope. - Lines
- An iterator returned by
lines. - RFind
All - An iterator returned by
rfind_all. - RSplit
- An iterator returned by
rsplit. - RSplitN
- An iterator returned by
rsplitn. - RSplit
Terminator - An iterator returned by
rsplit_terminator. - Rope
- A Unicode string backed by an RRB vector.
- Split
- An iterator returned by
split. - Split
Inclusive - An iterator returned by
split_inclusive. - SplitN
- An iterator returned by
splitn. - Split
Terminator - An iterator returned by
split_terminator. - Utf8
Boundary Error - An error returned when attempting to divide a
Ropeat a location that is not a UTF-8 character boundary. - Utf8
Error - Errors which can occur when attempting to interpret a sequence of
u8as a string. - Vector
Guard - Guards against panics during unsafe rope mutation.
Enums§
Traits§
- Bytes
Like - A trait for types that can be converted into a
Vector<u8>. - StrLike
- A trait for types that can be converted into a
Vector<u8>containing valid UTF-8.