home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2001 Mobile
/
Chip_Mobile_2001.iso
/
palm
/
business
/
printcar
/
printcar.exe
/
src
/
IrDA
/
IrPort.h
< prev
Wrap
C/C++ Source or Header
|
2000-06-06
|
1KB
|
60 lines
//
// $Id: IrPort.h,v 1.3 2000/06/06 09:30:57 sergey Exp $
//
#ifndef _IrPort_h_
#define _IrPort_h_
namespace IrDA
{
class Connection;
class Callback;
class Port
{
public:
Port();
~Port();
// can't be copied
private:
Port(const Port&);
Port& operator =(const Port&);
// operations
public:
bool open(Callback* callback);
void close();
bool connect();
void disconnect();
bool sendData(const Byte* data, int size);
// Blocks until the channel not ready to accept this portion of data.
bool blockingSendData(const Byte* data, int size);
// attributes
bool isOpened() const { return _opened; }
bool isConnected() const;
bool dataSendReady() const;
int getMaxTxSize() const;
// implementation
private:
bool initIrLib();
// data members
private:
bool _opened;
Word _refNum;
Connection* _connection;
};
}
// namespace IrDA
#endif // _IrPort_h_