automotive-dlt
dlt_cdh_streamer.h
Go to the documentation of this file.
1 /*
2  * @licence app begin@
3  * SPDX license identifier: MPL-2.0
4  *
5  * Copyright (C) 2011-2015, BMW AG
6  *
7  * This file is part of GENIVI Project DLT - Diagnostic Log and Trace.
8  *
9  * This Source Code Form is subject to the terms of the
10  * Mozilla Public License (MPL), v. 2.0.
11  * If a copy of the MPL was not distributed with this file,
12  * You can obtain one at http://mozilla.org/MPL/2.0/.
13  *
14  * For further information see http://www.genivi.org/.
15  * @licence end@
16  */
17 
28 #ifndef DLT_CDH_STREAMER_H
29 #define DLT_CDH_STREAMER_H
30 
31 #include <stdio.h>
32 #include <zlib.h>
33 
34 #include "dlt_cdh_definitions.h"
35 
36 typedef struct
37 {
38  FILE* stream;
39  unsigned int offset;
40  gzFile gz_dst_file;
41  unsigned char* read_buf;
42 
44 
45 cdh_status_t stream_init(file_streamer_t* p_fs, const char* p_src_fname, const char* p_dst_fname);
47 cdh_status_t stream_read(file_streamer_t* p_fs, void* p_buf, unsigned int p_size);
49 cdh_status_t stream_move_to_offest(file_streamer_t* p_fs, unsigned int p_offset);
50 cdh_status_t stream_move_ahead(file_streamer_t* p_fs, unsigned int p_nbbytes);
51 unsigned int stream_get_offset(file_streamer_t* p_fs);
52 
53 #endif /* #ifndef DLT_CDH_STREAMER_H */
unsigned int offset
cdh_status_t stream_finish(file_streamer_t *p_fs)
unsigned char * read_buf
cdh_status_t
cdh_status_t stream_close(file_streamer_t *p_fs)
unsigned int stream_get_offset(file_streamer_t *p_fs)
cdh_status_t stream_init(file_streamer_t *p_fs, const char *p_src_fname, const char *p_dst_fname)
cdh_status_t stream_move_ahead(file_streamer_t *p_fs, unsigned int p_nbbytes)
cdh_status_t stream_read(file_streamer_t *p_fs, void *p_buf, unsigned int p_size)
cdh_status_t stream_move_to_offest(file_streamer_t *p_fs, unsigned int p_offset)