Added a comment about the zlib compressed content and meta data in the blocks.

This commit is contained in:
Sascha L. Teichmann 2014-09-10 08:35:20 +02:00
parent cb5b6461a3
commit 0ff87c1d22

View File

@ -30,6 +30,12 @@ type DecodedBlock struct {
IndexMap map[int]int
}
// The content of the map and the meta data are compressed with zlib.
// Unfortunately the byte length of this two structures are not stored
// explicitly in the block data. To access the informations behind
// them (e.g. the node id mappings) we have to count the bytes consumed
// by the zlib reader and continue our extraction process behind this
// offset. PosBuf implements such a counting reader source.
type PosBuf struct {
Data []byte
Pos int