<div class="doctest-setup">

>>> from xix.utils.config import configFactory
>>> directory = configFactory('xix-unittests.cfg').utils.xio.data.directory
>>> from glob import glob
>>> import os.path
>>> files = glob(os.path.join(directory, '*txt'))
>>> files.sort()

</div>

Example 1.
----------

Seeking from the beginning of the file

>>> from xix.utils.xio import AggregateFile
>>> fd = AggregateFile(files).open()
>>> fd.seek(1)
>>> print fd.read()[:-1]
bcdef
ghijkl
mnopqr
stuvwx
yz

Example 1 continued:

>>> fd = AggregateFile(files).open()
>>> fd.seek(7)
>>> print fd.read()[:-1]
ghijkl
mnopqr
stuvwx
yz
>>> fd.seek(8)
>>> print fd.read()[:-1]
hijkl
mnopqr
stuvwx
yz

Overseeking:

>>> fd = AggregateFile(files).open()
>>> fd.seek(57634657)
>>> print fd.read()
<BLANKLINE>


