![]() |
The Simons
|
00001 00002 // 00003 // SCL : Simons Component Library 00004 // 00006 // 00007 // Filename: ReadFailure.h 00008 // Contents: ReadFailure class, signalling a failed read 00009 // Author: Anthony J H Simons 00010 // Revised: 30 November 2005 00011 00012 // This software is distributed free in the hope that others will 00013 // find it useful. However, it comes WITHOUT ANY WARRANTY. No 00014 // liability can be accepted for software failure, merchantability 00015 // or fitness for a particular purpose. You can redistribute this 00016 // software in its original form, or in a modified form, provided 00017 // that this disclaimer is retained in the file banner. 00018 00019 #ifndef SCL_READ_FAILURE 00020 #define SCL_READ_FAILURE 00021 00022 #include "DataError.h" // Include my superclass type 00023 #include "ReadFailureID.h" // Include my pointer type 00024 00025 #include "StringID.h" // Depend on the pointer type 00026 00028 00029 class ReadFailure : public DataError { 00030 protected: 00031 ReadFailure(const ReadFailure&); 00032 public: 00033 ReadFailure(); 00034 virtual ~ReadFailure(); 00035 ReadFailure(StreamID, StringID, ObjectID); 00036 virtual ObjectID clone() const; 00037 }; 00038 00040 00041 00043 00046 inline ReadFailureID::ReadFailureID() {} 00047 00049 inline ReadFailureID::~ReadFailureID() {} 00050 00054 inline ReadFailureID::ReadFailureID(const Null* null) : 00055 DataErrorID(null) {} 00056 00060 inline ReadFailureID::ReadFailureID(const ReadFailure* exception) : 00061 DataErrorID(exception) {} 00062 00066 inline ReadFailureID::ReadFailureID(const ReadFailureID& pointer) : 00067 DataErrorID(pointer) {} 00068 00072 inline ReadFailureID& ReadFailureID::operator=(const ReadFailure* exception) { 00073 assign(exception); 00074 return *this; 00075 } 00076 00081 inline ReadFailureID& ReadFailureID::operator=(const ReadFailureID& pointer) { 00082 assign(pointer); 00083 return *this; 00084 } 00085 00086 00087 #endif 00088