(file) Return to daVarRpc.x CVS log (file) (dir) Up to [HallC] / Analyzer / CTP

  1 saw   1.1 /*-----------------------------------------------------------------------------
  2            * Copyright (c) 1993 Southeastern Universities Research Association,
  3            *                    Continuous Electron Beam Accelerator Facility
  4            *
  5            * This software was developed under a United States Government license
  6            * described in the NOTICE file included as part of this distribution.
  7            *
  8            * Stephen A. Wood, 12000 Jefferson Ave., Newport News, VA 23606
  9            * Email: saw@cebaf.gov  Tel: (804) 249-7367  Fax: (804) 249-5800
 10            *-----------------------------------------------------------------------------
 11            * 
 12            * Description:
 13            *  daVar RPCGEN input file
 14            *	
 15            * Author:  Stephen Wood, CEBAF Hall C
 16            *
 17            * Revision History:
 18            *   $Log: daVarRpc.x,v $
 19            *   Revision 1.3  1994/11/07  14:33:12  saw
 20            *   Add testnamelist structure and readmultiple_test and family rpc's
 21            *
 22 saw   1.1  *   Revision 1.2  1993/11/24  22:01:35  saw
 23            *   Add double variable type
 24            *
 25            *   Revision 1.1  1993/05/10  21:10:37  saw
 26            *   Initial revision
 27            *
 28            */
 29           
 30           %#include <time.h>
 31           
 32           #if defined(RPC_HDR) || defined(RPC_XDR) || defined(RPC_SVC) || \
 33             defined(RPC_CLNT) || defined(RPC_TBL)
 34           #define RPCGEN
 35           #else
 36           #undef RPCGEN
 37           #endif
 38           
 39           #include "daVar.h"
 40           const DAVARINT_RPC = DAVARINT;
 41           const DAVARFLOAT_RPC = DAVARFLOAT;
 42           const DAVARDOUBLE_RPC = DAVARDOUBLE;
 43 saw   1.1 const DAVARSTRING_RPC = DAVARSTRING;
 44           const DAVARERROR_RPC = 999;
 45           
 46           typedef string PNAME<>;
 47           typedef PNAME NAMELIST<>;
 48           
 49           union any switch (int valtype) {
 50            case DAVARINT_RPC:
 51             int i<>;
 52            case DAVARFLOAT_RPC:
 53             float r<>;
 54            case DAVARDOUBLE_RPC:
 55             double d<>;
 56            case DAVARSTRING_RPC:
 57             string s<>;
 58            case DAVARERROR_RPC:
 59             int error;
 60            default:
 61             void;
 62           };
 63           
 64 saw   1.1 struct wany {
 65             PNAME name;
 66             any *val;
 67           };
 68           
 69           typedef any RVALLIST<>;
 70           
 71           typedef wany WVALLIST<>;
 72           
 73           typedef int ERRLIST<>;
 74           
 75           struct TESTNAMELIST {
 76               /* Can we have a more generic structure fore this? */
 77             string test_condition<>;
 78             int max_time_wait;            /* Seconds before failing */
 79             int max_event_wait;           /* # of events before failing */
 80             int prog;
 81             int vers;
 82             NAMELIST *NAMELISTP;
 83           };
 84           
 85 saw   1.1 program DAVARSVR {
 86             version DAVARVERS {
 87               int DAVAR_ACKMESSAGE(string) = 101;
 88               NAMELIST DAVAR_GETLIST(string) = 102;
 89               RVALLIST DAVAR_READMULTIPLE(NAMELIST) = 103;
 90               ERRLIST DAVAR_WRITEMULTIPLE(WVALLIST) = 104;
 91               int DAVAR_READMULTIPLE_TEST(TESTNAMELIST) = 105;
 92           #if defined(RPC_HDR) || defined(RPC_XDR) || defined(RPC_SVC)
 93               int DAVAR_READMULTIPLE_TEST_CB(RVALLIST) = 106; /* Call Back */
 94           #endif
 95           /*    double HACK(int) = 201;*/
 96             } = 1;
 97           } = 0x2c0daFF8;
 98           
 99           /*
100           Local Variables:
101           mode: c
102           End:
103           */

Analyzer/Replay: Mark Jones, Documents: Stephen Wood
Powered by
ViewCVS 0.9.2-cvsgraph-1.4.0