2001-04-01 03:42:00 +00:00
|
|
|
/* column.h
|
|
|
|
* Definitions for column structures and routines
|
|
|
|
*
|
2004-07-18 00:24:25 +00:00
|
|
|
* $Id$
|
2001-04-01 03:42:00 +00:00
|
|
|
*
|
2006-05-21 05:12:17 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
2001-04-01 03:42:00 +00:00
|
|
|
* Copyright 1998 Gerald Combs
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
2002-08-28 20:41:00 +00:00
|
|
|
*
|
2001-04-01 03:42:00 +00:00
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
2002-08-28 20:41:00 +00:00
|
|
|
*
|
2001-04-01 03:42:00 +00:00
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __COLUMN_INFO_H__
|
|
|
|
#define __COLUMN_INFO_H__
|
|
|
|
|
|
|
|
#include <glib.h>
|
|
|
|
|
2007-01-18 18:43:30 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
2001-04-01 03:42:00 +00:00
|
|
|
#define COL_MAX_LEN 256
|
|
|
|
#define COL_MAX_INFO_LEN 4096
|
|
|
|
|
|
|
|
typedef struct _column_info {
|
2004-12-30 23:42:02 +00:00
|
|
|
gint num_cols; /* Number of columns */
|
|
|
|
gint *col_fmt; /* Format of column */
|
|
|
|
gboolean **fmt_matx; /* Specifies which formats apply to a column */
|
|
|
|
gint *col_first; /* First column number with a given format */
|
|
|
|
gint *col_last; /* Last column number with a given format */
|
|
|
|
gchar **col_title; /* Column titles */
|
|
|
|
const gchar **col_data; /* Column data */
|
|
|
|
gchar **col_buf; /* Buffer into which to copy data for column */
|
|
|
|
int *col_fence; /* Stuff in column buffer before this index is immutable */
|
|
|
|
gchar **col_expr; /* Filter expression */
|
|
|
|
gchar **col_expr_val; /* Value for filter expression */
|
2005-08-24 18:35:54 +00:00
|
|
|
gboolean writable; /* Are we still writing to the columns? */
|
2001-04-01 03:42:00 +00:00
|
|
|
} column_info;
|
|
|
|
|
|
|
|
/*
|
|
|
|
* All of the possible columns in summary listing.
|
|
|
|
*
|
|
|
|
* NOTE: The SRC and DST entries MUST remain in this order, or else you
|
|
|
|
* need to fix the offset #defines before get_column_format!
|
|
|
|
*/
|
|
|
|
enum {
|
|
|
|
COL_NUMBER, /* Packet list item number */
|
|
|
|
COL_CLS_TIME, /* Command line-specified time (default relative) */
|
|
|
|
COL_REL_TIME, /* Relative time */
|
|
|
|
COL_ABS_TIME, /* Absolute time */
|
|
|
|
COL_ABS_DATE_TIME, /* Absolute date and time */
|
|
|
|
COL_DELTA_TIME, /* Delta time */
|
|
|
|
COL_DEF_SRC, /* Source address */
|
|
|
|
COL_RES_SRC, /* Resolved source */
|
|
|
|
COL_UNRES_SRC, /* Unresolved source */
|
|
|
|
COL_DEF_DL_SRC, /* Data link layer source address */
|
|
|
|
COL_RES_DL_SRC, /* Resolved DL source */
|
|
|
|
COL_UNRES_DL_SRC, /* Unresolved DL source */
|
|
|
|
COL_DEF_NET_SRC, /* Network layer source address */
|
|
|
|
COL_RES_NET_SRC, /* Resolved net source */
|
|
|
|
COL_UNRES_NET_SRC, /* Unresolved net source */
|
|
|
|
COL_DEF_DST, /* Destination address */
|
|
|
|
COL_RES_DST, /* Resolved dest */
|
|
|
|
COL_UNRES_DST, /* Unresolved dest */
|
|
|
|
COL_DEF_DL_DST, /* Data link layer dest address */
|
|
|
|
COL_RES_DL_DST, /* Resolved DL dest */
|
|
|
|
COL_UNRES_DL_DST, /* Unresolved DL dest */
|
|
|
|
COL_DEF_NET_DST, /* Network layer dest address */
|
|
|
|
COL_RES_NET_DST, /* Resolved net dest */
|
|
|
|
COL_UNRES_NET_DST, /* Unresolved net dest */
|
|
|
|
COL_DEF_SRC_PORT, /* Source port */
|
|
|
|
COL_RES_SRC_PORT, /* Resolved source port */
|
|
|
|
COL_UNRES_SRC_PORT, /* Unresolved source port */
|
|
|
|
COL_DEF_DST_PORT, /* Destination port */
|
|
|
|
COL_RES_DST_PORT, /* Resolved dest port */
|
|
|
|
COL_UNRES_DST_PORT, /* Unresolved dest port */
|
|
|
|
COL_PROTOCOL, /* Protocol */
|
|
|
|
COL_INFO, /* Description */
|
|
|
|
COL_PACKET_LENGTH, /* Packet length in bytes */
|
2004-01-31 04:10:05 +00:00
|
|
|
COL_CUMULATIVE_BYTES, /* Cumulative number of bytes */
|
2002-12-08 02:32:36 +00:00
|
|
|
COL_OXID, /* Fibre Channel OXID */
|
|
|
|
COL_RXID, /* Fibre Channel RXID */
|
2002-12-10 00:12:59 +00:00
|
|
|
COL_IF_DIR, /* FW-1 monitor interface/direction */
|
2002-12-10 01:17:21 +00:00
|
|
|
COL_CIRCUIT_ID, /* Circuit ID */
|
2003-01-22 06:26:36 +00:00
|
|
|
COL_SRCIDX, /* Src port idx - Cisco MDS-specific */
|
|
|
|
COL_DSTIDX, /* Dst port idx - Cisco MDS-specific */
|
|
|
|
COL_VSAN, /* VSAN - Cisco MDS-specific */
|
2004-07-05 09:29:06 +00:00
|
|
|
COL_TX_RATE, /* IEEE 802.11 - TX rate in Mbps */
|
|
|
|
COL_RSSI, /* IEEE 802.11 - received signal strength */
|
2005-04-01 10:17:05 +00:00
|
|
|
COL_HPUX_SUBSYS, /* HP-UX Nettl Subsystem */
|
|
|
|
COL_HPUX_DEVID, /* HP-UX Nettl Device ID */
|
2006-06-26 20:46:15 +00:00
|
|
|
COL_DCE_CALL, /* DCE/RPC connection oriented call id OR datagram sequence number */
|
|
|
|
COL_DCE_CTX, /* DCE/RPC connection oriented context id */
|
2006-01-20 08:48:43 +00:00
|
|
|
COL_8021Q_VLAN_ID, /* 802.1Q vlan ID */
|
2006-12-11 20:24:51 +00:00
|
|
|
COL_DSCP_VALUE, /* IP DSCP Value */
|
|
|
|
COL_COS_VALUE, /* L2 COS Value */
|
2007-01-18 18:43:30 +00:00
|
|
|
COL_TEI, /* Q.921 TEI */
|
|
|
|
COL_FR_DLCI, /* Frame Relay DLCI */
|
|
|
|
COL_BSSGP_TLLI, /* GPRS BSSGP IE TLLI */
|
2001-04-01 03:42:00 +00:00
|
|
|
NUM_COL_FMTS /* Should always be last */
|
|
|
|
};
|
|
|
|
|
2007-01-18 18:43:30 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif /* __cplusplus */
|
2001-04-01 03:42:00 +00:00
|
|
|
|
2007-01-18 18:43:30 +00:00
|
|
|
#endif /* __COLUMN_INFO_H__ */
|