Expand description
§TextArrayView Module - Windowed View over a TextArray
TextArrayV is a read-only, zero-copy view into a [offset .. offset + len)
slice of a TextArray.
§Purpose
- Provides windowed access to UTF-8 string data without copying buffers.
- Unifies handling for
StringArrayandCategoricalArrayunder theTextArrayenum. - Allows null counts to be cached per view for faster repeated operations.
§Behaviour
- Fully supports both string and dictionary-encoded text variants.
- Enables lightweight sub-ranges for use in downstream computations, filtering, or previews.
- Creating a view does not allocate; slicing is zero-copy.
§Threading
- Not thread-safe due to
Cellfor cached null counts. - For multi-threaded code, create per-thread clones via
slice.
§Interop
- Convert back to a full
TextArrayviato_text_array. - Promote to
Arrayviainner_arrayfor unified API calls.
§Invariants
offset + len <= array.len()lenis the logical number of text elements in the view.
Structs§
- Text
ArrayV - TextArrayView