forked from WKPlus/rangedict
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup.py
44 lines (38 loc) · 924 Bytes
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
VERSION = '0.1.6'
LONG_DESCRIPTION = '''
rangedict is a dict whose key is a range.
Usage
-----
>>> from rangedict import RangeDict
>>> rd = RangeDict()
>>> rd[(1, 2)] = 1
>>> rd[(3, 3)] = 3
>>> rd[(5, 7)] = 5
>>> print rd[6]
5
>>> 3 in rd
True
>>> del rd[(3, 3)]
>>> 3 in rd
False
Implemented based on red black tree provides an O(logn) complexity for
inserting, deleting and finding.
'''
setup(
name='rangedict',
description='range dict is a dict whose key is a range',
long_description=LONG_DESCRIPTION,
author='WKPlus',
url='https://github.com/WKPlus/rangedict.git',
license='MIT',
author_email='[email protected]',
version=VERSION,
py_modules=['rangedict'],
install_requires=[],
test_requires=['nose'],
zip_safe=False,
)