cctools
jx_table.h
1 #ifndef JX_TABLE_H
2 #define JX_TABLE_H
3 
4 #include "jx.h"
5 #include <stdio.h>
6 
7 typedef enum {
8  JX_TABLE_MODE_PLAIN,
9  JX_TABLE_MODE_METRIC,
10  JX_TABLE_MODE_URL
11 } jx_table_mode_t;
12 
13 typedef enum {
14  JX_TABLE_ALIGN_LEFT,
15  JX_TABLE_ALIGN_RIGHT
16 } jx_table_align_t;
17 
18 struct jx_table {
19  const char *name;
20  const char *title;
21  jx_table_mode_t mode;
22  jx_table_align_t align;
23  int width;
24 };
25 
26 void jx_table_print_header( struct jx_table *t, FILE *f, int columns );
27 void jx_table_print( struct jx_table *t, struct jx *j, FILE *f, int columns );
28 void jx_table_print_footer( struct jx_table *t, FILE *f, int columns );
29 
30 #endif
Definition: jx_table.h:18
JSON Expressions (JX) library.
JX value representing any expression type.
Definition: jx.h:135