Search indexes

Zim archives contain specific indexes in the  namespace.

They are content that can be used by reader implementation to locate user entries.

All indexes are optional.

All indexes and listing items MUST be stored in uncompressed cluster.

Xapian Indexes
Xapian indexes are xapian database. They have to be opened using the xapian library.

Fulltext index
Namespace:

Path:

Mimetype :

Tittle index
Namespace:

Path:

Mimetype :

Listing
Listings are listing of entries.

The content of listing are binary array of entry numbers. Each entry number is 4 bytes (little-endian) unsigned integer. Entry number is the index of the entry in the URL pointer list.

To get the offset of an entry from the title pointer list, you have to look it up in the URL pointer list

Title index v0
Namespace:

Path:

Mimetype :

The content of the listing is the list of all entries in the zim archive (all namespace included, including  itself).

Entries are sorted using the key

Content size is

This is the exact same content of the data.

If present,  should directly point to the data of this entry.

Title index v1
Namespace:

Path:

Mimetype :

The content of the listing is the list of all "article entries" in the zim archive.

Those "article entries" may be redirect (what is a article entry is not really defined in the spec, it is up to the creator to define in which category a entry is).

Entries are sorted using the key  (All article entries are in   namespace by definition)

Content size is

may be used to pick random articles or to search article by title and be sure that no resource entries are included.