public static string Encode(string str) { if (str == null) { throw new ArgumentNullException(); } var qp = new QuotedPrintable(); foreach (var line in Regex.Split(str, "\r\n|\r|\n")) { qp.NewLine(); qp.EncodeLine(line); } return(qp.ToString()); }
public static string Inline(string str) { if (str == null) { throw new ArgumentNullException(); } var qp = new QuotedPrintable(); qp.inline = true; qp.lineBreak = "?="; qp.NewLine(); qp.EncodeLine(str); qp.AppendSuffix(); return(qp.ToString()); }