Removed trailing whitespaces from .h and .c files using the
[obnox/wireshark/wip.git] / epan / column-utils.h
1 /* column-utils.h
2  * Definitions for column utility structures and routines
3  *
4  * $Id: column-utils.h,v 1.7 2002/08/28 20:40:44 jmayer Exp $
5  *
6  * Ethereal - Network traffic analyzer
7  * By Gerald Combs <gerald@ethereal.com>
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
23  */
24
25 #ifndef __COLUMN_UTILS_H__
26 #define __COLUMN_UTILS_H__
27
28 #include <glib.h>
29
30 #define COL_MAX_LEN 256
31 #define COL_MAX_INFO_LEN 4096
32
33 #include "column_info.h"
34 #include "packet_info.h"
35
36 /* Allocate all the data structures for constructing column data, given
37    the number of columns. */
38 extern void     col_init(column_info *, gint);
39
40 /* Utility routines used by packet*.c */
41
42 extern void     col_set_writable(column_info *, gboolean);
43 extern gint     check_col(column_info *, gint);
44 extern void     col_clear(column_info *, gint);
45 extern void     col_set_str(column_info *, gint, gchar *);
46 #if __GNUC__ >= 2
47 extern void     col_add_fstr(column_info *, gint, gchar *, ...)
48     __attribute__((format (printf, 3, 4)));
49 extern void     col_append_fstr(column_info *, gint, gchar *, ...)
50     __attribute__((format (printf, 3, 4)));
51 extern void     col_prepend_fstr(column_info *, gint, gchar *, ...)
52     __attribute__((format (printf, 3, 4)));
53 #else
54 extern void     col_add_fstr(column_info *, gint, gchar *, ...);
55 extern void     col_append_fstr(column_info *, gint, gchar *, ...);
56 extern void     col_prepend_fstr(column_info *, gint, gchar *, ...);
57 #endif
58 extern void     col_add_str(column_info *, gint, const gchar *);
59 extern void     col_append_str(column_info *, gint, gchar *);
60 extern void     col_set_cls_time(frame_data *, column_info *, int);
61 extern void     fill_in_columns(packet_info *);
62
63 #endif /* __COLUMN_UTILS_H__ */