1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 typedef void (* uv_read_cb_t) (uv_tcp_t * client, ssize_t nread, unsigned char * buf);
18 typedef void (* uv_write_cb_t) (uv_tcp_t * client, unsigned char * data, ssize_t datalen);
19 struct uvClientData_s
20 {
21 bool assoc;
22 uint fnpno;
23 uint lineno;
24 void * telnetp;
25 uv_read_cb_t read_cb;
26 uv_write_cb_t write_cb;
27 uv_write_cb_t write_actual_cb;
28
29 char buffer [1024];
30 size_t nPos;
31
32 char * ttype;
33 uint stationNo;
34 };
35
36 typedef struct uvClientData_s uvClientData;
37
38 int fnpuvInit (int telnet_port, char * telnet_address);
39 int fnpuv3270Init (int telnet3270_port);
40 void fnpuv3270Poll (bool start);
41 void fnpuvProcessEvent (void);
42 void fnpuv_start_write (uv_tcp_t * client, unsigned char * data, ssize_t len);
43 void fnpuv_start_writestr (uv_tcp_t * client, unsigned char * data);
44 void fnpuv_send_eor (uv_tcp_t * client);
45 void fnpuv_recv_eor (uv_tcp_t * client);
46 void fnpuv_start_write_actual (uv_tcp_t * client, unsigned char * data, ssize_t datalen);
47 void fnpuv_associated_brk (uv_tcp_t * client);
48 void fnpuv_unassociated_readcb (uv_tcp_t * client, ssize_t nread, unsigned char * buf);
49 void fnpuv_associated_readcb (uv_tcp_t * client, ssize_t nread, unsigned char * buf);
50 void fnpuv_read_start (uv_tcp_t * client);
51 void fnpuv_read_stop (uv_tcp_t * client);
52 void fnpuv_dial_out (uint fnpno, uint lineno, word36 d1, word36 d2, word36 d3);
53 void fnpuv_open_slave (uint fnpno, uint lineno);
54 void close_connection (uv_stream_t* stream);
55 #if defined(TUN)
56 void fnpTUNProcessEvent (void);
57 #endif
58 void fnpuv_3270_readcb (uv_tcp_t * client,
59 ssize_t nread,
60 unsigned char * buf);
61 void fnpuv_start_3270_write (uv_tcp_t * client, unsigned char * data, ssize_t datalen);
62 void reset_line (struct t_line * linep);