public string Encode(string value) { StringBuilder str = new StringBuilder(); try { int key = CodingSQLHelper.SetKey(value); var result = CodingHelper.HuffmanEncode(value); str.Append(result); str.Append(Environment.NewLine); str.Append(CodingHelper.HuffmanShowTable(value)); str.AppendFormat("${0}", key); } catch (Exception exc) { } return(str.ToString()); }