TwitCore/Helpers/Base64Handler.cs
/// <summary>
/// Encodes text to base4 string, based on the encoding type passed through
/// </summary>
/// <param name="encoding">Encoding, like UTF-8</param>
/// <param name="text">Text to be encoded</param>
/// <returns></returns>
Encodes text to base4 string, based on the encoding type passed through
Encodes text to base4 string based on the encoding type passed through
public static string EncodeBase64(this System.Text.Encoding encoding, string text) {
            if (text == null)
                return null;
            byte[] textAsBytes = encoding.GetBytes(text);
            return System.Convert.ToBase64String(textAsBytes);
        }
public static string EncodeBase64 ( this System . Text . Encoding encoding , string text ) { if ( text == null ) return null ; byte [ ] textAsBytes = encoding . GetBytes ( text ) ; return System . Convert . ToBase64String ( textAsBytes ) ; }
Encodes text to base4 string, based on the encoding type passed through
Encodes text to base4 string based on the encoding type passed through
None
System.Text.Encoding
this
text
string
Text to be encoded
Text to be encoded
encoding
Encoding, like UTF-8
Encoding like UTF - 8