1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2  * Copyright by The HDF Group.                                               *
3  * Copyright by the Board of Trustees of the University of Illinois.         *
4  * All rights reserved.                                                      *
5  *                                                                           *
6  * This file is part of HDF.  The full HDF copyright notice, including       *
7  * terms governing use, modification, and redistribution, is contained in    *
8  * the COPYING file, which can be found at the root of the source code       *
9  * distribution tree, or in https://support.hdfgroup.org/ftp/HDF/releases/.  *
10  * If you do not have access to either file, you may request a copy from     *
11  * help@hdfgroup.org.                                                        *
12  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
13 
14 /* $Id$ */
15 
16 /*-----------------------------------------------------------------------------
17  * File:    cnone.h
18  * Purpose: Header file for "none" encoding information.
19  * Dependencies: should only be included from hcompi.h
20  * Invokes: none
21  * Contents: Structures & definitions for "none" encoding.  This header
22  *              should only be included in hcomp.c and cnone.c.
23  * Structure definitions:
24  * Constant definitions:
25  *---------------------------------------------------------------------------*/
26 
27 /* avoid re-inclusion */
28 #ifndef __CNONE_H
29 #define __CNONE_H
30 
31 #if defined c_plusplus || defined __cplusplus
32 extern      "C"
33 {
34 #endif                          /* c_plusplus || __cplusplus */
35 
36 /*
37    ** from cnone.c
38  */
39 
40 HDFLIBAPI int32 HCPcnone_stread
41                 (accrec_t * rec);
42 
43 HDFLIBAPI int32 HCPcnone_stwrite
44                 (accrec_t * rec);
45 
46 HDFLIBAPI int32 HCPcnone_seek
47                 (accrec_t * access_rec, int32 offset, int origin);
48 
49 HDFLIBAPI int32 HCPcnone_inquire
50                 (accrec_t * access_rec, int32 *pfile_id, uint16 *ptag, uint16 *pref,
51                int32 *plength, int32 *poffset, int32 *pposn, int16 *paccess,
52                  int16 *pspecial);
53 
54 HDFLIBAPI int32 HCPcnone_read
55                 (accrec_t * access_rec, int32 length, void * data);
56 
57 HDFLIBAPI int32 HCPcnone_write
58                 (accrec_t * access_rec, int32 length, const void * data);
59 
60 HDFLIBAPI intn HCPcnone_endaccess
61                 (accrec_t * access_rec);
62 
63 #if defined c_plusplus || defined __cplusplus
64 }
65 #endif                          /* c_plusplus || __cplusplus */
66 
67 /* "none" [en|de]coding information */
68 typedef struct
69 {
70     intn        space_holder;   /* merely a space holder so compilers don't barf */
71 }
72 comp_coder_none_info_t;
73 
74 #ifndef CNONE_MASTER
75 extern funclist_t cnone_funcs;  /* functions to perform run-length encoding */
76 #else
77 funclist_t  cnone_funcs =
78 {                               /* functions to perform run-length encoding */
79     HCPcnone_stread,
80     HCPcnone_stwrite,
81     HCPcnone_seek,
82     HCPcnone_inquire,
83     HCPcnone_read,
84     HCPcnone_write,
85     HCPcnone_endaccess
86 };
87 #endif
88 
89 #endif /* __CNONE_H */
90