30 #define INET_ATON_ERR 0
43 #define ET_STATION_CUE 10
44 #define ET_STATION_PRESCALE 1
47 #define ET_SYSTEM_EVENTS 300
48 #define ET_SYSTEM_NTEMPS 300
49 #define ET_SYSTEM_ESIZE 1000
50 #define ET_SYSTEM_NSTATS 200
53 #define ET_UDP_PORT 11111
54 #define ET_SERVER_PORT 11111
55 #define ET_MULTICAST_PORT 11111
56 #define ET_BROADCAST_PORT 11111
58 #define ET_MULTICAST_ADDR "239.200.0.0"
60 #define ET_EVENT_GROUPS_MAX 200
69 #define ET_STATION_SELECT_INTS 6
76 #define ET_MULTICAST_TTL 32
79 #define ET_HOST_LOCAL ".local"
80 #define ET_HOST_REMOTE ".remote"
81 #define ET_HOST_ANYWHERE ".anywhere"
84 #define ET_HOST_AS_LOCAL 1
85 #define ET_HOST_AS_REMOTE 0
88 #define ET_POLICY_FIRST 0
89 #define ET_POLICY_LOCAL 1
90 #define ET_POLICY_ERROR 2
93 #define ET_FILENAME_LENGTH 100
94 #define ET_FUNCNAME_LENGTH 48
95 #define ET_STATNAME_LENGTH 48
97 #define ET_TEMPNAME_LENGTH (ET_FILENAME_LENGTH+12)
103 #define ET_GRANDCENTRAL 0
106 #define ET_STATION_UNUSED 0
107 #define ET_STATION_CREATING 1
108 #define ET_STATION_IDLE 2
109 #define ET_STATION_ACTIVE 3
112 #define ET_STATION_USER_MULTI 0
113 #define ET_STATION_USER_SINGLE 1
116 #define ET_STATION_NONBLOCKING 0
117 #define ET_STATION_BLOCKING 1
121 #define ET_STATION_SELECT_ALL 1
122 #define ET_STATION_SELECT_MATCH 2
123 #define ET_STATION_SELECT_USER 3
124 #define ET_STATION_SELECT_RROBIN 4
125 #define ET_STATION_SELECT_EQUALCUE 5
129 #define ET_STATION_RESTORE_OUT 0
130 #define ET_STATION_RESTORE_IN 1
131 #define ET_STATION_RESTORE_GC 2
132 #define ET_STATION_RESTORE_REDIST 3
136 #define ET_STATION_SERIAL 0
137 #define ET_STATION_PARALLEL 1
139 #define ET_STATION_PARALLEL_HEAD 2
153 #define ET_ERROR_TOOMANY -2
154 #define ET_ERROR_EXISTS -3
155 #define ET_ERROR_WAKEUP -4
156 #define ET_ERROR_TIMEOUT -5
157 #define ET_ERROR_EMPTY -6
158 #define ET_ERROR_BUSY -7
159 #define ET_ERROR_DEAD -8
160 #define ET_ERROR_READ -9
161 #define ET_ERROR_WRITE -10
162 #define ET_ERROR_REMOTE -11
163 #define ET_ERROR_NOREMOTE -12
164 #define ET_ERROR_TOOBIG -13
165 #define ET_ERROR_NOMEM -14
166 #define ET_ERROR_BADARG -15
167 #define ET_ERROR_SOCKET -16
168 #define ET_ERROR_NETWORK -17
169 #define ET_ERROR_CLOSED -18
170 #define ET_ERROR_JAVASYS -19
174 #define ET_DEBUG_NONE 0
175 #define ET_DEBUG_SEVERE 1
176 #define ET_DEBUG_ERROR 2
177 #define ET_DEBUG_WARN 3
178 #define ET_DEBUG_INFO 4
184 #define ET_PRIORITY_MASK 1
192 #define ET_NEWHEAD -2
195 #define ET_EVENT_TEMP 1
197 #define ET_EVENT_NORMAL 0
200 #define ET_EVENT_NEW 1
202 #define ET_EVENT_USED 0
209 #define ET_WAIT_MASK 3
212 #define ET_MODIFY_HEADER 8
215 #define ET_NOALLOC 32
218 #define ET_OPEN_NOWAIT 0
219 #define ET_OPEN_WAIT 1
224 #define ET_LOCAL_NOSHARE 2
227 #define ET_MULTICAST 0
228 #define ET_BROADCAST 1
230 #define ET_BROADANDMULTICAST 3
233 #define ET_SUBNET_ALL ".subnetsAll"
237 #define ET_DATA_CORRUPT 1
238 #define ET_DATA_POSSIBLY_CORRUPT 2
239 #define ET_DATA_MASK 0x30
240 #define ET_DATA_SHIFT 4
243 #define ET_ENDIAN_BIG 0
244 #define ET_ENDIAN_LITTLE 1
245 #define ET_ENDIAN_LOCAL 2
246 #define ET_ENDIAN_NOTLOCAL 3
247 #define ET_ENDIAN_SWITCH 4
256 #define ET_SWAP16(x) \
257 ((uint16_t)((((uint16_t)(x)) >> 8) | \
258 (((uint16_t)(x)) << 8)))
261 #define ET_SWAP32(x) \
262 ((uint32_t)((((uint32_t)(x)) >> 24) | \
263 (((uint32_t)(x) & 0x00ff0000) >> 8) | \
264 (((uint32_t)(x) & 0x0000ff00) << 8) | \
265 (((uint32_t)(x)) << 24)))
268 #define ET_SWAP64(x) \
269 ((uint64_t)((((uint64_t)(x)) >> 56) | \
270 (((uint64_t)(x) & 0x00ff000000000000ULL) >> 40) | \
271 (((uint64_t)(x) & 0x0000ff0000000000ULL) >> 24) | \
272 (((uint64_t)(x) & 0x000000ff00000000ULL) >> 8) | \
273 (((uint64_t)(x) & 0x00000000ff000000ULL) << 8) | \
274 (((uint64_t)(x) & 0x0000000000ff0000ULL) << 24) | \
275 (((uint64_t)(x) & 0x000000000000ff00ULL) << 40) | \
276 (((uint64_t)(x)) << 56)))
281 #define err_abort(code,text) do { \
282 fprintf (stderr, "%s at \"%s\":%d: %s\n", \
283 text, __FILE__, __LINE__, strerror (code)); \
354 int mode,
struct timespec *deltatime,
size_t size);
356 int mode,
struct timespec *deltatime,
size_t size,
357 int num,
int *nread);
359 int mode,
struct timespec *deltatime,
360 size_t size,
int group);
362 int mode,
struct timespec *deltatime,
363 size_t size,
int num,
int group,
int *nread);
365 extern int et_event_get(et_sys_id
id, et_att_id att, et_event **pe,
366 int mode,
struct timespec *deltatime);
367 extern int et_events_get(et_sys_id
id, et_att_id att, et_event *pe[],
368 int mode,
struct timespec *deltatime,
369 int num,
int *nread);
371 extern int et_event_put(et_sys_id
id, et_att_id att, et_event *pe);
372 extern int et_events_put(et_sys_id
id, et_att_id att, et_event *pe[],
375 extern int et_event_dump(et_sys_id
id, et_att_id att, et_event *pe);
376 extern int et_events_dump(et_sys_id
id, et_att_id att, et_event *pe[],
401 extern int et_open(et_sys_id*
id,
const char *
filename, et_openconfig openconfig);
404 extern int et_kill(et_sys_id
id);
425 const char *stat_name, et_statconfig sconfig,
426 int position,
int parallelposition);
428 const char *stat_name, et_statconfig sconfig);
434 int parallelposition);
436 int *parallelposition);
482 extern int et_station_exists(et_sys_id
id, et_stat_id *stat_id,
const char *stat_name);
672 et_att_id att_from, et_att_id att_to,
673 et_bridgeconfig bconfig,
674 int num,
int *ntransferred);
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.
Definition: et_event.c:1156
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 discover...
Definition: et_openconfig.c:575
struct et_event_t * next
Next event in linked list.
Definition: et.h:306
int group
Group number, events are divided into groups for limiting the number of events producers have access ...
Definition: et.h:338
char * et_perror(int error)
This routine returns a string describing the given error condition.
Definition: et_common.c:470
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...
Definition: et_statconfig.c:736
int(* ET_SWAP_FUNCPTR)(et_event *, et_event *, int, int)
Used to define a data-swapping function.
Definition: et.h:347
int et_system_config_setevents(et_sysconfig sconfig, int val)
This routine sets the configuration's total number of events.
Definition: et_sysconfig.c:139
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 us...
Definition: et_statconfig.c:675
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.
Definition: et_openconfig.c:522
int et_bridge_config_getmodeto(et_bridgeconfig config, int *val)
This routine gets the mode of getting new events from the "to" ET system.
Definition: et_bridge.c:206
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 allow...
Definition: et_station.c:2055
int et_open_config_getcast(et_openconfig sconfig, int *val)
This routine gets the method for a remote user to discover the ET system.
Definition: et_openconfig.c:229
int et_open_config_getTTL(et_openconfig sconfig, int *val)
This routine gets the "ttl" value for multicasting.
Definition: et_openconfig.c:279
int et_stat_id
ET station id.
Definition: et.h:355
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 ...
Definition: et_statconfig.c:616
int et_station_config_init(et_statconfig *sconfig)
This routine initializes a configuration used to create a station in the ET system.
Definition: et_statconfig.c:49
int et_system_getheartbeat(et_sys_id id, int *heartbeat)
This routine gets the current value of the heartbeat of the ET system.
Definition: et_sysconfig.c:1255
uint64_t length
Size of actual data in bytes.
Definition: et.h:316
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 at...
Definition: et_statconfig.c:392
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 ...
Definition: et_station.c:2745
int et_station_detach(et_sys_id id, et_att_id att)
This routine will detach the user from a station.
Definition: et_station.c:1044
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 ov...
Definition: et_sysconfig.c:691
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.
Definition: et_openconfig.c:1040
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 m...
Definition: et_bridge.c:323
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...
Definition: et_openconfig.c:438
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...
Definition: et_sysconfig.c:330
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 ov...
Definition: et_sysconfig.c:655
void * et_openconfig
ET open configuration.
Definition: et.h:353
void * et_statconfig
ET station configuration.
Definition: et.h:351
int et_system_config_init(et_sysconfig *sconfig)
This routine initializes a configuration used to define an ET system.
Definition: et_sysconfig.c:61
int et_open_config_sethost(et_openconfig sconfig, const char *val)
This routine sets host or computer on which the ET system is running.
Definition: et_openconfig.c:923
void * et_bridgeconfig
ET bridge id.
Definition: et.h:354
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...
Definition: et_sysconfig.c:1472
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...
Definition: et_openconfig.c:979
int et_event_getdatastatus(et_event *pe, int *datastatus)
This routine gets an event's data status.
Definition: et_event.c:2010
int et_station_config_setselectwords(et_statconfig sconfig, int val[])
This routine sets a station configuration's array of selection integers.
Definition: et_statconfig.c:525
struct et_event_t et_event
This structure defines an Event which exists in shared memory, holds data, and gets passed from stati...
int et_open_config_gethost(et_openconfig sconfig, char *val)
This routine gets the host or computer on which the ET system is running.
Definition: et_openconfig.c:950
int et_system_config_gettemps(et_sysconfig sconfig, int *val)
This routine gets the configuration's maximum number of temporary events.
Definition: et_sysconfig.c:279
int et_event_getdata(et_event *pe, void **data)
This routine gets the pointer to an event's data.
Definition: et_event.c:1900
int et_system_getpid(et_sys_id id, pid_t *pid)
This routine gets the unix process id of the ET system process.
Definition: et_sysconfig.c:1284
int et_system_setdebug(et_sys_id id, int debug)
This routine sets the level of debug output for the ET client.
Definition: et_sysconfig.c:1008
int et_bridge_config_init(et_bridgeconfig *config)
This routine initializes a configuration used to establish a bridge between 2 ET systems.
Definition: et_bridge.c:69
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 t...
Definition: et_statconfig.c:421
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.
Definition: et_station.c:1652
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 ...
Definition: et_sysconfig.c:735
int priority
Event priority, either ET_HIGH or ET_LOW.
Definition: et.h:330
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...
Definition: et_sysconfig.c:603
int et_station_config_getuser(et_statconfig sconfig, int *val)
This routine gets a station configuration's user mode.
Definition: et_statconfig.c:328
char filename[ET_TEMPNAME_LENGTH]
Filename of temp event.
Definition: et.h:343
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...
Definition: et_event.c:1833
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 allow...
Definition: et_station.c:1986
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...
Definition: et_sysconfig.c:538
int et_station_config_getflow(et_statconfig sconfig, int *val)
This routine gets a station configuration's flow mode.
Definition: et_statconfig.c:194
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 ca...
Definition: et_event.c:124
int et_system_gettempsmax(et_sys_id id, int *tempsmax)
This routine gets the maximum number of temporary events allowed in the ET system.
Definition: et_sysconfig.c:1136
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.
Definition: et_station.c:1710
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 t...
Definition: et_event.c:1690
int et_proc_id
ET process id.
Definition: et.h:356
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 e...
Definition: et_bridge.c:230
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...
Definition: et_station.c:2437
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 e...
Definition: et_bridge.c:253
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 ...
Definition: et_station.c:2128
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 bridgi...
Definition: et_bridge.c:427
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.
Definition: et_remote.c:1683
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 multi...
Definition: et_openconfig.c:491
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...
Definition: et_bridge.c:300
int et_event_getpriority(et_event *pe, int *pri)
This routine gets the priority of an event, either ET_LOW or ET_HIGH.
Definition: et_event.c:1852
int et_system_gettemps(et_sys_id id, int *temps)
This routine gets the number of temporary events currently in the ET system.
Definition: et_sysconfig.c:1400
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.
Definition: et_attachment.c:325
int et_system_config_settemps(et_sysconfig sconfig, int val)
This routine sets the configuration's maximum number of temporary events.
Definition: et_sysconfig.c:251
int age
ET_EVENT_NEW if it's a new event, else ET_EVENT_USED (new events always go to GrandCentral if user cr...
Definition: et.h:333
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 s...
Definition: et_sysconfig.c:481
int et_system_start(et_sys_id *id, et_sysconfig sconfig)
This routine creates an ET system.
Definition: et_system.c:90
int et_event_setdatastatus(et_event *pe, int datastatus)
This routine sets an event's data status.
Definition: et_event.c:1977
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 positio...
Definition: et_station.c:1192
int et_system_close(et_sys_id id)
This routine closes or shuts down an ET system.
Definition: et_system.c:461
int et_open_config_getaddress(et_openconfig sconfig, char *val)
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.
Definition: et_openconfig.c:1078
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 u...
Definition: et_statconfig.c:241
int et_system_config_getfile(et_sysconfig sconfig, char *val)
This routine gets the configuration's ET system file name.
Definition: et_sysconfig.c:880
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.
Definition: et_station.c:1582
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 pr...
Definition: et_station.c:726
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 th...
Definition: et_openconfig.c:728
int owner
Id of attachment that owns this event, else the system (-1).
Definition: et.h:331
uint64_t pointer
For remote events, pointer to this event in the server's space (used for writing of modified events)...
Definition: et.h:320
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.
Definition: et_openconfig.c:139
int et_alive(et_sys_id id)
This routine tells if an open ET system is alive (heartbeat is going).
Definition: et_common.c:415
int et_event_getendian(et_event *pe, int *endian)
This routine gets an event's data endian value.
Definition: et_event.c:2078
int et_event_setendian(et_event *pe, int endian)
This routine sets an event's data endian value.
Definition: et_event.c:2034
int et_station_config_setprescale(et_statconfig sconfig, int val)
This routine sets a station configuration's prescale value.
Definition: et_statconfig.c:472
int modify
When "getting" events from a remote client, this flag tells server whether this event will be modif...
Definition: et.h:322
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...
Definition: et_sysconfig.c:303
int et_station_config_setblock(et_statconfig sconfig, int val)
This routine sets a station configuration's block mode.
Definition: et_statconfig.c:109
int et_system_config_getevents(et_sysconfig sconfig, int *val)
This routine gets the configuration's total number of events.
Definition: et_sysconfig.c:173
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 whi...
Definition: et_event.c:668
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...
Definition: et_station.c:2504
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 t...
Definition: et_statconfig.c:449
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 us...
Definition: et_statconfig.c:642
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 mod...
Definition: et_bridge.c:369
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 positio...
Definition: et_station.c:1322
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...
Definition: et_openconfig.c:413
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...
Definition: et_sysconfig.c:1195
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.
Definition: et_station.c:1767
int et_station_config_destroy(et_statconfig sconfig)
This routine frees the memory allocated when a configuration is initialized by et_station_config_init...
Definition: et_statconfig.c:87
int et_station_getprescale(et_sys_id id, et_stat_id stat_id, int *prescale)
This routine gets a station's prescale value.
Definition: et_station.c:2285
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-bas...
Definition: et_station.c:2894
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...
Definition: et_bridge.c:277
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 ...
Definition: et_event.c:618
int et_system_config_getsize(et_sysconfig sconfig, size_t *val)
This routine gets the configuration's event size in bytes.
Definition: et_sysconfig.c:222
int et_wait_for_alive(et_sys_id id)
This routine waits until given ET system is alive.
Definition: et_common.c:440
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...
Definition: et_sysconfig.c:1225
int temp
ET_EVENT_TEMP if temporary event, else ET_EVENT_NORMAL.
Definition: et.h:332
int et_system_setgroup(et_sys_id id, int group)
This routine sets the default group number of the ET client.
Definition: et_sysconfig.c:929
int et_open_config_getpolicy(et_openconfig sconfig, int *val)
This routine gets the return policy from calls to et_open.
Definition: et_openconfig.c:891
int et_close(et_sys_id id)
This routine closes an open ET system.
Definition: et_common.c:316
int et_open_config_setaddress(et_openconfig sconfig, const char *val)
int et_event_getgroup(et_event *pe, int *grp)
This routine gets the group number that the event is associated with.
Definition: et_event.c:1816
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.
Definition: et_attachment.c:381
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 sy...
Definition: et_bridge.c:475
int et_open(et_sys_id *id, const char *filename, et_openconfig openconfig)
This routine opens an ET system for client use.
Definition: et_common.c:188
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 wh...
Definition: et_event.c:360
int et_system_config_setfile(et_sysconfig sconfig, const char *val)
This routine sets the configuration's ET system file name.
Definition: et_sysconfig.c:851
int et_bridge_config_getmodefrom(et_bridgeconfig config, int *val)
This routine gets the mode of getting events from the "from" ET system.
Definition: et_bridge.c:152
int et_open_config_setcast(et_openconfig sconfig, int val)
This routine sets the method for a remote user to discover the ET system.
Definition: et_openconfig.c:200
int et_bridge_config_setmodeto(et_bridgeconfig config, int val)
This routine sets the mode of getting new events from the "to" ET system.
Definition: et_bridge.c:177
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...
Definition: et_station.c:2976
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 a...
Definition: et_common.c:349
int et_open_config_setTTL(et_openconfig sconfig, int val)
This routine sets the "ttl" value for multicasting.
Definition: et_openconfig.c:254
int et_wakeup_all(et_sys_id id, et_stat_id stat_id)
This routine wakes up all attachments waiting to read events.
Definition: et_attachment.c:127
int et_open_config_init(et_openconfig *sconfig)
This routine initializes a configuration used to open an ET system.
Definition: et_openconfig.c:49
void * pdata
Set to either data field pointer (shared mem), or to temp event buffer.
Definition: et.h:313
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...
Definition: et_openconfig.c:334
int et_att_id
ET attachment id.
Definition: et.h:357
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 s...
Definition: et_sysconfig.c:510
uint64_t memsize
Total size of available data memory in bytes.
Definition: et.h:317
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 m...
Definition: et_bridge.c:346
int et_system_config_setattachments(et_sysconfig sconfig, int val)
This routine sets the configuration's maximum number of attachments that may be created.
Definition: et_sysconfig.c:424
int et_event_getlength(et_event *pe, size_t *len)
This routine gets the length of an event's data in bytes.
Definition: et_event.c:1884
int et_system_config_setprocs(et_sysconfig sconfig, int val)
This routine sets the configuration's maximum number of processes that may be created.
Definition: et_sysconfig.c:363
int et_station_config_getblock(et_statconfig sconfig, int *val)
This routine gets a station configuration's block mode.
Definition: et_statconfig.c:138
int et_open_config_destroy(et_openconfig sconfig)
This routine frees the memory allocated when an open configuration is initialized by et_open_config_i...
Definition: et_openconfig.c:100
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_NONBLOCK...
Definition: et_station.c:1830
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...
Definition: et_event.c:1587
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...
Definition: et_station.c:1488
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 ...
Definition: et_station.c:2200
int et_station_setprescale(et_sys_id id, et_stat_id stat_id, int prescale)
This routine sets a station's prescale value.
Definition: et_station.c:2350
int et_system_config_destroy(et_sysconfig sconfig)
This routine frees the memory allocated when a system configuration is initialized by et_system_confi...
Definition: et_sysconfig.c:118
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 f...
Definition: et_sysconfig.c:795
void * tempdata
For MacOS or non mutex-sharing systems, a temp event gotten by the server thread needs its data point...
Definition: et.h:307
int et_open_config_setdebugdefault(et_openconfig sconfig, int val)
This routine sets the default level of debug output.
Definition: et_openconfig.c:361
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.
Definition: et_attachment.c:269
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.
Definition: et_event.c:937
#define ET_STATION_SELECT_INTS
Number of control integers associated with each station.
Definition: et.h:69
int byteorder
Use to track the data's endianness (set to 0x04030201).
Definition: et.h:337
int et_system_getstationsmax(et_sys_id id, int *stationsmax)
This routine gets the maximum number of stations allowed in the ET system.
Definition: et_sysconfig.c:1164
int et_system_getstations(et_sys_id id, int *stations)
This routine gets the number of stations in the ET system.
Definition: et_sysconfig.c:1370
char * data
Pointer to shared memory data.
Definition: et.h:315
int datastatus
ET_DATA_OK normally, ET_DATA_CORRUPT if data corrupt, ET_DATA_POSSIBLY_CORRUPT if data questionable...
Definition: et.h:335
int et_system_getprocs(et_sys_id id, int *procs)
This routine gets the number of local processes that have opened the ET system.
Definition: et_sysconfig.c:1314
int et_station_config_getselect(et_statconfig sconfig, int *val)
This routine gets a station configuration's select mode.
Definition: et_statconfig.c:273
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.
Definition: et_station.c:2581
#define ET_TEMPNAME_LENGTH
Max length of temp event file name + 1, leaves room for _temp<#######>.
Definition: et.h:97
int et_open_config_setpolicy(et_openconfig sconfig, int val)
This routine sets the return policy from calls to et_open.
Definition: et_openconfig.c:862
int et_bridge_config_setmodefrom(et_bridgeconfig config, int val)
This routine sets the mode of getting events from the "from" ET system.
Definition: et_bridge.c:123
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.
Definition: et_openconfig.c:164
int et_station_config_setflow(et_statconfig sconfig, int val)
This routine sets a station configuration's flow mode.
Definition: et_statconfig.c:166
int et_system_config_setsize(et_sysconfig sconfig, size_t val)
This routine sets the configuration's event size in bytes.
Definition: et_sysconfig.c:196
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...
Definition: et_openconfig.c:1011
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 stat...
Definition: et_station.c:707
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 ...
Definition: et_statconfig.c:583
void * et_sysconfig
ET system configuration.
Definition: et.h:352
int et_station_config_getprescale(et_statconfig sconfig, int *val)
This routine gets a station configuration's prescale value.
Definition: et_statconfig.c:499
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?
Definition: et_station.c:1420
int et_event_setlength(et_event *pe, size_t len)
This routine sets the length of an event's data in bytes.
Definition: et_event.c:1868
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...
Definition: et_event.c:1357
int et_bridge_config_destroy(et_bridgeconfig sconfig)
This routine frees the memory allocated when a bridge configuration is initialized by et_bridge_confi...
Definition: et_bridge.c:103
int et_system_config_getprocs(et_sysconfig sconfig, int *val)
This routine gets the configuration's maximum number of processes that may be created.
Definition: et_sysconfig.c:394
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.
Definition: et_openconfig.c:543
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.
Definition: et_station.c:2651
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...
Definition: et_sysconfig.c:566
int et_event_needtoswap(et_event *pe, int *swap)
This routine indicates whether an event's data needs to be swapped or not.
Definition: et_event.c:2108
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 mod...
Definition: et_bridge.c:392
int et_system_getnumevents(et_sys_id id, int *numevents)
This routine gets the number of events in the ET system.
Definition: et_sysconfig.c:1087
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...
Definition: et_event.c:1465
This structure defines an Event which exists in shared memory, holds data, and gets passed from stati...
Definition: et.h:305
int et_open_config_getdebugdefault(et_openconfig sconfig, int *val)
This routine gets the default level of debug output.
Definition: et_openconfig.c:389
int et_event_setcontrol(et_event *pe, int con[], int num)
This routine sets the control array of an event.
Definition: et_event.c:1919
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 ...
Definition: et_statconfig.c:300
int control[ET_STATION_SELECT_INTS]
Array of ints to select on for entry into station.
Definition: et.h:342
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...
Definition: et_openconfig.c:307
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 t...
Definition: et_openconfig.c:791
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 stat...
Definition: et_station.c:365
int et_system_getgroup(et_sys_id id, int *group)
This routine gets the default group number of the ET client.
Definition: et_sysconfig.c:975
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 multi...
Definition: et_openconfig.c:466
int et_event_getcontrol(et_event *pe, int con[])
This routine gets the control array of an event.
Definition: et_event.c:1943
int et_system_gethost(et_sys_id id, char *host)
This routine gets the host of the ET system.
Definition: et_sysconfig.c:1449
int et_station_config_getselectwords(et_statconfig sconfig, int val[])
This routine gets a station configuration's array of selection integers.
Definition: et_statconfig.c:553
int place
Place number of event's relative position in shared mem starting with 0 (lowest memory position) and ...
Definition: et.h:340
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 t...
Definition: et_station.c:2812
int et_system_getserverport(et_sys_id id, int *port)
This routine gets the TCP listening port number of the ET system.
Definition: et_sysconfig.c:1426
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. ...
Definition: et_sysconfig.c:1342
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.
Definition: et_station.c:872
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 dis...
Definition: et_openconfig.c:655
int et_station_setblock(et_sys_id id, et_stat_id stat_id, int block)
This routine sets a station's block mode.
Definition: et_station.c:1899
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.
Definition: et_sysconfig.c:1109
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...
Definition: et_attachment.c:213
int et_kill(et_sys_id id)
This routine kills an open ET system.
Definition: et_common.c:381
int et_system_getdebug(et_sys_id id, int *debug)
This routine gets the level of debug output for the ET client.
Definition: et_sysconfig.c:1038
int et_system_getlocality(et_sys_id id, int *locality)
This routine gets the locality of the ET client.
Definition: et_sysconfig.c:1065
int et_system_config_getattachments(et_sysconfig sconfig, int *val)
This routine gets the configuration's maximum number of attachments that may be created.
Definition: et_sysconfig.c:455
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...
Definition: et_statconfig.c:702
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,.
Definition: et_station.c:1552
int et_wakeup_attachment(et_sys_id id, et_att_id att)
This routine wakes up a specific attachment waiting to read events.
Definition: et_attachment.c:41
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 at...
Definition: et_statconfig.c:360
void * et_sys_id
ET system id.
Definition: et.h:350