Click here to Skip to main content
15,891,409 members
Articles / Programming Languages / C#

A C# Implementation of Mime De/encode

Rate me:
Please Sign up or sign in to vote.
4.00/5 (16 votes)
21 Aug 2005CPOL 151K   4.2K   38  
A C# implementation of Mime de/encode
using System;

namespace MIME
{
	/// <summary>
	/// 
	/// </summary>
	public class MimeConst
	{
		public MimeConst()
		{
			// 
			// TODO: Add constructor logic here
			//
		}

		// field names
		public static string MimeVersion { get{return "MIME-Version";} }
		public static string ContentType { get{ return "Content-Type";} }
		public static string TransferEncoding { get{return "Content-Transfer-Encoding";} }
		public static string ContentID { get{return "Content-ID";} }
		public static string ContentDescription { get{return "Content-Description";} }
		public static string ContentDisposition { get{return "Content-Disposition";} }

		// parameter names
		public static string Charset { get{return "charset";} }
		public static string Name { get{return "name";} }
		public static string Filename { get{return "filename";} }
		public static string Boundary { get{return "boundary";} }

		// parameter values
		public static string Encoding7Bit { get{return "7bit";} }
		public static string Encoding8Bit { get{return "8bit";} }
		public static string EncodingBinary { get{return "binary";} }
		public static string EncodingQP { get{return "quoted-printable";} }
		public static string EncodingBase64 { get{return "base64";} }

		public static string MediaText { get{return "text";} }
		public static string MediaImage { get{return "image";} }
		public static string MediaAudio { get{return "audio";} }
		public static string MediaVideo { get{return "vedio";} }
		public static string MediaApplication { get{return "application";} }
		public static string MediaMultiPart { get{return "multipart";} }
		public static string MediaMessage { get{return "message";} }
	}
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Web Developer
China China
I think I have to start coding my life now...Smile | :)

Comments and Discussions