/* * Functions needed for particular implementation (varies * depending on what synchronization mechanism is to be used). */ #ifndef READERS_WRITERS_H #define READERS_WRITERS_H /* * initialize for synchronization */ void init_synch(void); /* * clean up */ void end_synch(void); /* * simulate read with synchronization (wait if need be) */ void simulate_read_with_synch(const int readerID, const int delay); /* * simulate write with synchronization (wait if need be) */ void simulate_write_with_synch(const int writerID, const int delay); #endif /* READERS_WRITERS_H */