3 #ifndef __INDEX_FILE_H__
4 #define __INDEX_FILE_H__
7 #include "tools/AutoFilePtr.h"
10 #include "storage/Index.h"
11 #include "storage/NameHash.h"
40 static const uint32_t
cookie = 0x43414932;
54 virtual void open(
const stdString &filename,
ReadWrite readwrite=ReadOnly);
72 bool check(
int level);
virtual NameIterator * iterator()
Returns iterator.
Name iterator.
Definition: Index.h:115
void showStats(FILE *f)
Prints statistics.
static const uint32_t cookie
== 'CAI2', Chan.
Definition: IndexFile.h:40
Return value of addChannel() and findChannel()
Definition: Index.h:65
ReadWrite
Modes used for open.
Definition: Index.h:27
bool check(int level)
Check level.
virtual void close()
Close the index file.
virtual Result * addChannel(const stdString &channel)
Add channel.
virtual Result * findChannel(const stdString &channel)
Find channel.
RTree-based index file.
Definition: IndexFile.h:35
virtual void open(const stdString &filename, ReadWrite readwrite=ReadOnly)
Open the index file.
A file-based Hash table for strings.
Definition: NameHash.h:37
IndexFile(int RTreeM=50)
Constructor.
Auto-close FILE pointer wrapper.
Definition: AutoFilePtr.h:15
Maintains memory blocks within a file.
Definition: FileAllocator.h:22
static const uint32_t ht_size
The hash table size used for new channel name tables.
Definition: IndexFile.h:49
Base interface for the archiver's indices.
Definition: Index.h:16