Simple python class that acts like string, but it also provides a way to work with it in segments.
Project description
segmentedstring
Simple python class that acts like string, but it also provides a way to work with it in segments.
The eq, lt, and gt methods are the same as the ones for ordinary strings. Therefore, there is no consideration of the segments.
Example usage:
>>> s = SegmentedString(("abc", "def", "ghi"), labels=("first", "second", "third"))
>>> s
'abcdefghi'
>>> s.segments
('abc', 'def', 'ghi')
>>> s.labels
('first', 'second', 'third')
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
segmentedstring-1.0.1.tar.gz
(4.2 kB
view details)
File details
Details for the file segmentedstring-1.0.1.tar.gz.
File metadata
- Download URL: segmentedstring-1.0.1.tar.gz
- Upload date:
- Size: 4.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.10.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e2455d02adcab426bf502073809f17572d8d5effd7cd3e75cd9858da9b5d74c4
|
|
| MD5 |
22aa27f18b4432d606d66a341e8eb983
|
|
| BLAKE2b-256 |
700a972dfa1404f3bb3247970be65633abcf2638da34f6d89eba2b0ae166cdcc
|