|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T c
Length: 5175 (0x1437)
Types: TextFile
Names: »console.h«
└─⟦2d1937cfd⟧ Bits:30007241 EUUGD22: P.P 5.0
└─⟦dc59850a2⟧ »EurOpenD22/pp5.0/pp-5.tar.Z«
└─⟦e5a54fb17⟧
└─⟦this⟧ »pp-5.0/Src/MTAconsole/console.h«
/* console.h: include file for MTA console */
/*
* @(#) $Header: /cs/research/pp/hubris/pp-beta/Src/MTAconsole/RCS/console.h,v 5.0 90/09/20 16:20:23 pp Exp Locker: pp $
*
* $Log: console.h,v $
* Revision 5.0 90/09/20 16:20:23 pp
* rcsforce : 5.0 public release
*
*
*/
#ifndef _H_MTACONSOLE_CONSOLE
#define _H_MTACONSOLE_CONSOLE
#include <isode/rosy.h>
#include "util.h"
#include <isode/cmd_srch.h>
#include "Qmgr-types.h"
#include <X11/Intrinsic.h>
#if defined(XtSpecificationRelease) && XtSpecificationRelease == 4
#define R4
#endif
#include <X11/StringDefs.h>
#include <X11/Shell.h>
#ifdef R4
#include <X11/Xaw/Form.h>
#include <X11/Xaw/Command.h>
#include <X11/Xaw/Viewport.h>
#include <X11/Xaw/Box.h>
#include <X11/Xaw/Label.h>
#include <X11/Xaw/Text.h>
#include <X11/Xaw/AsciiText.h>
#include <X11/Xaw/Paned.h>
#include <X11/Xaw/StripChart.h>
#else /* R3 */
#include <X11/Form.h>
#include <X11/Command.h>
#include <X11/Viewport.h>
#include <X11/Box.h>
#include <X11/Label.h>
#include <X11/Text.h>
#include <X11/AsciiText.h>
#include <X11/VPaned.h>
#endif
#include "WidgetWrap.h"
/* commented out
#define WidgetSet XtVaSetValues
#define WidgetGet XtVaGetValues
#define WidgetCreate XtVaCreateManagedWidget
********** */
typedef struct procStatus {
char enabled; /* boolean TRUE or FALSE */
time_t lastAttempt,
cachedUntil,
lastSuccess;
} ProcStatus;
typedef struct tailor {
char *key;
double ub_number,
ub_volume,
ub_age,
ub_last;
struct tailor *next;
} TailorInfo;
/* 4 factors (num, vol, age, last) == max 400 % */
#define max_bad_channel 400
/* 4 factors (num, vol, age, last) == max 400 % */
#define max_bad_mta 400
/* 2 factors (vol, age) == max 200 % */
#define max_bad_msg 200
typedef struct permsginfo {
char *queueid;
char *originator;
char *contenttype;
char *eit;
int priority;
int size;
time_t expiryTime;
time_t deferredTime;
time_t age;
int errorCount;
char *inChannel;
char *uaContentId;
} Permsginfo;
typedef struct recip {
int id;
char *recipient;
char *mta;
char *actChan;
char *chansOutstanding;
struct procStatus *status;
char *info;
struct recip *next;
} Recip;
typedef struct msg_struct {
struct permsginfo *msginfo;
struct recip *reciplist;
struct tailor *tai;
} Msg_struct;
typedef struct mta_struct {
char *mta;
time_t oldestMessage;
int numberMessages,
numberReports,
volumeMessages;
struct procStatus *status;
int priority;
char active;
char *info;
struct tailor *tai;
} Mta_struct;
typedef struct chan_struct {
char *channelname,
*channeldescrip;
time_t oldestMessage;
int numberMessages,
numberReports,
volumeMessages,
numberActiveProcesses;
struct procStatus *status;
int priority;
struct mta_struct **mtalist;
int num_mtas;
int display_num;
int inbound;
int outbound;
int chantype;
int maxprocs;
struct tailor *tai;
} Chan_struct;
typedef struct mta_disp_struct {
Widget widget;
struct mta_struct *mta;
} Mta_disp_struct;
typedef struct msg_disp_struct {
Widget widget;
struct msg_struct *msg;
} Msg_disp_struct;
typedef struct monitor_item {
Widget form,
chan,
box;
Mta_disp_struct **mtas;
int num_allocd; /* num allocd for mtas */
int num_mtas; /* num of mtas actual being displayed */
struct chan_struct **channel; /* actual being displayed */
} Monitor_item;
typedef struct color_item {
int badness;
XColor colour;
} Color_item;
typedef enum {
unknown,
quit, connect, disconnect, quecontrol,
chanread, chanstop, chanstart,
chancacheadd, chandownforce, chanclear, chaninfo,
mtaread, mtastop, mtastart,
mtacacheadd, mtaforce, mtadownforce, mtaclear, mtainfo,
readchannelmtamessage, msgstop, msgstart,
msgcacheadd, msgforce, msgclear, msginfo,
mtacontrol
} Operations;
typedef struct popup_tuple {
Widget label,
text;
char *str;
} Popup_tuple;
typedef struct popup_menu {
Widget popup,
form;
int numberOftuples,
selected;
Operations op;
Popup_tuple *tuple;
} Popup_menu;
/* -- defines for config --- */
#define REFRESH 0
#define INACTIVE 1
#define START 2
#define BACKOFF 3
#define CONNECTMAX 4
#define PERCENT 5
#define MINBADMTA 6
#define LINEMAX 7
typedef enum { percentage, line, all} Heuristic;
typedef enum { notconnected, connecting, connected} State;
typedef enum { limited, full} Authentication;
typedef enum { inactive, green, yellow, red} Colour;
typedef enum { control, monitor} Mode;
#define APPLICATION_NAME "xconsole"
#define APPLICATION_CLASS "MTAconsole"
#define MAX_EDIT_STRING 100
#define NO_CONNECTION "Unconnected"
typedef struct server_dispatch {
char *ds_name;
int ds_operation;
IFP ds_vector;
} Server_dispatch;
typedef struct client_dispatch {
char *ds_name;
int ds_operation;
IFP ds_argument;
IFP ds_free;
IFP ds_result;
IFP ds_error;
char *ds_help;
} Client_dispatch;
#define PERCENT_BASED "percent based"
#define LINE_BASED "line based"
#define ALL_BASED "all"
#endif