NetSim Source Code Help v14.4
All 13 Components
 
Loading...
Searching...
No Matches
NetSim_Plot.h
1/************************************************************************************
2 * Copyright (C) 2023 *
3 * TETCOS, Bangalore. India *
4 * *
5 * Tetcos owns the intellectual property rights in the Product and its content. *
6 * The copying, redistribution, reselling or publication of any or all of the *
7 * Product or its content without express prior written consent of Tetcos is *
8 * prohibited. Ownership and / or any other right relating to the software and all *
9 * intellectual property rights therein shall remain at all times with Tetcos. *
10 * *
11 * Author: Shashi Kant Suman *
12 * *
13 * ---------------------------------------------------------------------------------*/
14#ifndef _NETSIM_PLOT_H_
15#define _NETSIM_PLOT_H_
16#ifndef WIN32
17#include <stdio.h>
18#include "Linux.h"
19#endif
20
21typedef enum enum_plot_type
22{
23 Plot_Custom,
24 Plot_Throughput,
25 Plot_Buffer,
26}PLOT_TYPE;
27
28typedef struct stru_plot_data
29{
30 char* data;
31 struct stru_plot_data* next;
32}PLOT_DATA,*PPLOT_DATA;
33
34typedef struct stru_plotData
35{
36 PPLOT_DATA read;
37 PPLOT_DATA write;
38}PLOTDATA,*ptrPLOTDATA;
39
40
41typedef struct stru_NetSimPlot
42{
43 char* menuName;
44 char* heading;
45 char* xLabel;
46 char* yLabel;
47
48 UINT numY;
49 char** plotName;
50
51 PLOT_TYPE plotType;
52 char* txtFileName;
53 PLOTDATA plotData;
54 bool isOver;
55
56 HANDLE mutex;
57
58}NETSIMPLOT,*PNETSIMPLOT;
59
60/* Plot API */
61_declspec(dllexport) PNETSIMPLOT fn_NetSim_Install_Metrics_Plot(PLOT_TYPE plotType,
62 char* menuName,
63 char* heading,
64 ...);
65_declspec(dllexport) void add_plot_data_formatted(PNETSIMPLOT g, char* format, ...);
66#endif