ET System  16.4
 All Data Structures Files Functions Variables Typedefs Macros Groups Pages
et.h File Reference
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pthread.h>
#include <stdint.h>
#include <inttypes.h>

Go to the source code of this file.

Data Structures

struct  et_event_t
 This structure defines an Event which exists in shared memory, holds data, and gets passed from station to station. More...
 

Macros

#define INET_ATON_ERR   0
 
#define ET_STATION_CUE   10
 Max number of events queued in nonblocking station. More...
 
#define ET_STATION_PRESCALE   1
 Default prescale of blocking stations. More...
 
#define ET_SYSTEM_EVENTS   300
 Default total number of events in ET system. More...
 
#define ET_SYSTEM_NTEMPS   300
 Default max number of temp events in ET system. More...
 
#define ET_SYSTEM_ESIZE   1000
 Default size of normal events in bytes. More...
 
#define ET_SYSTEM_NSTATS   200
 Default max number of stations. More...
 
#define ET_UDP_PORT   11111
 Default ET system UDP broad/multicast/directed-udp port. More...
 
#define ET_SERVER_PORT   11111
 Default ET system TCP server port. More...
 
#define ET_MULTICAST_PORT   11111
 
#define ET_BROADCAST_PORT   11111
 
#define ET_MULTICAST_ADDR   "239.200.0.0"
 Default multicast address to use in finding ET system. More...
 
#define ET_EVENT_GROUPS_MAX   200
 Default max number of groups events are divided into. More...
 
#define ET_STATION_SELECT_INTS   6
 Number of control integers associated with each station. More...
 
