1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- #ifndef INTERFACE_ABSTRACTION_H_
- #define INTERFACE_ABSTRACTION_H_
- #include <stdio.h>
- #include <stdlib.h>
- #include <string>
- typedef unsigned char Byte;
- using namespace std;
- class InterfaceAbstraction
- {
- public:
- ~InterfaceAbstraction();
- bool Open(const char *toIPAPath, const char *fromIPAPath);
- void Close();
- long SendData(unsigned char *buffer, size_t size);
- int ReceiveData(unsigned char *buf, size_t size);
- int ReceiveSingleDataChunk(unsigned char *buf, size_t size);
- int setReadNoBlock();
- int clearReadNoBlock();
- string m_toChannelName;
- string m_fromChannelName;
- private:
- int m_toIPADescriptor;
- int m_fromIPADescriptor;
- };
- #endif
|