2011-11-04 17:25:00 -04:00
|
|
|
/* Declarations of WARC helper methods. */
|
|
|
|
#ifndef WARC_H
|
|
|
|
#define WARC_H
|
|
|
|
|
|
|
|
#include "host.h"
|
|
|
|
|
2012-05-05 09:24:35 -04:00
|
|
|
void warc_init (void);
|
|
|
|
void warc_close (void);
|
2011-11-04 17:25:00 -04:00
|
|
|
void warc_timestamp (char *timestamp);
|
|
|
|
void warc_uuid_str (char *id_str);
|
|
|
|
|
2012-05-05 09:24:35 -04:00
|
|
|
FILE * warc_tempfile (void);
|
2011-11-04 17:25:00 -04:00
|
|
|
|
2012-02-25 05:58:21 -05:00
|
|
|
bool warc_write_request_record (char *url, char *timestamp_str, char *concurrent_to_uuid, ip_address *ip, FILE *body, off_t payload_offset);
|
|
|
|
bool warc_write_response_record (char *url, char *timestamp_str, char *concurrent_to_uuid, ip_address *ip, FILE *body, off_t payload_offset, char *mime_type, int response_code, char *redirect_location);
|
removed 'const' warnings.
* hash.h (hash_table_put): Make argument "value" const.
* hash.c (hash_table_put): Make argument value const. Cast `value' to
void.
* http.c (request_set_header): Make argument `name' const. Cast `value'
and `name' to void*.
(request_remove_header): Make argument `name' const.
* url.c (url_file_name): Make `index_filename' static.
* warc.h (warc_write_cdx_record): Make `url', `timestamp', `mime_type',
`payload_digest', `redirect_location', `warc_filename', response_uuid'
arguments const. Make `checksum' const.
* warc.c (warc_write_date_header): Make the `timestamp' argument const.
Make `extension' const.
(warc_write_cdx_record): Make `url', `timestamp', `mime_type',
`payload_digest', `redirect_location', `warc_filename', response_uuid'
arguments const. Make `checksum' const.
2012-05-14 11:32:55 -04:00
|
|
|
bool warc_write_resource_record (char *resource_uuid, const char *url, const char *timestamp_str, const char *concurrent_to_uuid, ip_address *ip, const char *content_type, FILE *body, off_t payload_offset);
|
2011-11-04 17:25:00 -04:00
|
|
|
|
|
|
|
#endif /* WARC_H */
|
|
|
|
|