IMAP4 servers may establish one or more namespaces for mailbox names. Examples of namespaces include a personal namespace, an other users' namespace, and a shared namespace. Namespaces may have different attribute values. If an IMAP4 server that supports the NAMESPACE option, it reports these attribute values in a NAMESPACE response when the client sends a NAMESPACE command. Two attributes are defined: the hierarchy delimiter and the prefix.
If the IMAP4 server allows hierarchical mailbox names, then the hierarchy delimiter is the character that separates the levels of the names. For example, a mailbox name might be "savedmail/2004/Q1", with the hierarchy delimiter "/".
The IMAP4 server may require a prefix for a namespace. An example is a prefix "~shared/" for shared mailboxes such as "~share/sales-team".
To get the attributes of an IMAP4 namespace, you may call the Imap4Client::Namespace() member function, then get the NamespaceResponse. From the NamespaceResponse, you may get the list NamespaceAttributes.
NAMESPACE command in RFC 2342
Public Member Functions | |
| NamespaceAttributes () | |
| Default constructor. | |
| NamespaceAttributes (const char *prefix, char delimiter) | |
| Constructor that takes an initial value. | |
| NamespaceAttributes (const NamespaceAttributes &) | |
| Copy constructor. | |
| ~NamespaceAttributes () | |
| Destructor. | |
| NamespaceAttributes & | operator= (const NamespaceAttributes &) |
| Assignment operator. | |
| const char * | Prefix () const |
| Gets the namespace prefix. | |
| char | Delimiter () const |
| Gets the namespace delimiter. | |
| void | ImportData (ListItem *root) |
| Called by the parser to set the data for this object. | |
|
|
Default constructor. |
|
||||||||||||
|
Constructor that takes an initial value.
|
|
|
Copy constructor.
|
|
|
Destructor. |
|
|
Gets the namespace delimiter. If the IMAP4 server allows hierarchical mailbox names, then the hierarchy delimiter is the character that separates the levels of the names. For example, a mailbox name might be "savedmail/2004/Q1", with the hierarchy delimiter "/".
|
|
|
Called by the parser to set the data for this object. Only the parser should call this function.
|
|
|
Assignment operator.
|
|
|
Gets the namespace prefix. The IMAP4 server may require a prefix for a namespace. An example is a prefix "~shared/" for shared mailboxes such as "~share/sales-team". If the prefix is empty, this member function returns an empty string.
|
Copyright © 2001-2005 Hunny Software, Inc. All rights reserved.