| 1 | /* | 
|---|
| 2 | * synergy -- mouse and keyboard sharing utility | 
|---|
| 3 | * Copyright (C) 2002 Chris Schoeneman | 
|---|
| 4 | * | 
|---|
| 5 | * This package is free software; you can redistribute it and/or | 
|---|
| 6 | * modify it under the terms of the GNU General Public License | 
|---|
| 7 | * found in the file COPYING that should have accompanied this file. | 
|---|
| 8 | * | 
|---|
| 9 | * This package is distributed in the hope that it will be useful, | 
|---|
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | 
|---|
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the | 
|---|
| 12 | * GNU General Public License for more details. | 
|---|
| 13 | */ | 
|---|
| 14 |  | 
|---|
| 15 | #ifndef XIO_H | 
|---|
| 16 | #define XIO_H | 
|---|
| 17 |  | 
|---|
| 18 | #include "XBase.h" | 
|---|
| 19 |  | 
|---|
| 20 | //! Generic I/O exception | 
|---|
| 21 | XBASE_SUBCLASS(XIO, XBase); | 
|---|
| 22 |  | 
|---|
| 23 | //! I/O closing exception | 
|---|
| 24 | /*! | 
|---|
| 25 | Thrown if a stream cannot be closed. | 
|---|
| 26 | */ | 
|---|
| 27 | XBASE_SUBCLASS(XIOClose, XIO); | 
|---|
| 28 |  | 
|---|
| 29 | //! I/O already closed exception | 
|---|
| 30 | /*! | 
|---|
| 31 | Thrown when attempting to close or perform I/O on an already closed. | 
|---|
| 32 | stream. | 
|---|
| 33 | */ | 
|---|
| 34 | XBASE_SUBCLASS_WHAT(XIOClosed, XIO); | 
|---|
| 35 |  | 
|---|
| 36 | //! I/O end of stream exception | 
|---|
| 37 | /*! | 
|---|
| 38 | Thrown when attempting to read beyond the end of a stream. | 
|---|
| 39 | */ | 
|---|
| 40 | XBASE_SUBCLASS_WHAT(XIOEndOfStream, XIO); | 
|---|
| 41 |  | 
|---|
| 42 | //! I/O would block exception | 
|---|
| 43 | /*! | 
|---|
| 44 | Thrown if an operation on a stream would block. | 
|---|
| 45 | */ | 
|---|
| 46 | XBASE_SUBCLASS_WHAT(XIOWouldBlock, XIO); | 
|---|
| 47 |  | 
|---|
| 48 | #endif | 
|---|