/[H8]/trunk/test-server/TerminalSocket.h
ViewVC logotype

Contents of /trunk/test-server/TerminalSocket.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 110 - (show annotations) (download)
Mon May 28 14:41:33 2007 UTC (17 years ago) by torben
File MIME type: text/plain
File size: 754 byte(s)
Implement a test-server (maybe)
1 #pragma once
2 #include "afxsock.h"
3 #include "sigslot.h"
4 #include "SalesItem.h"
5
6 #include <vector>
7
8
9 class TerminalSocket :
10 public CSocket
11 {
12 unsigned char m_buffer[1024];
13 CString m_message;
14 int m_termid;
15 double m_total;
16
17 std::vector<SalesItemLine> m_items;
18
19 public:
20 TerminalSocket(void);
21 virtual ~TerminalSocket(void);
22 virtual void OnReceive(int nErrorCode);
23
24 sigslot::signal0<> dataRecieved;
25
26 CString GetMessage() { return m_message; }
27
28
29 void HelloPackage();//0
30 void SalesDescriptionPackage();//1
31 void RequestTotalPackage();//2
32 void RequestChangePackage();//3
33 void AbortLastPackage();//4
34 void AbortSessionPackage();//5
35 void GoodByePackage();//6
36
37 SalesItem FetchItemInfo(const CString& barcode);
38 };

  ViewVC Help
Powered by ViewVC 1.1.20