encode

encodes data and returns as an ASCII hex string.

  1. char[] encode(ubyte[] data, char[] buff)
    char[]
    encode
    (
    ubyte[] data
    ,
    char[] buff
    )
  2. char[] encode(ubyte[] data)

Parameters

data ubyte[]

what is to be encoded

buff char[]

buffer large enough to hold encoded data

Examples

char[512] encodebuf;
char[] myEncodedString = encode(cast(ubyte[])"Hello, how are you today?", encodebuf);
Stdout(myEncodedString).newline; // 48656C6C6F2C20686F772061726520796F7520746F6461793F

Meta