SourcePro® API Reference Guide

 
Loading...
Searching...
No Matches
RWMimeContentDispositionHeader Class Reference

Represents the Content-Disposition header of a MIME part. More...

#include <rw/mime/RWMimeContentDispositionHeader.h>

Inheritance diagram for RWMimeContentDispositionHeader:
RWMimeHeader RWHandleBase

Public Member Functions

 RWMimeContentDispositionHeader (const RWMimeContentDisposition &contentDisposition)
 
 RWMimeContentDispositionHeader (const RWMimeContentDispositionHeader &second)
 
 RWMimeContentDispositionHeader (const RWMimeHeader &second)
 
 RWMimeContentDispositionHeader (void)
 
virtual ~RWMimeContentDispositionHeader (void)
 
RWMimeContentDisposition getContentDisposition (void) const
 
RWMimeContentDispositionHeaderoperator= (const RWMimeContentDispositionHeader &second)
 
void setContentDisposition (const RWMimeContentDisposition &contentDisposition)
 
- Public Member Functions inherited from RWMimeHeader
 RWMimeHeader (const RWCString &label)
 
 RWMimeHeader (const RWMimeHeader &second)
 
 RWMimeHeader (void)
 
virtual ~RWMimeHeader (void)
 
RWCString asString (void) const
 
void fromString (const RWCString &headerString)
 
RWCString getLabel (void) const
 
RWMimeHeaderoperator= (const RWMimeHeader &second)
 
- Public Member Functions inherited from RWHandleBase
bool isValid (void) const
 
bool operator!= (const RWHandleBase &second) const
 
bool operator== (const RWHandleBase &second) const
 

Static Public Attributes

static const RWCString Label
 

Protected Member Functions

RWMimeContentDispositionHeaderImp & body (void) const
 
virtual bool checkLabel (const RWCString &label) const
 
- Protected Member Functions inherited from RWMimeHeader
RWMimeHeaderImp & body (void) const
 
- Protected Member Functions inherited from RWHandleBase
 RWHandleBase (const RWHandleBase &second)
 
 RWHandleBase (RWBodyBase *body)
 
 RWHandleBase (RWStaticCtor)
 
 RWHandleBase (void)
 
 ~RWHandleBase (void)
 
RWBodyBasebody (void) const
 
RWHandleBaseoperator= (const RWHandleBase &second)
 

Detailed Description

RWMimeContentDispositionHeader represents the Content-Disposition header of a MIME part. The Content-Disposition specifies the way in which a recipient should present the part.

The Content-Disposition Header specification, RFC 1806, defines two values for the header. A value of inline states that the part should be presented at the same time the rest of the message is presented. A value of attachment states that the part should be treated as a separate file attached to the message. The specification also defines an optional filename parameter that provides a filename for the MIME part.

An instance of this class is a handle to a private, reference-counted body.

Note
RWMimeContentDispositionHeader conforms to the Content-Disposition header requirements specified in RFC 1806.

Constructor & Destructor Documentation

◆ RWMimeContentDispositionHeader() [1/4]

RWMimeContentDispositionHeader::RWMimeContentDispositionHeader ( void )

Default constructor. Constructs a header with no value.

Note
A header with an empty value does not meet the requirements for a Content-Disposition header.

◆ RWMimeContentDispositionHeader() [2/4]

RWMimeContentDispositionHeader::RWMimeContentDispositionHeader ( const RWMimeContentDisposition & contentDisposition)

Constructs a header with the value contentDisposition.

◆ RWMimeContentDispositionHeader() [3/4]

RWMimeContentDispositionHeader::RWMimeContentDispositionHeader ( const RWMimeContentDispositionHeader & second)

Copy constructor. Constructs a new handle to the body second refers to.

◆ RWMimeContentDispositionHeader() [4/4]

RWMimeContentDispositionHeader::RWMimeContentDispositionHeader ( 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-Description".

◆ ~RWMimeContentDispositionHeader()

virtual RWMimeContentDispositionHeader::~RWMimeContentDispositionHeader ( void )
virtual

Destructor.

Member Function Documentation

◆ body()

RWMimeContentDispositionHeaderImp & RWMimeContentDispositionHeader::body ( void ) const
protected

Returns a reference to the underlying implementation.

◆ checkLabel()

virtual bool RWMimeContentDispositionHeader::checkLabel ( const RWCString & label) const
protectedvirtual

Returns true if label matches "Content-Disposition", false otherwise. The comparison is case-insensitive. The RWCString should contain 7-bit US-ASCII data.

Reimplemented from RWMimeHeader.

◆ getContentDisposition()

RWMimeContentDisposition RWMimeContentDispositionHeader::getContentDisposition ( void ) const

Returns a copy of self's value as an RWMimeContentDisposition.

◆ operator=()

RWMimeContentDispositionHeader & RWMimeContentDispositionHeader::operator= ( const RWMimeContentDispositionHeader & second)

Assignment operator. Makes self a handle identical to second.

◆ setContentDisposition()

void RWMimeContentDispositionHeader::setContentDisposition ( const RWMimeContentDisposition & contentDisposition)

Sets self's value to contentDisposition.

Member Data Documentation

◆ Label

const RWCString RWMimeContentDispositionHeader::Label
static

Static constant string containing "Content-Disposition", the label for a Content-Disposition header. The RWCString should contain 7-bit US-ASCII data.

Copyright © 2024 Rogue Wave Software, Inc., a Perforce company. All Rights Reserved.