]>
Commit | Line | Data |
---|---|---|
412da427 FC |
1 | #ifndef _SQUID_SRC_OUTOFBOUNDSEXCEPTION_H |
2 | #define _SQUID_SRC_OUTOFBOUNDSEXCEPTION_H | |
3 | ||
4 | #include "base/TextException.h" | |
5 | #include "SBuf.h" | |
6 | ||
7 | /** | |
8 | * Exception raised when the user is going out of bounds when accessing | |
9 | * a char within the SBuf | |
10 | */ | |
11 | class OutOfBoundsException : public TextException | |
12 | { | |
13 | public: | |
14 | OutOfBoundsException(const SBuf &buf, SBuf::size_type &pos, const char *aFileName = 0, int aLineNo = -1); | |
15 | virtual ~OutOfBoundsException() throw(); | |
16 | ||
17 | protected: | |
496a9e97 FC |
18 | SBuf theThrowingBuf; |
19 | SBuf::size_type accessedPosition; | |
412da427 FC |
20 | }; |
21 | ||
22 | #endif /* _SQUID_SRC_OUTOFBOUNDSEXCEPTION_H */ |