MSWSP: add parse_CNatLanguageRestriction()
[wireshark-wip.git] / ui / export_object.h
blobc42d8524ff431133876aa0f1e5fce9c467449312
1 /* export_object.h
2 * Common routines for tracking & saving objects found in streams of data
3 * Copyright 2007, Stephen Fisher (see AUTHORS file)
5 * $Id$
7 * Wireshark - Network traffic analyzer
8 * By Gerald Combs <gerald@wireshark.org>
9 * Copyright 1998 Gerald Combs
11 * This program is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU General Public License
13 * as published by the Free Software Foundation; either version 2
14 * of the License, or (at your option) any later version.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program; if not, write to the Free Software
23 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
24 * USA.
27 #ifndef __EXPORT_OBJECT_H__
28 #define __EXPORT_OBJECT_H__
30 #ifdef __cplusplus
31 extern "C" {
32 #endif /* __cplusplus */
34 /* Common between protocols */
36 struct _export_object_list_t;
37 typedef struct _export_object_list_t export_object_list_t;
39 typedef struct _export_object_entry_t {
40 guint32 pkt_num;
41 gchar *hostname;
42 gchar *content_type;
43 gchar *filename;
44 /* We need to store a 64 bit integer to hold a file length
45 (was guint payload_len;) */
46 gint64 payload_len;
47 guint8 *payload_data;
48 } export_object_entry_t;
50 void object_list_add_entry(export_object_list_t *object_list, export_object_entry_t *entry);
51 export_object_entry_t *object_list_get_entry(export_object_list_t *object_list, int row);
53 gboolean eo_save_entry(const gchar *save_as_filename, export_object_entry_t *entry, gboolean show_err);
54 GString *eo_massage_str(const gchar *in_str, gsize maxlen, int dup);
55 const char *ct2ext(const char *content_type);
58 /* Protocol specific */
59 gboolean eo_dicom_packet(void *tapdata, packet_info *pinfo, epan_dissect_t *edt _U_,
60 const void *data);
61 gboolean eo_http_packet(void *tapdata, packet_info *pinfo, epan_dissect_t *edt _U_,
62 const void *data);
63 gboolean eo_smb_packet(void *tapdata, packet_info *pinfo, epan_dissect_t *edt _U_,
64 const void *data);
66 void eo_smb_cleanup(void);
69 #ifdef __cplusplus
71 #endif /* __cplusplus */
73 #endif /* __EXPORT_OBJECT_H__ */
76 * Editor modelines
78 * Local Variables:
79 * c-basic-offset: 4
80 * tab-width: 8
81 * indent-tabs-mode: nil
82 * End:
84 * ex: set shiftwidth=4 tabstop=8 expandtab:
85 * :indentSize=4:tabSize=8:noTabs=true: