rerun pidl
[metze/wireshark/wip.git] / epan / column-info.h
1 /* column-info.h
2  * Definitions for column structures and routines
3  *
4  * $Id$
5  *
6  * Wireshark - Network traffic analyzer
7  * By Gerald Combs <gerald@wireshark.org>
8  * Copyright 1998 Gerald Combs
9  *
10  * This program is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU General Public License
12  * as published by the Free Software Foundation; either version 2
13  * of the License, or (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
23  */
24
25 #ifndef __COLUMN_INFO_H__
26 #define __COLUMN_INFO_H__
27
28 #include <glib.h>
29 #include <epan/column-utils.h>
30
31 #ifdef __cplusplus
32 extern "C" {
33 #endif /* __cplusplus */
34
35 /** @file
36  * Column info.
37  */
38
39 #define COL_MAX_LEN 256
40 #define COL_MAX_INFO_LEN 4096
41
42 /** Column expression */
43 typedef struct {
44   const gchar **col_expr;     /**< Filter expression */
45   gchar      **col_expr_val;  /**< Value for filter expression */
46 } col_expr_t;
47
48 /** Column info */
49 struct epan_column_info {
50   const struct epan_session *epan;
51   gint                num_cols;             /**< Number of columns */
52   gint               *col_fmt;              /**< Format of column */
53   gboolean          **fmt_matx;             /**< Specifies which formats apply to a column */
54   gint               *col_first;            /**< First column number with a given format */
55   gint               *col_last;             /**< Last column number with a given format */
56   gchar             **col_title;            /**< Column titles */
57   gchar             **col_custom_field;     /**< Custom column field */
58   gint               *col_custom_occurrence;/**< Custom column field occurrence */
59   gint               *col_custom_field_id;  /**< Custom column field id */
60   struct epan_dfilter **col_custom_dfilter; /**< Compiled custom column field */
61   const gchar       **col_data;             /**< Column data */
62   gchar             **col_buf;              /**< Buffer into which to copy data for column */
63   int                *col_fence;            /**< Stuff in column buffer before this index is immutable */
64   col_expr_t          col_expr;             /**< Column expressions and values */
65   gboolean            writable;             /**< writable or not @todo Are we still writing to the columns? */
66 };
67
68 #ifdef __cplusplus
69 }
70 #endif /* __cplusplus */
71
72 #endif /* __COLUMN_INFO_H__ */