C# Class LumiSoft.Net.Mime.MimeUtils

Datei anzeigen Open project: jeske/StepsDB-alpha

Public Methods

Method Description
CreateMessageID ( ) : string

Creates Rfc 2822 3.6.4 message-id. Syntax: '<' id-left '@' id-right '>'.

DateTimeToRfc2822 ( System.DateTime dateTime ) : string

Converts date to rfc 2822 date time string.

ParseDate ( string date ) : System.DateTime

Parses rfc 2822 datetime.

ParseHeaderField ( string fieldName, Stream entryStrm ) : string

Parse header specified header field value. Use this method only if you need to get only one header field, otherwise use MimeParser.ParseHeaderField(string fieldName,string headers). This avoid parsing headers multiple times.

ParseHeaderField ( string fieldName, string headers ) : string

Parse header specified header field value.

ParseHeaderFiledParameter ( string fieldName, string parameterName, string headers ) : string

Parses header field parameter value. For example: CONTENT-TYPE: application\octet-stream; name="yourFileName.xxx", fieldName="CONTENT-TYPE:" and subFieldName="name".

ParseHeaders ( Stream entryStrm ) : string

Parses headers from message or mime entry.

Method Details

CreateMessageID() public static method

Creates Rfc 2822 3.6.4 message-id. Syntax: '<' id-left '@' id-right '>'.
public static CreateMessageID ( ) : string
return string

DateTimeToRfc2822() public static method

Converts date to rfc 2822 date time string.
public static DateTimeToRfc2822 ( System.DateTime dateTime ) : string
dateTime System.DateTime Date time value.
return string

ParseDate() public static method

Parses rfc 2822 datetime.
public static ParseDate ( string date ) : System.DateTime
date string Date string.
return System.DateTime

ParseHeaderField() public static method

Parse header specified header field value. Use this method only if you need to get only one header field, otherwise use MimeParser.ParseHeaderField(string fieldName,string headers). This avoid parsing headers multiple times.
public static ParseHeaderField ( string fieldName, Stream entryStrm ) : string
fieldName string Header field which to parse. Eg. Subject: .
entryStrm Stream Stream from where to read headers.
return string

ParseHeaderField() public static method

Parse header specified header field value.
public static ParseHeaderField ( string fieldName, string headers ) : string
fieldName string Header field which to parse. Eg. Subject: .
headers string Full headers string. Use MimeParser.ParseHeaders() to get this value.
return string

ParseHeaderFiledParameter() public static method

Parses header field parameter value. For example: CONTENT-TYPE: application\octet-stream; name="yourFileName.xxx", fieldName="CONTENT-TYPE:" and subFieldName="name".
public static ParseHeaderFiledParameter ( string fieldName, string parameterName, string headers ) : string
fieldName string Main header field name.
parameterName string Header field's parameter name.
headers string Full headrs string.
return string

ParseHeaders() public static method

Parses headers from message or mime entry.
public static ParseHeaders ( Stream entryStrm ) : string
entryStrm Stream Stream from where to read headers.
return string