Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

TestFdStreams.C File Reference

#include <assert.h>
#include <string.h>
#include <stdlib.h>
#include <time.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
#include <limits.h>
#include "FdStream.H"
#include <iostream>
#include <fstream>
#include <getopt.h>

Go to the source code of this file.

Defines

#define MAX(a, b)   (((a) > (b)) ? (a) : (b))
#define MIN(a, b)   (((a) > (b)) ? (b) : (a))
#define MAX_READ_SIZE   (BUFSIZ*2)

Functions

void print_stream_state (std::ostream &out, unsigned int state)
void print_state_if_not_good (const ios &stream, const char *name, const char *marker)
void random_read_test (const char *fname, unsigned int count)
void compare_files (const char *fname1, const char *fname2)
void random_read_write_test (const char *source_fname, const char *dest_fname_base, unsigned int count)
int main (int argc, char *argv[])


Define Documentation

#define MAX a,
 )     (((a) > (b)) ? (a) : (b))
 

Definition at line 76 of file TestFdStreams.C.

#define MAX_READ_SIZE   (BUFSIZ*2)
 

Definition at line 79 of file TestFdStreams.C.

Referenced by compare_files(), random_read_test(), and random_read_write_test().

#define MIN a,
 )     (((a) > (b)) ? (b) : (a))
 

Definition at line 77 of file TestFdStreams.C.

Referenced by random_read_write_test().


Function Documentation

void compare_files const char *  fname1,
const char *  fname2
 

Definition at line 139 of file TestFdStreams.C.

References MAX_READ_SIZE.

Referenced by random_read_write_test().

int main int  argc,
char *  argv[]
 

Definition at line 384 of file TestFdStreams.C.

References random_read_test(), and random_read_write_test().

void print_state_if_not_good const ios &  stream,
const char *  name,
const char *  marker
 

Definition at line 65 of file TestFdStreams.C.

References print_stream_state().

Referenced by output_tests().

void print_stream_state std::ostream &  out,
unsigned int  state
 

Definition at line 32 of file TestFdStreams.C.

Referenced by print_state_if_not_good(), and random_read_write_test().

void random_read_test const char *  fname,
unsigned int  count
 

Definition at line 83 of file TestFdStreams.C.

References FS::FdStreamBase::fd(), and MAX_READ_SIZE.

Referenced by main().

void random_read_write_test const char *  source_fname,
const char *  dest_fname_base,
unsigned int  count
 

Definition at line 182 of file TestFdStreams.C.

References compare_files(), MAX_READ_SIZE, MIN, and print_stream_state().

Referenced by main().


Generated on Mon May 8 00:49:00 2006 for Vesta by  doxygen 1.4.2