There was an error while loading. Please reload this page.
1 parent 6350d44 commit 200286dCopy full SHA for 200286d
Selective Repeat Protocol/Frame.h
@@ -0,0 +1,23 @@
1
+/**
2
+ * This code defines a header file. The Frame class has three member variables:
3
+ * seqNum of type int to store the sequence number, data of type std::string to store data,
4
+ * and ack of type bool to represent acknowledgment.
5
+ * The class also includes a constructor that initializes the seqNum and data member variables.
6
+ * The code is wrapped inside include guards to prevent multiple declarations when the header file is included in different source files.
7
+ **/
8
+
9
10
11
+#ifndef FRAME_H
12
+#define FRAME_H
13
+#include <string>
14
15
16
+class Frame {
17
+public:
18
+ int seqNum;
19
+ std::string data;
20
+ bool ack;
21
+};
22
23
+#endif
0 commit comments