IDZEBRA  2.1.2
Data Structures | Functions
benchindex1.c File Reference
#include <yaz/options.h>
#include <ctype.h>
#include <stdlib.h>
#include <string.h>
#include <yaz/log.h>
#include <yaz/nmem.h>
#include <yaz/xmalloc.h>
#include <yaz/marcdisp.h>
#include <yaz/timing.h>
#include <it_key.h>
#include <idzebra/isamb.h>
#include <idzebra/dict.h>
#include <assert.h>

Go to the source code of this file.

Data Structures

struct  index_block
 
struct  index_term
 

Functions

struct index_blockindex_block_new (int memory)
 
void index_block_destroy (struct index_block **bp)
 
static int cmp_ar (const void *p1, const void *p2)
 
int code_read (void *vp, char **dst, int *insertMode)
 
void index_block_flush (struct index_block *b, ISAMB isb, Dict dict, int no_docs)
 
void index_block_check_flush (struct index_block *b, ISAMB isb, Dict dict, int no_docs)
 
void index_block_add (struct index_block *b, const char *term, zint docid, zint seqno)
 
void index_term (struct index_block *b, const char *term, zint docid, zint *seqno)
 
void index_wrbuf (struct index_block *b, WRBUF wrbuf, zint docid, int subfield_char)
 
void index_marc_line_records (ISAMB isb, Dict dict, zint *docid_seq, FILE *inf, int memory)
 
void index_marc_from_file (ISAMB isb, Dict dict, zint *docid_seq, FILE *inf, int memory, int verbose, int print_offset)
 
void exit_usage (void)
 
int main (int argc, char **argv)
 

Function Documentation

static int cmp_ar ( const void *  p1,
const void *  p2 
)
static

Definition at line 76 of file benchindex1.c.

References index_term::docid, index_term::seqno, and index_term::term.

Referenced by index_block_flush().

int code_read ( void *  vp,
char **  dst,
int *  insertMode 
)
void exit_usage ( void  )

Definition at line 498 of file benchindex1.c.

Referenced by main().

void index_block_add ( struct index_block b,
const char *  term,
zint  docid,
zint  seqno 
)
void index_block_check_flush ( struct index_block b,
ISAMB  isb,
Dict  dict,
int  no_docs 
)
void index_block_destroy ( struct index_block **  bp)

Definition at line 66 of file benchindex1.c.

Referenced by index_marc_from_file(), and index_marc_line_records().

void index_block_flush ( struct index_block b,
ISAMB  isb,
Dict  dict,
int  no_docs 
)
struct index_block* index_block_new ( int  memory)
void index_marc_from_file ( ISAMB  isb,
Dict  dict,
zint docid_seq,
FILE *  inf,
int  memory,
int  verbose,
int  print_offset 
)
void index_marc_line_records ( ISAMB  isb,
Dict  dict,
zint docid_seq,
FILE *  inf,
int  memory 
)
void index_term ( struct index_block b,
const char *  term,
zint  docid,
zint seqno 
)

Definition at line 278 of file benchindex1.c.

References index_block_add(), and ZINT_FORMAT.

Referenced by index_wrbuf().

void index_wrbuf ( struct index_block b,
WRBUF  wrbuf,
zint  docid,
int  subfield_char 
)

Definition at line 289 of file benchindex1.c.

References index_term(), index_term::seqno, and index_term::term.

Referenced by index_marc_from_file(), and index_marc_line_records().

int main ( int  argc,
char **  argv 
)