root/src/dps8/uvutil.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 /*
   2  * vim: filetype=c:tabstop=4:ai:expandtab
   3  * SPDX-License-Identifier: ICU
   4  * scspell-id: 6ae968db-f630-11ec-991c-80ee73e9b8e7
   5  *
   6  * ---------------------------------------------------------------------------
   7  *
   8  * Copyright (c) 2007-2013 Michael Mondy
   9  * Copyright (c) 2012-2016 Harry Reed
  10  * Copyright (c) 2013-2018 Charles Anthony
  11  * Copyright (c) 2015 Eric Swenson
  12  * Copyright (c) 2021-2024 The DPS8M Development Team
  13  *
  14  * This software is made available under the terms of the ICU License.
  15  * See the LICENSE.md file at the top-level directory of this distribution.
  16  *
  17  * ---------------------------------------------------------------------------
  18  */
  19 
  20 #if !defined(UVUTIL_H)
  21 # define UVUTIL_H
  22 
  23 struct uv_access_s
  24   {
  25     uv_loop_t * loop;
  26     int port;
  27     char * address;
  28 # define PW_SIZE 128
  29     char pw[PW_SIZE + 1];
  30     char pwBuffer[PW_SIZE + 1];
  31     int pwPos;
  32 
  33     void (* connectPrompt) (uv_tcp_t * client);
  34     void (* connected) (uv_tcp_t * client);
  35     bool open;
  36     uv_tcp_t server;
  37     uv_tcp_t * client;
  38     bool useTelnet;
  39     void * telnetp;
  40     bool loggedOn;
  41     unsigned char * inBuffer;
  42     uint inSize;
  43     uint inUsed;
  44   };
  45 
  46 typedef struct uv_access_s uv_access;
  47 void accessStartWriteStr (uv_tcp_t * client, char * data);
  48 void uv_open_access (uv_access * access);
  49 # if !defined(QUIET_UNUSED)
  50 void accessPutStr (uv_access * access, char * str);
  51 void accessPutChar (uv_access * access,  char ch);
  52 # endif
  53 int accessGetChar (uv_access * access);
  54 void accessStartWrite (uv_tcp_t * client, char * data, ssize_t datalen);
  55 void accessCloseConnection (uv_stream_t* stream);
  56 #endif

/* [previous][next][first][last][top][bottom][index][help] */