Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

vmdsock.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *cr
00003  *cr            (C) Copyright 1995-2019 The Board of Trustees of the
00004  *cr                        University of Illinois
00005  *cr                         All Rights Reserved
00006  *cr
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  * RCS INFORMATION:
00011  *
00012  *      $RCSfile: vmdsock.h,v $
00013  *      $Author: johns $        $Locker:  $             $State: Exp $
00014  *      $Revision: 1.17 $      $Date: 2019/01/17 21:21:03 $
00015  *
00016  ***************************************************************************
00017  * DESCRIPTION:
00018  *   socket interface layer, abstracts platform-dependent routines/APIs
00019  *
00020  * LICENSE:
00021  *   UIUC Open Source License
00022  *   http://www.ks.uiuc.edu/Research/vmd/plugins/pluginlicense.html
00023  *
00024  ***************************************************************************/
00025 
00026 #if defined(VMDSOCKINTERNAL)
00027 
00028 #if !defined(_MSC_VER)
00029 #include <unistd.h>
00030 #include <sys/types.h>
00031 #include <sys/socket.h>
00032 #include <sys/time.h>
00033 #include <netinet/in.h>
00034 #include <sys/file.h>
00035 #endif
00036 
00037 typedef struct {
00038   struct sockaddr_in addr; /* address of socket provided by bind() */
00039   int addrlen;             /* size of the addr struct */
00040   int sd;                  /* socket file descriptor */
00041 } vmdsocket;
00042 
00043 #endif /* VMDSOCKINTERNAL */
00044 
00045 #ifdef __cplusplus
00046 extern "C" {
00047 #endif
00048 
00049 int   vmdsock_init(void);
00050 void *vmdsock_create(void);
00051 int   vmdsock_bind(void *, int);
00052 int   vmdsock_listen(void *);
00053 void *vmdsock_accept(void *);  /* return new socket */
00054 int   vmdsock_connect(void *, const char *, int);
00055 int   vmdsock_write(void *, const void *, int);
00056 int   vmdsock_read(void *, void *, int);
00057 int   vmdsock_selread(void *, int);
00058 int   vmdsock_selwrite(void *, int);
00059 void  vmdsock_shutdown(void *);
00060 void  vmdsock_destroy(void *);
00061 
00062 #ifdef __cplusplus
00063 }
00064 #endif
00065 

Generated on Thu Apr 18 02:45:48 2024 for VMD (current) by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002