Main Page   Class Hierarchy   Alphabetical List   Compound List   Examples  
contenttransferencoding.h
00001 /***************************************************************************
00002     copyright            : (C) 2002-2008 by Stefano Barbato
00003     email                : stefano@codesink.org
00004 
00005     $Id: contenttransferencoding.h,v 1.12 2008-10-07 11:06:25 tat Exp $
00006  ***************************************************************************/
00007 #ifndef _MIMETIC_CONTENT_TRANSFER_ENCODING_H_
00008 #define _MIMETIC_CONTENT_TRANSFER_ENCODING_H_
00009 #include <string>
00010 #include <mimetic/strutils.h>
00011 #include <mimetic/rfc822/fieldvalue.h>
00012 
00013 namespace mimetic
00014 {
00015 
00016 
00017 /// Content-Transfer-Encoding field value
00018 struct ContentTransferEncoding: public FieldValue
00019 {
00020     static const char label[];
00021     static const char base64[];
00022     static const char quoted_printable[];
00023     static const char binary[];
00024     static const char sevenbit[];
00025     static const char eightbit[];
00026 
00027     ContentTransferEncoding();
00028     ContentTransferEncoding(const char*);
00029     ContentTransferEncoding(const std::string&);
00030     const istring& mechanism() const;
00031     void mechanism(const std::string&);
00032     
00033     void set(const std::string&);
00034     std::string str() const;
00035 protected:
00036     FieldValue* clone() const;
00037 private:
00038     istring m_mechanism;
00039 };
00040 
00041 }
00042 
00043 #endif
00044