Module to handle spacemaps

Annotation For __init__.py
anonymous

Annotation For __init__.py

Origin for each line in __init__.py from check-in bfe3da6658:

bfe3da6658 2010-10-14 c.kworr@f7677: ##
bfe3da6658 2010-10-14 c.kworr@f7677: # py-spacemap root package
bfe3da6658 2010-10-14 c.kworr@f7677: # http://code.google.com/p/py-spacemap
bfe3da6658 2010-10-14 c.kworr@f7677: ##
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: """
bfe3da6658 2010-10-14 c.kworr@f7677: This module provides simple class to work with spacemaps, objects that marks
bfe3da6658 2010-10-14 c.kworr@f7677: some portions of given range.
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: Imagine that we have range of 10 bytes. So we want to mark bytes 2 - 3 as used
bfe3da6658 2010-10-14 c.kworr@f7677: and also 8 - 9. I know this just a rough example.
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: Any range can be given as pair x:y where x is part of the marked range and y -
bfe3da6658 2010-10-14 c.kworr@f7677: next free space. In mathematical notation this is equal to [x:y).
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: Module also can:
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677:  - autoshrink maps, i.e. [2:3),[3:6) = [2:6);
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677:  - substract maps, the product of A - B is all space in A that is not covered
bfe3da6658 2010-10-14 c.kworr@f7677: by B, i.e. [2:10) - [5:7) = [2:5),[7,10);
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677:  - get intersection (logical or), the product of A and B is all space that can
bfe3da6658 2010-10-14 c.kworr@f7677: be found both in A and in B, i.e. [2:10) and [5:15) = [5:10);
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677:  - compare maps.
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: more will be added soon...
bfe3da6658 2010-10-14 c.kworr@f7677: """
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: __all__ = [
bfe3da6658 2010-10-14 c.kworr@f7677: 	'__author__',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'__date__',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'__version__',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'__docformat__',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'version',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'version_info',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'SpaceMap',
bfe3da6658 2010-10-14 c.kworr@f7677: 	'test',
bfe3da6658 2010-10-14 c.kworr@f7677: ]
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: # Optional.
bfe3da6658 2010-10-14 c.kworr@f7677: try:
bfe3da6658 2010-10-14 c.kworr@f7677: 	from .project import version_info, version, author as __author__, date as __date__
bfe3da6658 2010-10-14 c.kworr@f7677: 	__version__ = version
bfe3da6658 2010-10-14 c.kworr@f7677: 	from .test import test
bfe3da6658 2010-10-14 c.kworr@f7677: except ImportError:
bfe3da6658 2010-10-14 c.kworr@f7677: 	pass
bfe3da6658 2010-10-14 c.kworr@f7677: 
bfe3da6658 2010-10-14 c.kworr@f7677: from .spacemap import SpaceMap