source: tmcsimulator/branches/ATMSCommunicator/FEPClient.h @ 75

Revision 75, 1.2 KB checked in by jtorres, 9 years ago (diff)

Renamed fep_client_cpp to ATMSCommunicator, and upgraded it to cpp from straight c. Converted/Renamed? fep_client_java to ATMSDriver NetBeans? project, and checked in initial code for ATMSDriver. It contains the skeleton network model and a NetworkReader? which loads static network data from network lookup files.

Line 
1// Include guard
2#ifndef __FEPCLIENT_H_INCLUDED__
3#define __FEPCLIENT_H_INCLUDED__
4
5// Forward declared dependencies
6class NetworkReader;
7
8// Included dependencies
9#include "fep.h"
10#include <iostream>
11#include <stdlib.h>
12#include "time.h"
13#include "NetworkReader.h"
14
15/* The FEPClient is an RPC Client which transfers network data to the
16 * ATMS Server.
17 *
18 * An FEPClient is created every 30 seconds, and an fep_reply structure
19 * for every FEP_LINE_LDS is transferred to the ATMS through an RPC Call.
20 * After the FEPClient has transferred all fep_replys, it is destroyed.
21 *
22 * To construct an FEPClient, an input file (containing network data) and
23 * a host server_ip (for the ATMS) need to be specified.
24 *
25 * Author: John A. Torres
26 * Version: 9/8/2017
27 */
28class FEPClient
29{
30        public:
31        /* members */
32                CLIENT *clnt; // RPC Client
33
34        /* methods */
35                FEPClient(char * host, char * networkFile); // Constructor
36                ~FEPClient(); // Destructor
37
38        private:
39        /* members */
40        NetworkReader *networkReader;
41
42        /* methods */
43                void handleCallResponse(void *response); //
44                void createClient(char *host);
45        void updateATMS(); // updates ATMS
46
47};
48
49#endif // __FEPCLIENT_H_INCLUDED__
Note: See TracBrowser for help on using the repository browser.