Error::GetGeneric()
Returns generic error code of the most severe error.
Virtual? |
No |
|
Class |
||
Arguments |
None |
|
Returns |
|
the "generic" code of the most severe error |
Notes
For more sophisticated handling, use a "switch" statement based on the error number to handle different errors in different ways.
The generic error codes are not documented at this time.
Example
The following example attempts to establish a connection to a nonexistent server, and displays the resulting generic error code.
ClientApi client; Error e; client.SetPort( "bogus:12345" ); client.Init( &e ); if ( e.Test() ) printf( "Init() failed, error code %d.\n", e.GetGeneric() );
Executing the preceding code produces the following output:
Init() failed, error code 38.