SourcePro C++ 12.0 |
SourcePro® C++ API Reference Guide |
SourcePro C++ Documentation Home |
Represents the Content-ID header of a MIME part. More...
#include <rw/mime/RWMimeContentIdHeader.h>
Public Member Functions | |
RWMimeContentIdHeader (void) | |
RWMimeContentIdHeader (const RWCString &id) | |
RWMimeContentIdHeader (const RWMimeContentIdHeader &second) | |
RWMimeContentIdHeader (const RWMimeHeader &second) | |
RWMimeContentIdHeader & | operator= (const RWMimeContentIdHeader &second) |
virtual | ~RWMimeContentIdHeader (void) |
RWCString | getId (void) const |
void | setId (const RWCString &id) |
Static Public Attributes | |
static const RWCString | Label |
Protected Member Functions | |
virtual bool | checkLabel (const RWCString &label) const |
RWMimeStructuredHeaderImp & | body (void) const |
RWMimeContentIdHeader represents the Content-ID header of a MIME part. The header is designed to allow external references to a MIME part. Therefore, the MIME format requires that the value of the header be world-unique. For example, a MIME message might contain the Content-ID header:
Content-ID: <part.0014@roguewave.example>
In general, a MIME message contains one Content-ID header at the top level of the message. For multipart/alternative
messages, the MIME specification suggests that each alternative have a different Content-ID header unless all alternatives contain equivalent information.
An instance of this class is a handle to a private, reference-counted body.
RWMimeContentIdHeader conforms to the Content-ID header requirements specified in RFC 2045, Section 7 (p. 26). For a discussion of Content-ID and multipart/alternative
messages, see RFC 2046 Section 5.1.4 (p. 24).
RWMimeContentIdHeader::RWMimeContentIdHeader | ( | void | ) |
Default constructor. Constructs a Content-ID header with the empty string for a value. Since the empty string is not world-unique, a default-constructed RWMimeContentHeader does not meet the requirements of the MIME format.
RWMimeContentIdHeader::RWMimeContentIdHeader | ( | const RWCString & | id | ) |
Constructs a Content-ID header with the value id. The RWCString should contain 7-bit US-ASCII data.
RWMimeContentIdHeader::RWMimeContentIdHeader | ( | const RWMimeContentIdHeader & | second | ) |
Copy constructor. Constructs a new handle to the body second refers to.
RWMimeContentIdHeader::RWMimeContentIdHeader | ( | const RWMimeHeader & | second | ) |
Conversion constructor. Constructs a new handle to the body second refers to. Throws RWMimeError if second does not have the label "Content-ID"
.
virtual RWMimeContentIdHeader::~RWMimeContentIdHeader | ( | void | ) | [virtual] |
Destructor.
RWMimeStructuredHeaderImp& RWMimeContentIdHeader::body | ( | void | ) | const [protected] |
Returns a reference to the underlying implementation.
Reimplemented from RWMimeHeader.
virtual bool RWMimeContentIdHeader::checkLabel | ( | const RWCString & | label | ) | const [protected, virtual] |
Returns true
if label matches "Content-ID"
, false
otherwise. The comparison is case-insensitive. The RWCString should contain 7-bit US-ASCII data.
Reimplemented from RWMimeHeader.
RWCString RWMimeContentIdHeader::getId | ( | void | ) | const |
Returns the content ID value of this header. The RWCString should contain 7-bit US-ASCII data.
RWMimeContentIdHeader& RWMimeContentIdHeader::operator= | ( | const RWMimeContentIdHeader & | second | ) |
Assignment operator. Makes self a handle identical to second.
void RWMimeContentIdHeader::setId | ( | const RWCString & | id | ) |
Sets the content ID value of this header. The RWCString should contain 7-bit US-ASCII data.
const RWCString RWMimeContentIdHeader::Label [static] |
Static constant string containing "Content-ID"
, the label for a Content-ID header. The RWCString should contain 7-bit US-ASCII data.
© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.