qments/include/driver.h

16 lines
425 B
C
Raw Permalink Normal View History

2023-06-15 01:44:02 +03:00
#ifndef DRIVER_H
#define DRIVER_H
#include "comment.h"
typedef struct {
/* should return (id > 0) on success, and negative number on error */
int (*leave_comment)(void*, const CommentHeader*, const char*);
2023-06-15 01:44:02 +03:00
/* retrieve header information by id */
int (*get_header)(void*, CommentHeader*, int);
/* retrieve text of comment by id */
int (*get_text)(void*, char*, int);
} Driver;
#endif /* DRIVER_H */