The macros and global functions fall into the following categories:
· Exception macros, which structure your exception handler.
· Exception-throwing functions, which generate exceptions of specific types.
· Termination functions, which cause program termination.
Exception Macros
| TRY | Designates a block of code for exception processing. |
| CATCH | Designates a block of code for catching an exception from the preceding TRY block. |
| CATCH_ALL | Designates a block of code for catching all exceptions from the preceding TRY block. |
| AND_CATCH | Designates a block of code for catching additional exception types from the preceding TRY block. |
| AND_CATCH_ALL | Designates a block of code for catching all other additional exception types thrown in a preceding TRY block. |
| END_CATCH | Ends the last CATCH or AND_CATCH code block. |
| END_CATCH_ALL | Ends the last CATCH_ALL code block. |
| THROW | Throws a specified exception. |
| THROW_LAST | Throws the currently handled exception to the next outer handler. |
Exception-Throwing Functions
| AfxThrowArchiveException | Throws an archive exception. |
| AfxThrowFileException | Throws a file exception. |
| AfxThrowMemoryException | Throws a memory exception. |
| AfxThrowNotSupportedException | Throws a not-supported exception. |
| AfxThrowResourceException | Throws a Windows resource-not-found exception. |
| AfxThrowUserException | Throws an exception in a user-initiated program action. |
OLE Exception
Functions
| AfxThrowOleDispatchException | Throws an exception within an OLE automation function. |
| AfxThrowOleException | Throws an OLE exception. |
DAO Exception
Functions
| AfxThrowDAOException | Throws a CDaoException from your own code. |
| AfxThrowDBException | Throws a CDBException from your own code. |
Termination Functions
| AfxAbort | Called to terminate an application when a fatal error occurs. |
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.