Metadata-Version: 2.1
Name: range-set
Version: 0.3.2
Summary: Efficient storage for sets of mostly-consecutive integers
Home-page: https://github.com/smurfix/range_set
Author: Matthias Urlichs
Author-email: matthias@urlichs.de
License: MIT -or- Apache License 2.0
Keywords: set,coalesce,compact,consecutive
Classifier: License :: OSI Approved :: MIT License
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.4
License-File: LICENSE
License-File: LICENSE.APACHE2
License-File: LICENSE.MIT

RangeSet
========

License: Your choice of MIT or Apache License 2.0

Rationale
---------

Python Sets are nice to work with, but very inefficient if you need a large
set with mostly-consecutive integers. The RangeSet class provides efficient
handling and storage for these sets.

Non-integers?
-------------

RangeSet works with any class whose instances are

* comparable

* step-able, i.e. you can add 1 to them / subtract 1 from them.

* discrete, i.e. there is no value between ``n`` and ``n+1``.

RangeSet doesn't add or subtract any other values, nor does it try to
subtract two instances from each other.

The requirement to subtract 1 is an optimization that could be removed if
necessary.