#define ET_MULTICAST_TTL   32
 Default multicast time-to-live value (# of router hops permitted). More...
 
#define ET_HOST_LOCAL   ".local"
 ET host is local. More...
 
#define ET_HOST_REMOTE   ".remote"
 ET host is remote. More...
 
#define ET_HOST_ANYWHERE   ".anywhere"
 ET host is either local or remote. More...
 
#define ET_HOST_AS_LOCAL   1
 For communication with local ET system, use shared memory. More...
 
#define ET_HOST_AS_REMOTE   0
 For communication with local ET system, use sockets. More...
 
#define ET_POLICY_FIRST   0
 Pick first responder when broad/multicasting to find ET system. More...
 
#define ET_POLICY_LOCAL   1
 Pick local responder, else the first when broad/multicasting to find ET system. More...
 
#define ET_POLICY_ERROR   2
 Return an error if more than one responder when broad/multicasting to find ET system. More...
 
#define ET_FILENAME_LENGTH   100
 Max length of ET system file name + 1. More...
 
#define ET_FUNCNAME_LENGTH   48
 Max length of user's event selection func name + 1. More...
 
#define ET_STATNAME_LENGTH   48
 Max length of station name + 1. More...
 
#define ET_TEMPNAME_LENGTH   (ET_FILENAME_LENGTH+12)
 Max length of temp event file name + 1, leaves room for _temp<#######>. More...
 
#define ET_GRANDCENTRAL   0
 Station id of GrandCentral station. More...
 
#define ET_STATION_UNUSED   0
 Station structure is unused. More...
 
#define ET_STATION_CREATING   1
 Station is in the middle of being created. More...
 
#define ET_STATION_IDLE   2
 Station exists but has no attachments. More...
 
#define ET_STATION_ACTIVE   3
 Station exists and has at least one attachment. More...
 
#define ET_STATION_USER_MULTI   0
 Multiple attachments are allowed on a single station. More...
 
#define ET_STATION_USER_SINGLE   1
 Only one attachment is allowed on a single station. More...
 
#define ET_STATION_NONBLOCKING   0
 Events bypass station when input queue is full. More...
 
#define ET_STATION_BLOCKING   1
 Station accepts all events (except if prescaling > 1 or if selection rule rejects them). More...
 
#define ET_STATION_SELECT_ALL   1
 Select all events into station. More...
 
#define ET_STATION_SELECT_MATCH   2
 Select events using predefined selection rule. More...
 
#define ET_STATION_SELECT_USER   3
 Select event with user-supplied selection rule. More...
 
#define ET_STATION_SELECT_RROBIN   4
 For parallel stations, select events with round-robin distribution. More...
 
#define ET_STATION_SELECT_EQUALCUE   5
 For parallel stations, select events such that all input queues have the same number of events. More...
 
#define ET_STATION_RESTORE_OUT   0
 Restore recovered events to output list. More...
 
#define ET_STATION_RESTORE_IN   1
 Restore recovered events to input list. More...
 
#define ET_STATION_RESTORE_GC   2
 Restore recovered events to GrandCentral input list. More...
 
#define ET_STATION_RESTORE_REDIST   3
 Redistribute recovered events to input of all parallel stations, along with all events left in station's input list. More...
 
#define ET_STATION_SERIAL   0
 normal flow of all events through all stations. More...
 
#define ET_STATION_PARALLEL   1
 station is part of a group of stations in which events are flowing in parallel. More...
 
#define ET_STATION_PARALLEL_HEAD   2
 station is head of a group of stations in which events are flowing in parallel. More...
 
#define ET_OK   0
 No error. More...
 
#define ET_ERROR   -1
 General error. More...
 
#define ET_ERROR_TOOMANY   -2
 Too many somethings (stations, attachments, temp events, ET system responses) exist. More...
 
#define ET_ERROR_EXISTS   -3
 ET system file or station already exists. More...
 
#define ET_ERROR_WAKEUP   -4
 Sleeping routine woken up by et_wakeup_attachment() or et_wakeup_all(). More...
 
#define ET_ERROR_TIMEOUT   -5
 Timed out. More...
 
#define ET_ERROR_EMPTY   -6
 No events available in async mode. More...
 
#define ET_ERROR_BUSY   -7
 Resource is busy. More...
 
#define ET_ERROR_DEAD   -8
 ET system is dead. More...
 
#define ET_ERROR_READ   -9
 Network read error. More...
 
#define ET_ERROR_WRITE   -10
 Network write error,. More...
 
#define ET_ERROR_REMOTE   -11
 Cannot allocate memory in remote client. More...
 
#define ET_ERROR_NOREMOTE   -12
 (Currently not used). More...
 
#define ET_ERROR_TOOBIG   -13
 Client is 32 bits & server is 64 (or vice versa) and event is too big for one. More...
 
#define ET_ERROR_NOMEM   -14
 Cannot allocate memory. More...
 
#define ET_ERROR_BADARG   -15
 Bad argument given to function. More...
 
#define ET_ERROR_SOCKET   -16
 Socket option could not be set. More...
 
#define ET_ERROR_NETWORK   -17
 Host name or address could not be resolved, or cannot connect. More...
 
#define ET_ERROR_CLOSED   -18
 ET system has been closed by client. More...
 
#define ET_ERROR_JAVASYS   -19
 C code trying to open Java-based ET system file locally. More...
 
#define ET_DEBUG_NONE   0
 No debug output. More...
 
#define ET_DEBUG_SEVERE   1
 Debug output for severe errors only. More...
 
#define ET_DEBUG_ERROR   2
 Debug output for all errors. More...
 
#define ET_DEBUG_WARN   3
 Debug output for warnings and all errors. More...
 
#define ET_DEBUG_INFO   4
 Debug output for warnings, errors, and general information. More...
 
#define ET_LOW   0
 Event is of normal priority. More...
 
#define ET_HIGH   1
 Event is of high priority which means it get placed at the top of each station in/output list (but below other high priority events). More...
 
#define ET_PRIORITY_MASK   1
 Bit mask used to send priority bits over network. More...
 
#define ET_SYS   -1
 Event owner is the ET system (not an attachment or user-process). More...
 
#define ET_END   -1
 When creating a new station, put at end of a linked list. More...
 
#define ET_NEWHEAD   -2
 When creating a new parallel station, put at head of a new group of parallel stations and in the main linked list of stations. More...
 
#define ET_EVENT_TEMP   1
 Event is temporary (bigger than normal events with shared memory especially allocated for it alone). More...
 
#define ET_EVENT_NORMAL   0
 Normal ET system event existing in main shared memory. More...
 
#define ET_EVENT_NEW   1
 Event obtained through calling et_event_new, et_events_new, et_event_new_group, or et_events_new_group. More...
 
#define ET_EVENT_USED   0
 Event obtained through calling et_event_get or et_events_get. More...
 
#define ET_SLEEP   0
 When getting events, wait until at least one is available before returning. More...
 
#define ET_TIMED   1
 When getting events, wait until either an event is available or the given time has expired before returning. More...
 
#define ET_ASYNC   2
 When getting events, return immediately if no event is available. More...
 
#define ET_WAIT_MASK   3
 Bit mask for mode's wait info. More...
 
#define ET_MODIFY   4
 Remote user will modify event. More...
 
#define ET_MODIFY_HEADER   8
 Remote user will modify only event header (metadata). More...
 
#define ET_DUMP   16
 If remote get and not modifying event, server dumps (not puts) events automatically back into ET. More...
 
#define ET_NOALLOC   32
 Remote user will not allocate memory but use existing buffer. More...
 
#define ET_OPEN_NOWAIT   0
 Do not wait for the ET system to appear when trying to open it. More...
 
#define ET_OPEN_WAIT   1
 Wait for the ET system to appear when trying to open it. More...
 
#define ET_REMOTE   0
 ET system is on a remote host. More...
 
#define ET_LOCAL   1
 ET system is on the local host. More...
 
#define ET_LOCAL_NOSHARE   2
 ET system is on the local host, but it is not possible to share pthread mutexes. More...
 
#define ET_MULTICAST   0
 Use multicasting to find ET system. More...
 
#define ET_BROADCAST   1
 Use broadcasting to find ET system. More...
 
#define ET_DIRECT   2
 Connect directly to ET system TCP server by specifying host & port explicitly. More...
 
#define ET_BROADANDMULTICAST   3
 Use broad and multicasting to find ET system. More...
 
#define ET_SUBNET_ALL   ".subnetsAll"
 Use all local subnets. More...
 
#define ET_DATA_OK   0
 Event data is OK. More...
 
#define ET_DATA_CORRUPT   1
 Event data is corrupt (currently not used). More...
 
#define ET_DATA_POSSIBLY_CORRUPT   2
 Event data is possibly corrupt as event was recovered from user crash. More...
 
#define ET_DATA_MASK   0x30
 Bit mask for network handling of data status. More...
 
#define ET_DATA_SHIFT   4
 Bit shift for network handling of data status. More...
 
#define ET_ENDIAN_BIG   0
 Big endian. More...
 
#define ET_ENDIAN_LITTLE   1
 Little endian. More...
 
#define ET_ENDIAN_LOCAL   2
 Same endian as local host. More...
 
#define ET_ENDIAN_NOTLOCAL   3
 Opposite endian as local host. More...
 
#define ET_ENDIAN_SWITCH   4
 Switch recorded value of data's endian. More...
 
#define ET_NOSWAP   0
 Event data endian is same as local host. More...
 
#define ET_SWAP   1
 Event data must be swapped to be consistent with local host endian. More...
 
#define ET_SWAP16(x)
 Macro to swap endian of 64 bit arg. More...
 
#define ET_SWAP32(x)
 Macro for swapping 32 bit types. More...
 
#define ET_SWAP64(x)
 Macro for swapping 64 bit types. More...
 
#define err_abort(code, text)
 Macro to exit program with unrecoverable error (see "Programming with POSIX threads' by Butenhof). More...
 

Typedefs

typedef struct et_event_t et_event
 This structure defines an Event which exists in shared memory, holds data, and gets passed from station to station. More...
 
typedef int(* ET_SWAP_FUNCPTR )(et_event *, et_event *, int, int)
 Used to define a data-swapping function. More...
 
typedef void * et_sys_id
 ET system id. More...
 
typedef void * et_statconfig
 ET station configuration. More...
 
typedef void * et_sysconfig
 ET system configuration. More...
 
typedef void * et_openconfig
 ET open configuration. More...
 
typedef void * et_bridgeconfig
 ET bridge id. More...
 
typedef int et_stat_id
 ET station id. More...
 
typedef int et_proc_id
 ET process id. More...
 
typedef int et_att_id
 ET attachment id. More...
 

Functions

int et_event_new (et_sys_id id, et_att_id att, et_event **pe, int mode, struct timespec *deltatime, size_t size)
 This routine is called when a user wants a blank or fresh event from the ET system into which data can be placed. More...
 
int et_events_new (et_sys_id id, et_att_id att, et_event *pe[], int mode, struct timespec *deltatime, size_t size, int num, int *nread)
 This routine is called when a user wants an array of blank or fresh events from the ET system into which data can be placed. More...
 
int et_event_new_group (et_sys_id id, et_att_id att, et_event **pe, int mode, struct timespec *deltatime, size_t size, int group)
 This routine is called when a user wants a blank or fresh event from the ET system into which it can place data and that event must belong to the given group. More...
 
int et_events_new_group (et_sys_id id, et_att_id att, et_event *pe[], int mode, struct timespec *deltatime, size_t size, int num, int group, int *nread)
 This routine is called when a user wants an array of blank or fresh event from the ET system into which it can place data and those events must belong to the given group. More...
 
int et_event_get (et_sys_id id, et_att_id att, et_event **pe, int mode, struct timespec *deltatime)
 This routine is called when a user wants to read a single event from the ET system. More...
 
int et_events_get (et_sys_id id, et_att_id att, et_event *pe[], int mode, struct timespec *deltatime, int num, int *nread)
 This routine is called when a user wants to read an array of events from the ET system. More...
 
int et_event_put (et_sys_id id, et_att_id att, et_event *pe)
 This routine is called when a user wants to return a single, previously read or new event into the ET system so processes downstream can use it or so it can be returned to ET_GRANDCENTRAL station. More...
 
int et_events_put (et_sys_id id, et_att_id att, et_event *pe[], int num)
 This routine is called when a user wants to return an array of previously read or new events into the ET system so processes downstream can use it or so it can be returned to ET_GRANDCENTRAL station. More...
 
int et_event_dump (et_sys_id id, et_att_id att, et_event *pe)
 This routine is called when a user wants to get rid of a single, previously read or new event so that no user processes downstream will ever see it. More...
 
int et_events_dump (et_sys_id id, et_att_id att, et_event *pe[], int num)
 This routine is called when a user wants to get rid of an array of previously read or new events so that no user processes downstream will ever see them. More...
 
int et_event_getgroup (et_event *pe, int *grp)
 This routine gets the group number that the event is associated with. More...
 
int et_event_setpriority (et_event *pe, int pri)
 This routine sets the priority of an event to either ET_LOW which is the default or ET_HIGH. More...
 
int et_event_getpriority (et_event *pe, int *pri)
 This routine gets the priority of an event, either ET_LOW or ET_HIGH. More...
 
int et_event_setlength (et_event *pe, size_t len)
 This routine sets the length of an event's data in bytes. More...
 
int et_event_getlength (et_event *pe, size_t *len)
 This routine gets the length of an event's data in bytes. More...
 
int et_event_setcontrol (et_event *pe, int con[], int num)
 This routine sets the control array of an event. More...
 
int et_event_getcontrol (et_event *pe, int con[])
 This routine gets the control array of an event. More...
 
int et_event_setdatastatus (et_event *pe, int datastatus)
 This routine sets an event's data status. More...
 
int et_event_getdatastatus (et_event *pe, int *datastatus)
 This routine gets an event's data status. More...
 
int et_event_setendian (et_event *pe, int endian)
 This routine sets an event's data endian value. More...
 
int et_event_getendian (et_event *pe, int *endian)
 This routine gets an event's data endian value. More...
 
int et_event_getdata (et_event *pe, void **data)
 This routine gets the pointer to an event's data. More...
 
int et_event_setdatabuffer (et_sys_id id, et_event *pe, void *data)
 This routine set an event's data buffer for a remote user. More...
 
int et_event_needtoswap (et_event *pe, int *swap)
 This routine indicates whether an event's data needs to be swapped or not. More...
 
int et_open (et_sys_id *id, const char *filename, et_openconfig openconfig)
 This routine opens an ET system for client use. More...
 
int et_close (et_sys_id id)
 This routine closes an open ET system. More...
 
int et_forcedclose (et_sys_id id)
 This routine closes an open ET system but differs from et_close in that it automatically closes all attachments. More...
 
int et_kill (et_sys_id id)
 This routine kills an open ET system. More...
 
int et_system_start (et_sys_id *id, et_sysconfig sconfig)
 This routine creates an ET system. More...
 
int et_system_close (et_sys_id id)
 This routine closes or shuts down an ET system. More...
 
int et_alive (et_sys_id id)
 This routine tells if an open ET system is alive (heartbeat is going). More...
 
int et_wait_for_alive (et_sys_id id)
 This routine waits until given ET system is alive. More...
 
char * et_perror (int err)
 This routine returns a string describing the given error condition. More...
 
int et_wakeup_attachment (et_sys_id id, et_att_id att)
 This routine wakes up a specific attachment waiting to read events. More...
 
int et_wakeup_all (et_sys_id id, et_stat_id stat_id)
 This routine wakes up all attachments waiting to read events. More...
 
int et_attach_geteventsput (et_sys_id id, et_att_id att_id, uint64_t *events)
 This routine gets the number of events an attachment put by calling et_event_put or et_events_put. More...
 
int et_attach_geteventsget (et_sys_id id, et_att_id att_id, uint64_t *events)
 This routine gets the number of events an attachment obtained by calling et_event_get, or et_events_get. More...
 
int et_attach_geteventsdump (et_sys_id id, et_att_id att_id, uint64_t *events)
 This routine gets the number of events an attachment dumped by calling et_event_dump, or et_events_dump. More...
 
int et_attach_geteventsmake (et_sys_id id, et_att_id att_id, uint64_t *events)
 This routine gets the number of events an attachment created by calling et_event_new, et_events_new, et_event_new_group, or et_events_new_group. More...
 
int et_station_create_at (et_sys_id id, et_stat_id *stat_id, const char *stat_name, et_statconfig sconfig, int position, int parallelposition)
 This routine creates a station provided that it does not already exist and the maximum number of stations has not been reached. More...
 
int et_station_create (et_sys_id id, et_stat_id *stat_id, const char *stat_name, et_statconfig sconfig)
 This routine creates a station provided that it does not already exist and the maximum number of stations has not been reached. More...
 
int et_station_remove (et_sys_id id, et_stat_id stat_id)
 This routine deletes a station provided it is not GRAND_CENTRAL and provided there are no attached processes. More...
 
int et_station_attach (et_sys_id id, et_stat_id stat_id, et_att_id *att)
 This routine will attach the user to a station. More...
 
int et_station_detach (et_sys_id id, et_att_id att)
 This routine will detach the user from a station. More...
 
int et_station_setposition (et_sys_id id, et_stat_id stat_id, int position, int parallelposition)
 This routine sets a station's position in the linked list of active and idle stations and its position within a group of parallel stations if it is one. More...
 
int et_station_getposition (et_sys_id id, et_stat_id stat_id, int *position, int *parallelposition)
 This routine gets a station's position in the linked list of active and idle stations and its position within a group of parallel stations if it is one. More...
 
int et_station_config_init (et_statconfig *sconfig)
 This routine initializes a configuration used to create a station in the ET system. More...
 
int et_station_config_destroy (et_statconfig sconfig)
 This routine frees the memory allocated when a configuration is initialized by et_station_config_init(). More...
 
int et_station_config_setblock (et_statconfig sconfig, int val)
 This routine sets a station configuration's block mode. More...
 
int et_station_config_getblock (et_statconfig sconfig, int *val)
 This routine gets a station configuration's block mode. More...
 
int et_station_config_setflow (et_statconfig sconfig, int val)
 This routine sets a station configuration's flow mode. More...
 
int et_station_config_getflow (et_statconfig sconfig, int *val)
 This routine gets a station configuration's flow mode. More...
 
int et_station_config_setselect (et_statconfig sconfig, int val)
 This routine sets a station configuration's select mode which determines the algorithm this station uses to decide which events to let into its input list. More...
 
int et_station_config_getselect (et_statconfig sconfig, int *val)
 This routine gets a station configuration's select mode. More...
 
int et_station_config_setuser (et_statconfig sconfig, int val)
 This routine sets a station configuration's user mode which is the maximum number of users which may simultaneously attach to the station. More...
 
int et_station_config_getuser (et_statconfig sconfig, int *val)
 This routine gets a station configuration's user mode. More...
 
int et_station_config_setrestore (et_statconfig sconfig, int val)
 This routine sets a station configuration's restore mode which determines where events go when the attachment that owns those events detaches from the station. More...
 
int et_station_config_getrestore (et_statconfig sconfig, int *val)
 This routine gets a station configuration's restore mode which determines where events go when the attachment who owns those events detaches from the station. More...
 
int et_station_config_setcue (et_statconfig sconfig, int val)
 This routine sets a station configuration's queue size which is the max number of events allowed in the input list when the station is nonblocking. More...
 
int et_station_config_getcue (et_statconfig sconfig, int *val)
 This routine gets a station configuration's queue size which is the max number of events allowed in the input list when the station is nonblocking. More...
 
int et_station_config_setprescale (et_statconfig sconfig, int val)
 This routine sets a station configuration's prescale value. More...
 
int et_station_config_getprescale (et_statconfig sconfig, int *val)
 This routine gets a station configuration's prescale value. More...
 
int et_station_config_setselectwords (et_statconfig sconfig, int val[])
 This routine sets a station configuration's array of selection integers. More...
 
int et_station_config_getselectwords (et_statconfig sconfig, int val[])
 This routine gets a station configuration's array of selection integers. More...
 
int et_station_config_setfunction (et_statconfig sconfig, const char *val)
 This routine sets a station configuration's name of the user-defined function which is loaded from a shared library and used for selecting events. More...
 
int et_station_config_getfunction (et_statconfig sconfig, char *val)
 This routine gets a station configuration's name of the user-defined function which is loaded from a shared library and used for selecting events (may be NULL). More...
 
int et_station_config_setlib (et_statconfig sconfig, const char *val)
 This routine sets a station configuration's name of the shared library which is used for loading a user's function to select events. More...
 
int et_station_config_getlib (et_statconfig sconfig, char *val)
 This routine gets a station configuration's name of the shared library which is used for loading a user's function to select events (may be NULL). More...
 
int et_station_config_setclass (et_statconfig sconfig, const char *val)
 This routine sets a station configuration's name of the Java class which is used for loading a user's function to select events. More...
 
int et_station_config_getclass (et_statconfig sconfig, char *val)
 This routine gets a station configuration's name of the Java class which is used for loading a user's function to select events. More...
 
int et_station_isattached (et_sys_id id, et_stat_id stat_id, et_att_id att)
 Is an attachment attached to a particular station? More...
 
int et_station_exists (et_sys_id id, et_stat_id *stat_id, const char *stat_name)
 This routine tells whether a station exists or not, given the name of a station, If it does, it gives its id. More...
 
int et_station_name_to_id (et_sys_id id, et_stat_id *stat_id, const char *stat_name)
 This routine gives a station id, given the name of a station,. More...
 
int et_station_getattachments (et_sys_id id, et_stat_id stat_id, int *numatts)
 This routine gets the number of attachments to the given station. More...
 
int et_station_getstatus (et_sys_id id, et_stat_id stat_id, int *status)
 This routine gets the status of a station which may be one of the following values. More...
 
int et_station_getinputcount (et_sys_id id, et_stat_id stat_id, int *cnt)
 This routine gets the number of events in a station's input list. More...
 
int et_station_getoutputcount (et_sys_id id, et_stat_id stat_id, int *cnt)
 This routine gets the number of events in a station's output list. More...
 
int et_station_getselect (et_sys_id id, et_stat_id stat_id, int *select)
 This routine gets a station's select mode which determines the algorithm this station uses to decide which events to let into its input list. More...
 
int et_station_getlib (et_sys_id id, et_stat_id stat_id, char *lib)
 This routine gets the name of the shared library containing an event selection function provided by the user. More...
 
int et_station_getclass (et_sys_id id, et_stat_id stat_id, char *classs)
 This routine gets the Java class defining an event selection method provided by the user for Java-based ET systems. More...
 
int et_station_getfunction (et_sys_id id, et_stat_id stat_id, char *function)
 This routine gets the name of the selection function in the shared library provided by the user. More...
 
int et_station_getblock (et_sys_id id, et_stat_id stat_id, int *block)
 This routine gets the block mode of a station which may be ET_STATION_BLOCKING or ET_STATION_NONBLOCKING. More...
 
int et_station_setblock (et_sys_id id, et_stat_id stat_id, int block)
 This routine sets a station's block mode. More...
 
int et_station_getrestore (et_sys_id id, et_stat_id stat_id, int *restore)
 This routine gets a station's restore mode which determines where events go when the attachment that owns those events detaches from a station. More...
 
int et_station_setrestore (et_sys_id id, et_stat_id stat_id, int restore)
 This routine sets a station's restore mode which determines where events go when the attachment that owns those events detaches from a station. More...
 
int et_station_getuser (et_sys_id id, et_stat_id stat_id, int *user)
 This routine gets a station's user mode which is the maximum number of simultaneous attachments allowed with 0 meaning multiple. More...
 
int et_station_setuser (et_sys_id id, et_stat_id stat_id, int user)
 This routine sets a station's user mode which is the maximum number of simultaneous attachments allowed to a station. More...
 
int et_station_getprescale (et_sys_id id, et_stat_id stat_id, int *prescale)
 This routine gets a station's prescale value. More...
 
int et_station_setprescale (et_sys_id id, et_stat_id stat_id, int prescale)
 This routine sets a station's prescale value. More...
 
int et_station_getcue (et_sys_id id, et_stat_id stat_id, int *cue)
 This routine gets a station's queue size, the size of the input event list for nonblocking stations. More...
 
int et_station_setcue (et_sys_id id, et_stat_id stat_id, int cue)
 This routine sets a station's queue size, the size of the input event list for nonblocking stations. More...
 
int et_station_getselectwords (et_sys_id id, et_stat_id stat_id, int select[])
 This routine gets a station's array of selection integers used to select events. More...
 
int et_station_setselectwords (et_sys_id id, et_stat_id stat_id, int select[])
 This routine sets a station's array of selection integers used to select events. More...
 
int et_system_config_init (et_sysconfig *sconfig)
 This routine initializes a configuration used to define an ET system. More...
 
int et_system_config_destroy (et_sysconfig sconfig)
 This routine frees the memory allocated when a system configuration is initialized by et_system_config_init. More...
 
int et_system_config_setevents (et_sysconfig sconfig, int val)
 This routine sets the configuration's total number of events. More...
 
int et_system_config_getevents (et_sysconfig sconfig, int *val)
 This routine gets the configuration's total number of events. More...
 
int et_system_config_setsize (et_sysconfig sconfig, size_t val)
 This routine sets the configuration's event size in bytes. More...
 
int et_system_config_getsize (et_sysconfig sconfig, size_t *val)
 This routine gets the configuration's event size in bytes. More...
 
int et_system_config_settemps (et_sysconfig sconfig, int val)
 This routine sets the configuration's maximum number of temporary events. More...
 
int et_system_config_gettemps (et_sysconfig sconfig, int *val)
 This routine gets the configuration's maximum number of temporary events. More...
 
int et_system_config_setstations (et_sysconfig sconfig, int val)
 This routine sets the configuration's maximum number of stations that may be created (including GRAND_CENTRAL). More...
 
int et_system_config_getstations (et_sysconfig sconfig, int *val)
 This routine gets the configuration's maximum number of stations that may be created (including GRAND_CENTRAL). More...
 
int et_system_config_setprocs (et_sysconfig sconfig, int val)
 This routine sets the configuration's maximum number of processes that may be created. More...
 
int et_system_config_getprocs (et_sysconfig sconfig, int *val)
 This routine gets the configuration's maximum number of processes that may be created. More...
 
int et_system_config_setattachments (et_sysconfig sconfig, int val)
 This routine sets the configuration's maximum number of attachments that may be created. More...
 
int et_system_config_getattachments (et_sysconfig sconfig, int *val)
 This routine gets the configuration's maximum number of attachments that may be created. More...
 
int et_system_config_setgroups (et_sysconfig sconfig, int groups[], int size)
 This routine sets the configuration's number of event groups and how many events are in each group. More...
 
int et_system_config_setfile (et_sysconfig sconfig, const char *val)
 This routine sets the configuration's ET system file name. More...
 
int et_system_config_getfile (et_sysconfig sconfig, char *val)
 This routine gets the configuration's ET system file name. More...
 
int et_system_config_setport (et_sysconfig sconfig, int val)
 This routine sets the configuration's UDP listening port used by remote users trying to find the ET system by broad/multicasting. More...
 
int et_system_config_getport (et_sysconfig sconfig, int *val)
 This routine gets the configuration's UDP listening port used by remote users trying to find the ET system by broad/multicasting. More...
 
int et_system_config_setserverport (et_sysconfig sconfig, int val)
 This routine sets the configuration's TCP listening port number used to communicate with remote users. More...
 
int et_system_config_getserverport (et_sysconfig sconfig, int *val)
 This routine gets the configuration's TCP listening port number used to communicate with remote users. More...
 
int et_system_config_addmulticast (et_sysconfig sconfig, const char *val)
 This routine adds a multicast address to a list, each address of which the ET system is listening on for UDP packets from users trying to find it. More...
 
int et_system_config_removemulticast (et_sysconfig sconfig, const char *val)
 This routine removes a multicast address from a list, so that the ET system no longer listens on it for UDP packets from users trying to find the system. More...
 
int et_system_config_settcp (et_sysconfig sconfig, int rBufSize, int sBufSize, int noDelay)
 This routine sets the configuration's TCP socket options used when communicating with remote users over sockets. More...
 
int et_system_config_gettcp (et_sysconfig sconfig, int *rBufSize, int *sBufSize, int *noDelay)
 This routine gets the configuration's TCP socket options used when communicating with remote users over sockets. More...
 
int et_system_setgroup (et_sys_id id, int group)
 This routine sets the default group number of the ET client. More...
 
int et_system_getgroup (et_sys_id id, int *group)
 This routine gets the default group number of the ET client. More...
 
int et_system_setdebug (et_sys_id id, int debug)
 This routine sets the level of debug output for the ET client. More...
 
int et_system_getdebug (et_sys_id id, int *debug)
 This routine gets the level of debug output for the ET client. More...
 
int et_system_getlocality (et_sys_id id, int *locality)
 This routine gets the locality of the ET client. More...
 
int et_system_getnumevents (et_sys_id id, int *numevents)
 This routine gets the number of events in the ET system. More...
 
int et_system_geteventsize (et_sys_id id, size_t *eventsize)
 This routine gets the size of an event in bytes in the ET system. More...
 
int et_system_gettempsmax (et_sys_id id, int *tempsmax)
 This routine gets the maximum number of temporary events allowed in the ET system. More...
 
int et_system_getstationsmax (et_sys_id id, int *stationsmax)
 This routine gets the maximum number of stations allowed in the ET system. More...
 
int et_system_getprocsmax (et_sys_id id, int *procsmax)
 This routine gets the maximum number of local processes that are allowed to open the ET system. More...
 
int et_system_getattsmax (et_sys_id id, int *attsmax)
 This routine gets the maximum number of attachments that are allowed to be made to the ET system. More...
 
int et_system_getheartbeat (et_sys_id id, int *heartbeat)
 This routine gets the current value of the heartbeat of the ET system. More...
 
int et_system_getpid (et_sys_id id, pid_t *pid)
 This routine gets the unix process id of the ET system process. More...
 
int et_system_getprocs (et_sys_id id, int *procs)
 This routine gets the number of local processes that have opened the ET system. More...
 
int et_system_getattachments (et_sys_id id, int *atts)
 This routine gets the number of attachments that have been made to the ET system. More...
 
int et_system_getstations (et_sys_id id, int *stations)
 This routine gets the number of stations in the ET system. More...
 
int et_system_gettemps (et_sys_id id, int *temps)
 This routine gets the number of temporary events currently in the ET system. More...
 
int et_system_getserverport (et_sys_id id, int *port)
 This routine gets the TCP listening port number of the ET system. More...
 
int et_system_gethost (et_sys_id id, char *host)
 This routine gets the host of the ET system. More...
 
int et_system_getlocaladdress (et_sys_id id, char *address)
 This routine gets the local IP address, if any, used to connect remotely to the ET system. More...
 
int et_open_config_init (et_openconfig *sconfig)
 This routine initializes a configuration used to open an ET system. More...
 
int et_open_config_destroy (et_openconfig sconfig)
 This routine frees the memory allocated when an open configuration is initialized by et_open_config_init. More...
 
int et_open_config_setwait (et_openconfig sconfig, int val)
 This routine sets the means to wait for a valid ET system to be detected. More...
 
int et_open_config_getwait (et_openconfig sconfig, int *val)
 This routine gets the means being used to wait for a valid ET system to be detected. More...
 
int et_open_config_setcast (et_openconfig sconfig, int val)
 This routine sets the method for a remote user to discover the ET system. More...
 
int et_open_config_getcast (et_openconfig sconfig, int *val)
 This routine gets the method for a remote user to discover the ET system. More...
 
int et_open_config_setTTL (et_openconfig sconfig, int val)
 This routine sets the "ttl" value for multicasting. More...
 
int et_open_config_getTTL (et_openconfig sconfig, int *val)
 This routine gets the "ttl" value for multicasting. More...
 
int et_open_config_setmode (et_openconfig sconfig, int val)
 This routine sets whether the ET system treats the user running this routine as local (if it is local) or remote even if it is local. More...
 
int et_open_config_getmode (et_openconfig sconfig, int *val)
 This routine gets whether the ET system treats the user running this routine as local (if it is local) or remote even if it is local. More...
 
int et_open_config_setdebugdefault (et_openconfig sconfig, int val)
 This routine sets the default level of debug output. More...
 
int et_open_config_getdebugdefault (et_openconfig sconfig, int *val)
 This routine gets the default level of debug output. More...
 
int et_open_config_setport (et_openconfig sconfig, int val)
 This routine sets the port number for the UDP broad/multicasting used to discover the ET system. More...
 
int et_open_config_getport (et_openconfig sconfig, int *val)
 This routine gets the port number for the UDP broad/multicasting used to discover the ET system. More...
 
int et_open_config_setserverport (et_openconfig sconfig, int val)
 This routine sets the TCP port number for opening an ET system directly without broadcasting or multicasting. More...
 
int et_open_config_getserverport (et_openconfig sconfig, int *val)
 This routine gets the TCP port number for opening an ET system directly without broadcasting or multicasting. More...
 
int et_open_config_settimeout (et_openconfig sconfig, struct timespec val)
 This routine sets the maximum time to wait for a valid ET system to be detected. More...
 
int et_open_config_gettimeout (et_openconfig sconfig, struct timespec *val)
 This routine gets the maximum time to wait for a valid ET system to be detected. More...
 
int et_open_config_setaddress (et_openconfig sconfig, const char *val)
 
int et_open_config_getaddress (et_openconfig sconfig, char *val)
 
int et_open_config_sethost (et_openconfig sconfig, const char *val)
 This routine sets host or computer on which the ET system is running. More...
 
int et_open_config_gethost (et_openconfig sconfig, char *val)
 This routine gets the host or computer on which the ET system is running. More...
 
int et_open_config_addbroadcast (et_openconfig sconfig, const char *val)
 This routine adds an IP subnet broadcast address to a list of destinations used in broadcast discovery of the ET system. More...
 
int et_open_config_removebroadcast (et_openconfig sconfig, const char *val)
 This routine removes an IP subnet broadcast address from a list of destinations used in broadcast discovery of the ET system. More...
 
int et_open_config_addmulticast (et_openconfig sconfig, const char *val)
 This routine adds an IP multicast address to a list of destinations used in multicast discovery of the ET system. More...
 
int et_open_config_removemulticast (et_openconfig sconfig, const char *val)
 This routine removes a multicast address from a list of destinations used in multicast discovery of the ET system. More...
 
int et_open_config_setpolicy (et_openconfig sconfig, int val)
 This routine sets the return policy from calls to et_open. More...
 
int et_open_config_getpolicy (et_openconfig sconfig, int *val)
 This routine gets the return policy from calls to et_open. More...
 
int et_open_config_setinterface (et_openconfig sconfig, const char *val)
 This routine sets the network interface to use when communicating over the network with the ET system. More...
 
int et_open_config_getinterface (et_openconfig sconfig, char *val)
 This routine gets the network interface being used to communicate over the network with the ET system. More...
 
int et_open_config_settcp (et_openconfig sconfig, int rBufSize, int sBufSize, int noDelay)
 This routine sets the parameters of any TCP connection to the ET system. More...
 
int et_open_config_gettcp (et_openconfig sconfig, int *rBufSize, int *sBufSize, int *noDelay)
 This routine gets the parameters of any TCP connection to the ET system. More...
 
int et_bridge_config_init (et_bridgeconfig *config)
 This routine initializes a configuration used to establish a bridge between 2 ET systems. More...
 
int et_bridge_config_destroy (et_bridgeconfig sconfig)
 This routine frees the memory allocated when a bridge configuration is initialized by et_bridge_config_init. More...
 
int et_bridge_config_setmodefrom (et_bridgeconfig config, int val)
 This routine sets the mode of getting events from the "from" ET system. More...
 
int et_bridge_config_getmodefrom (et_bridgeconfig config, int *val)
 This routine gets the mode of getting events from the "from" ET system. More...
 
int et_bridge_config_setmodeto (et_bridgeconfig config, int val)
 This routine sets the mode of getting new events from the "to" ET system. More...
 
int et_bridge_config_getmodeto (et_bridgeconfig config, int *val)
 This routine gets the mode of getting new events from the "to" ET system. More...
 
int et_bridge_config_setchunkfrom (et_bridgeconfig config, int val)
 This routine sets the maximum number of events to get from the "from" ET system in a single call to et_events_get - the number of events to get in one chunk. More...
 
int et_bridge_config_getchunkfrom (et_bridgeconfig config, int *val)
 This routine gets the maximum number of events to get from the "from" ET system in a single call to et_events_get - the number of events to get in one chunk. More...
 
int et_bridge_config_setchunkto (et_bridgeconfig config, int val)
 This routine sets the maximum number of new events to get from the "to" ET system in a single call to et_events_new - the number of events to get in one chunk. More...
 
int et_bridge_config_getchunkto (et_bridgeconfig config, int *val)
 This routine gets the maximum number of new events to get from the "to" ET system in a single call to et_events_new - the number of events to get in one chunk. More...
 
int et_bridge_config_settimeoutfrom (et_bridgeconfig config, struct timespec val)
 This routine sets the time to wait for the "from" ET system during all et_events_get calls when the mode is set to ET_TIMED. More...
 
int et_bridge_config_gettimeoutfrom (et_bridgeconfig config, struct timespec *val)
 This routine gets the time to wait for the "from" ET system during all et_events_get calls when the mode is set to ET_TIMED. More...
 
int et_bridge_config_settimeoutto (et_bridgeconfig config, struct timespec val)
 This routine sets the time to wait for the "to" ET system during all et_events_new calls when the mode is set to ET_TIMED. More...
 
int et_bridge_config_gettimeoutto (et_bridgeconfig config, struct timespec *val)
 This routine gets the time to wait for the "to" ET system during all et_events_new calls when the mode is set to ET_TIMED. More...
 
int et_bridge_config_setfunc (et_bridgeconfig config, ET_SWAP_FUNCPTR func)
 This routine sets the function used to automatically swap data from one endian to another when bridging events between two ET systems. More...
 
int et_events_bridge (et_sys_id id_from, et_sys_id id_to, et_att_id att_from, et_att_id att_to, et_bridgeconfig bconfig, int num, int *ntransferred)
 This routine transfers events between two ET systems in which events are copied from the "from" ET system and placed into the "to" ET system. More...
 

Macro Definition Documentation

#define err_abort (   code,
  text 
)
Value:
do { \
fprintf (stderr, "%s at \"%s\":%d: %s\n", \
text, __FILE__, __LINE__, strerror (code)); \
exit (-1); \
} while (0)

Macro to exit program with unrecoverable error (see "Programming with POSIX threads' by Butenhof).

Referenced by et_station_create_at(), et_station_remove(), et_system_start(), et_wakeup_all(), and et_wakeup_attachment().

#define ET_ASYNC   2

When getting events, return immediately if no event is available.

Referenced by et_bridge_config_setmodefrom(), et_bridge_config_setmodeto(), et_event_get(), et_event_new(), et_events_get(), et_events_new(), and et_events_new_group().

#define ET_BROADANDMULTICAST   3

Use broad and multicasting to find ET system.

Referenced by et_open_config_setcast().

#define ET_BROADCAST   1

Use broadcasting to find ET system.

Referenced by et_open_config_init(), and et_open_config_setcast().

#define ET_BROADCAST_PORT   11111
Deprecated:
Previous default ET system UDP broadcast port kept for backwards compatibility.
#define ET_DATA_CORRUPT   1

Event data is corrupt (currently not used).

Referenced by et_event_setdatastatus().

#define ET_DATA_MASK   0x30

Bit mask for network handling of data status.

Referenced by etr_event_get(), and etr_events_get().

#define ET_DATA_OK   0

Event data is OK.

Referenced by et_event_setdatastatus().

#define ET_DATA_POSSIBLY_CORRUPT   2

Event data is possibly corrupt as event was recovered from user crash.

Referenced by et_event_setdatastatus().

#define ET_DATA_SHIFT   4

Bit shift for network handling of data status.

Referenced by etr_event_get(), etr_event_put(), etr_events_get(), and etr_events_put().

#define ET_DEBUG_ERROR   2

Debug output for all errors.

Referenced by et_attach_geteventsdump(), et_attach_geteventsget(), et_attach_geteventsmake(), et_attach_geteventsput(), et_event_dump(), et_event_get(), et_event_new(), et_event_put(), et_event_setdatabuffer(), et_events_bridge(), et_events_dump(), et_events_get(), et_events_new(), et_events_new_group(), et_events_put(), et_open(), et_open_config_init(), et_open_config_setdebugdefault(), et_station_attach(), et_station_compare_parallel(), et_station_config_check(), et_station_create_at(), et_station_detach(), et_station_exists(), et_station_getattachments(), et_station_getblock(), et_station_getclass(), et_station_getcue(), et_station_getfunction(), et_station_getinputcount(), et_station_getlib(), et_station_getoutputcount(), et_station_getposition(), et_station_getprescale(), et_station_getrestore(), et_station_getselect(), et_station_getselectwords(), et_station_getstatus(), et_station_getuser(), et_station_isattached(), et_station_remove(), et_station_setblock(), et_station_setcue(), et_station_setposition(), et_station_setprescale(), et_station_setrestore(), et_station_setselectwords(), et_station_setuser(), et_system_close(), et_system_setdebug(), et_system_start(), et_wakeup_all(), et_wakeup_attachment(), etr_alive(), etr_close(), etr_event_dump(), etr_event_get(), etr_event_new(), etr_event_put(), etr_events_dump(), etr_events_get(), etr_events_new(), etr_events_new_group(), etr_events_put(), etr_forcedclose(), etr_kill(), etr_open(), etr_station_attach(), etr_station_create_at(), etr_station_detach(), etr_station_exists(), etr_station_getclass(), etr_station_getfunction(), etr_station_getlib(), etr_station_getposition(), etr_station_getselectwords(), etr_station_isattached(), etr_station_remove(), etr_station_setposition(), etr_station_setselectwords(), etr_wait_for_alive(), etr_wakeup_all(), and etr_wakeup_attachment().

#define ET_DEBUG_NONE   0
#define ET_DEBUG_SEVERE   1

Debug output for severe errors only.

Referenced by et_open_config_setdebugdefault(), et_station_attach(), et_station_create_at(), and et_system_setdebug().

#define ET_DIRECT   2

Connect directly to ET system TCP server by specifying host & port explicitly.

Referenced by et_open_config_setcast(), and etr_open().

#define ET_DUMP   16

If remote get and not modifying event, server dumps (not puts) events automatically back into ET.

Referenced by etr_event_get(), and etr_events_get().

#define ET_END   -1

When creating a new station, put at end of a linked list.

Referenced by et_station_create(), et_station_create_at(), et_station_setposition(), and etr_station_create().

#define ET_ENDIAN_BIG   0

Big endian.

Referenced by et_event_getendian(), and et_event_setendian().

#define ET_ENDIAN_LITTLE   1

Little endian.

Referenced by et_event_getendian(), and et_event_setendian().

#define ET_ENDIAN_LOCAL   2

Same endian as local host.

Referenced by et_event_setendian().

#define ET_ENDIAN_NOTLOCAL   3

Opposite endian as local host.

Referenced by et_event_setendian().

#define ET_ENDIAN_SWITCH   4

Switch recorded value of data's endian.

Referenced by et_event_setendian().

#define ET_EVENT_GROUPS_MAX   200

Default max number of groups events are divided into.

Referenced by et_system_config_init(), and et_system_config_setgroups().

#define ET_EVENT_NEW   1

Event obtained through calling et_event_new, et_events_new, et_event_new_group, or et_events_new_group.

#define ET_EVENT_NORMAL   0

Normal ET system event existing in main shared memory.

Referenced by etr_events_new(), and etr_events_new_group().

#define ET_EVENT_TEMP   1

Event is temporary (bigger than normal events with shared memory especially allocated for it alone).

Referenced by et_event_dump(), et_event_get(), et_event_put(), et_events_dump(), et_events_get(), et_events_put(), etr_event_new(), etr_events_new(), and etr_events_new_group().

#define ET_EVENT_USED   0

Event obtained through calling et_event_get or et_events_get.

Referenced by et_event_put(), and et_events_put().

#define ET_FILENAME_LENGTH   100
#define ET_FUNCNAME_LENGTH   48

Max length of user's event selection func name + 1.

Referenced by et_open_config_sethost(), et_station_config_setfunction(), and etr_station_getfunction().

#define ET_HIGH   1

Event is of high priority which means it get placed at the top of each station in/output list (but below other high priority events).

Referenced by et_event_setpriority().

#define ET_HOST_ANYWHERE   ".anywhere"

ET host is either local or remote.

Referenced by et_findlocality().

#define ET_HOST_AS_LOCAL   1

For communication with local ET system, use shared memory.

Referenced by et_open_config_init(), and et_open_config_setmode().

#define ET_HOST_AS_REMOTE   0

For communication with local ET system, use sockets.

Referenced by et_findlocality(), and et_open_config_setmode().

#define ET_HOST_LOCAL   ".local"

ET host is local.

Referenced by et_findlocality(), et_open_config_init(), and etr_open().

#define ET_HOST_REMOTE   ".remote"

ET host is remote.

Referenced by et_findlocality().

#define ET_LOCAL_NOSHARE   2
#define ET_LOW   0

Event is of normal priority.

Referenced by et_event_setpriority().

#define ET_MODIFY   4
#define ET_MODIFY_HEADER   8

Remote user will modify only event header (metadata).

Referenced by etr_event_get(), and etr_events_get().

#define ET_MULTICAST   0

Use multicasting to find ET system.

Referenced by et_open_config_setcast().

#define ET_MULTICAST_ADDR   "239.200.0.0"

Default multicast address to use in finding ET system.

#define ET_MULTICAST_PORT   11111
Deprecated:
Previous default ET system UDP multicast port kept for backwards compatibility.
#define ET_MULTICAST_TTL   32

Default multicast time-to-live value (# of router hops permitted).

Referenced by et_open_config_init().

#define ET_NEWHEAD   -2

When creating a new parallel station, put at head of a new group of parallel stations and in the main linked list of stations.

Referenced by et_station_create_at(), and et_station_setposition().

#define ET_NOALLOC   32

Remote user will not allocate memory but use existing buffer.

Referenced by etr_event_new(), etr_event_put(), etr_events_new(), etr_events_new_group(), and etr_events_put().

#define ET_NOSWAP   0

Event data endian is same as local host.

Referenced by et_event_needtoswap().

#define ET_OPEN_NOWAIT   0

Do not wait for the ET system to appear when trying to open it.

Referenced by et_open_config_init(), et_open_config_setwait(), and etr_open().

#define ET_OPEN_WAIT   1

Wait for the ET system to appear when trying to open it.

Referenced by et_open_config_setwait().

#define ET_POLICY_ERROR   2

Return an error if more than one responder when broad/multicasting to find ET system.

Referenced by et_open(), and et_open_config_setpolicy().

#define ET_POLICY_FIRST   0

Pick first responder when broad/multicasting to find ET system.

Referenced by et_open_config_init(), and et_open_config_setpolicy().

#define ET_POLICY_LOCAL   1

Pick local responder, else the first when broad/multicasting to find ET system.

Referenced by et_open_config_setpolicy().

#define ET_PRIORITY_MASK   1

Bit mask used to send priority bits over network.

Referenced by etr_event_get(), and etr_events_get().

#define ET_SERVER_PORT   11111

Default ET system TCP server port.

Referenced by et_open_config_init(), and et_system_config_init().

#define ET_STATION_ACTIVE   3

Station exists and has at least one attachment.

Referenced by et_station_attach(), et_station_getposition(), and et_station_setposition().

#define ET_STATION_BLOCKING   1

Station accepts all events (except if prescaling > 1 or if selection rule rejects them).

Referenced by et_station_config_check(), et_station_config_init(), et_station_config_setblock(), and et_station_setblock().

#define ET_STATION_CREATING   1

Station is in the middle of being created.

Referenced by et_station_create_at().

#define ET_STATION_CUE   10

Max number of events queued in nonblocking station.

Referenced by et_station_config_init().

#define ET_STATION_IDLE   2
#define ET_STATION_NONBLOCKING   0

Events bypass station when input queue is full.

Referenced by et_station_config_check(), et_station_config_setblock(), and et_station_setblock().

#define ET_STATION_PARALLEL   1

station is part of a group of stations in which events are flowing in parallel.

Referenced by et_station_attach(), et_station_config_check(), and et_station_config_setflow().

#define ET_STATION_PARALLEL_HEAD   2

station is head of a group of stations in which events are flowing in parallel.

Only used when gathering monitoring data of stations (not for config).

#define ET_STATION_PRESCALE   1

Default prescale of blocking stations.

Referenced by et_station_config_init().

#define ET_STATION_RESTORE_GC   2

Restore recovered events to GrandCentral input list.

Referenced by et_station_config_check(), et_station_config_setrestore(), and et_station_setrestore().

#define ET_STATION_RESTORE_IN   1

Restore recovered events to input list.

Referenced by et_station_config_check(), et_station_config_setrestore(), and et_station_setrestore().

#define ET_STATION_RESTORE_OUT   0

Restore recovered events to output list.

Referenced by et_station_config_check(), et_station_config_init(), et_station_config_setrestore(), and et_station_setrestore().

#define ET_STATION_RESTORE_REDIST   3

Redistribute recovered events to input of all parallel stations, along with all events left in station's input list.

Referenced by et_station_config_check(), and et_station_config_setrestore().

#define ET_STATION_SELECT_ALL   1

Select all events into station.

Referenced by et_station_config_check(), et_station_config_init(), and et_station_config_setselect().

#define ET_STATION_SELECT_EQUALCUE   5

For parallel stations, select events such that all input queues have the same number of events.

Referenced by et_station_compare_parallel(), et_station_config_check(), et_station_config_setselect(), et_station_setblock(), et_station_setprescale(), and et_station_setrestore().

#define ET_STATION_SELECT_MATCH   2

Select events using predefined selection rule.

Referenced by et_station_config_check(), and et_station_config_setselect().

#define ET_STATION_SELECT_RROBIN   4
#define ET_STATION_SELECT_USER   3
#define ET_STATION_SERIAL   0

normal flow of all events through all stations.

Referenced by et_station_config_check(), et_station_config_init(), and et_station_config_setflow().

#define ET_STATION_USER_MULTI   0

Multiple attachments are allowed on a single station.

Referenced by et_station_config_init().

#define ET_STATION_USER_SINGLE   1

Only one attachment is allowed on a single station.

#define ET_STATNAME_LENGTH   48

Max length of station name + 1.

Referenced by et_station_create_at().

#define ET_SUBNET_ALL   ".subnetsAll"

Use all local subnets.

Referenced by et_open_config_addbroadcast(), and et_open_config_removebroadcast().

#define ET_SWAP   1

Event data must be swapped to be consistent with local host endian.

Referenced by et_event_needtoswap().

#define ET_SWAP16 (   x)
Value:
((uint16_t)((((uint16_t)(x)) >> 8) | \
(((uint16_t)(x)) << 8)))

Macro to swap endian of 64 bit arg.

#define ET_SWAP32 (   x)
Value:
((uint32_t)((((uint32_t)(x)) >> 24) | \
(((uint32_t)(x) & 0x00ff0000) >> 8) | \
(((uint32_t)(x) & 0x0000ff00) << 8) | \
(((uint32_t)(x)) << 24)))

Macro for swapping 32 bit types.

Referenced by et_event_setendian().

#define ET_SWAP64 (   x)
Value:
((uint64_t)((((uint64_t)(x)) >> 56) | \
(((uint64_t)(x) & 0x00ff000000000000ULL) >> 40) | \
(((uint64_t)(x) & 0x0000ff0000000000ULL) >> 24) | \
(((uint64_t)(x) & 0x000000ff00000000ULL) >> 8) | \
(((uint64_t)(x) & 0x00000000ff000000ULL) << 8) | \
(((uint64_t)(x) & 0x0000000000ff0000ULL) << 24) | \
(((uint64_t)(x) & 0x000000000000ff00ULL) << 40) | \
(((uint64_t)(x)) << 56)))

Macro for swapping 64 bit types.

#define ET_SYS   -1

Event owner is the ET system (not an attachment or user-process).

Referenced by et_station_attach(), et_station_detach(), and et_system_close().

#define ET_SYSTEM_ESIZE   1000

Default size of normal events in bytes.

Referenced by et_system_config_init().

#define ET_SYSTEM_EVENTS   300

Default total number of events in ET system.

Referenced by et_system_config_init().

#define ET_SYSTEM_NSTATS   200

Default max number of stations.

Referenced by et_system_config_init().

#define ET_SYSTEM_NTEMPS   300

Default max number of temp events in ET system.

Referenced by et_system_config_init().

#define ET_TEMPNAME_LENGTH   (ET_FILENAME_LENGTH+12)

Max length of temp event file name + 1, leaves room for _temp<#######>.

#define ET_TIMED   1

When getting events, wait until either an event is available or the given time has expired before returning.

Referenced by et_bridge_config_setmodefrom(), et_bridge_config_setmodeto(), et_event_get(), et_event_new(), et_events_get(), et_events_new(), et_events_new_group(), etr_event_get(), etr_event_new(), etr_events_get(), etr_events_new(), and etr_events_new_group().

#define ET_UDP_PORT   11111

Default ET system UDP broad/multicast/directed-udp port.

Referenced by et_open_config_init(), and et_system_config_init().

#define INET_ATON_ERR   0

Typedef Documentation

typedef int et_att_id

ET attachment id.

typedef void* et_bridgeconfig

ET bridge id.

typedef struct et_event_t et_event

This structure defines an Event which exists in shared memory, holds data, and gets passed from station to station.

typedef void* et_openconfig

ET open configuration.

typedef int et_proc_id

ET process id.

typedef int et_stat_id

ET station id.

typedef void* et_statconfig

ET station configuration.

typedef int(* ET_SWAP_FUNCPTR)(et_event *, et_event *, int, int)

Used to define a data-swapping function.

typedef void* et_sys_id

ET system id.

typedef void* et_sysconfig

ET system configuration.

Function Documentation

int et_open_config_getaddress ( et_openconfig  sconfig,
char *  val 
)
int et_open_config_setaddress ( et_openconfig  sconfig,
const char *  val 
)