Inheritance diagram for Response:

There is very little functionality in the Response class, so you will have to cast any Response object to a more specific class. To do this safely, you must examine the result of the Name member function. The following code shows how to do this for an OK response:
void foo(Response& rsp) {
if (strcasecmp(rsp.Name(), "OK") == 0) {
OkResponse& okRsp = (OkResponse&) rsp;
// ...
}
}
All instances of Response should be obtained from an instance of Imap4Client.
Public Member Functions | |
| virtual | ~Response () |
| Destructor. | |
| const char * | Name () const |
| Returns the name of the response. | |
| TypeCode | Type () const |
| Returns the type of the response as an enumerated value. | |
Protected Member Functions | |
| Response (const char *name, TypeCode type) | |
| Constructor that takes a name argument. | |
| Response (const Response &other) | |
| Copy constructor. | |
| Response & | operator= (const Response &other) |
| Assignment operator. | |
|
|
Destructor. |
|
||||||||||||
|
This is the protected constructor that is called from the constructor of subclasses. The argument is the name of the response, for example, "OK" for an OK response.
|
|
|
Copy constructor
|
|
|
Returns the name of the response.
|
|
|
Assignment operator.
|
|
|
Returns the type of the response as an enumerated value.
|
Copyright © 2001-2005 Hunny Software, Inc. All rights reserved.