/*****************************************************************************
*                                                                            *
*      COMMON OCEANOGRAPHIC DATA ACCESS SYSTEM (CODAS)                       *
*                                                                            *
*      WRITTEN BY:  RAMON CABRERA, ERIC FIRING, and JULIE RANADA             *
*                   JOINT INSTITUTE FOR MARINE AND ATMOSPHERIC RESEARCH      *
*                   1000 POPE ROAD  MSB 404                                  *
*                   HONOLULU, HI 96822                                       *
*                                                                            *
*      VERSION:     3.00                                                     *
*                                                                            *
*      DATE:        APRIL 1989                                               *
*                                                                            *
*****************************************************************************/
/*

    FILE:  prtstruc.h

          Structure & specialized printing functions and supporting routines.

*/
#ifndef prtstruc_included
#define prtstruc_included
#ifndef dbhost_included
#include "dbhost.h"        /* PROTOTYPE_ALLOWED */
#endif
#ifndef dbext_included
#include "dbext.h"         /* SHORT, STRUCT_DEF_HDR_TYPE, STRUCT_DEF_ELEM_TYPE */
#endif

#if PROTOTYPE_ALLOWED
int find_ncol(char *format, char *sample_value, SHORT value_type);
unsigned int print_structure(FILE *fp, char *data, char *name,
                             unsigned int nbytes, STRUCT_DEF_HDR_TYPE *str_def);
unsigned int print_array_struct(FILE *fp, char *data, char *name, int n,
                                STRUCT_DEF_HDR_TYPE *str_def);
unsigned int print_select(FILE *fp, char *data, STRUCT_DEF_ELEM_TYPE *nuv,
                          unsigned int n, char *format,
                          STRUCT_DEF_HDR_TYPE *str_def);
#else
int find_ncol();
unsigned int print_structure();
unsigned int print_array_struct();
unsigned int print_select();
#endif
#endif /* ifndef prtstruc_included */

