include/utils.h File Reference

#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <stdint.h>

Include dependency graph for utils.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void * check_malloc (size_t size)
void * check_realloc (void *ptr, size_t size)
void * check_calloc (size_t elements, size_t size)
char * word_flatten (char **words, int start_word, int n)
unsigned long data_hash (void *pack, unsigned long ecount, unsigned long esize, unsigned long elength, unsigned long offset, unsigned long hashsize)
uint64_t data_hash64 (void *pack, unsigned long datalen)
unsigned long long string_hash (char *string, unsigned long long size)
void print_time (FILE *stream)
void usage (char *pname)
void casefold (char *string)
int fcomp (const void *f1, const void *f2)


Detailed Description

Id
utils.h,v 1.10.2.2 2005/03/15 01:21:10 ybernste Exp
Written by Yaniv Bernstein 2004

Definition in file utils.h.


Function Documentation

void casefold ( char *  string  ) 

void* check_calloc ( size_t  elements,
size_t  size 
)

A wrapper around calloc that spews if a NULL pointer is returned

void* check_malloc ( size_t  size  ) 

A wrapper around malloc that spews if NULL is returned

void* check_realloc ( void *  ptr,
size_t  size 
)

A wrapper around realloc that spews if a NULL pointer is returned

unsigned long data_hash ( void *  pack,
unsigned long  ecount,
unsigned long  esize,
unsigned long  elength,
unsigned long  offset,
unsigned long  hashsize 
)

uint64_t data_hash64 ( void *  pack,
unsigned long  datalen 
)

int fcomp ( const void *  f1,
const void *  f2 
)

void print_time ( FILE *  stream  ) 

Print the current date and time in a nicely formatted way

unsigned long long string_hash ( char *  string,
unsigned long long  size 
)

Hash a string using the Karp-Rubin string hashing algorithm

void usage ( char *  pname  ) 

Print the usage information for this program

char* word_flatten ( char **  words,
int  start_word,
int  n 
)

Takes an array of words and returns a single string composed of all those words appended to each other, separated by spaces.


Generated on Wed Dec 19 20:52:42 2007 for fsa-blast by  doxygen 1.5.2