gmime.global
Global functions for gmime3 library
fn checkVersion contentEncodingFromString contentEncodingToString iconvLocaleToUtf8 iconvLocaleToUtf8Length iconvUtf8ToLocale iconvUtf8ToLocaleLength init_ localeCharset localeLanguage shutdown utilsBestEncoding utilsDecode8bit utilsDecodeMessageId utilsGenerateMessageId utilsHeaderDecodeDate utilsHeaderDecodePhrase utilsHeaderDecodeText utilsHeaderEncodePhrase utilsHeaderEncodeText utilsHeaderFormatDate utilsHeaderUnfold utilsQuoteString utilsStructuredHeaderFold utilsTextIs8bit utilsUnquoteString utilsUnstructuredHeaderFold ydecodeStep yencodeClose yencodeStep
Functions 30
fn
bool checkVersion(uint major, uint minor, uint micro)Checks that the GMime library version meets the requirements of the required version.fn
gmime.types.ContentEncoding contentEncodingFromString(string str)Gets the appropriate #GMimeContentEncoding enumeration value based on the input string.fn
string contentEncodingToString(gmime.types.ContentEncoding encoding)Gets the string value of the content encoding.fn
string iconvLocaleToUtf8Length(string str, size_t n)Allocates a new string buffer containing the first `n` bytes of str converted to UTF-8.fn
string iconvUtf8ToLocale(string str)Allocates a new string buffer containing str converted to the user's locale charset.fn
string iconvUtf8ToLocaleLength(string str, size_t n)Allocates a new string buffer containing the first `n` bytes of str converted to the user's locale charset.fn
string localeCharset()Gets the user's locale charset (or iso-8859-1 by default). Returns: the user's locale charset (or iso-8859-1 by default).fn
string localeLanguage()Gets the user's locale language code (or null by default). Returns: the user's locale language code (or null by default).fn
gmime.types.ContentEncoding utilsBestEncoding(ubyte[] text)Determines the best content encoding for the first len bytes of text.fn
string utilsDecode8bit(gmime.parser_options.ParserOptions options, ubyte[] text)Attempts to convert text in an unknown 8bit/multibyte charset into UTF-8 by finding the charset which will convert the most bytes into valid UTF-8 characters as possible. If no exact match can be f...fn
string utilsHeaderDecodePhrase(gmime.parser_options.ParserOptions options, string phrase)Decodes an rfc2047 encoded 'phrase' header.fn
string utilsHeaderDecodeText(gmime.parser_options.ParserOptions options, string text)Decodes an rfc2047 encoded 'text' header.fn
string utilsHeaderEncodePhrase(gmime.format_options.FormatOptions options, string phrase, string charset = null)Encodes a 'phrase' header according to the rules in rfc2047.fn
string utilsHeaderEncodeText(gmime.format_options.FormatOptions options, string text, string charset = null)Encodes a 'text' header according to the rules in rfc2047.fn
string utilsHeaderFormatDate(glib.date_time.DateTime date)Allocates a string buffer containing the rfc822 formatted date string represented by date.fn
string utilsHeaderUnfold(string value)Unfolds a raw header value according to the rules in rfc822.fn
string utilsStructuredHeaderFold(gmime.parser_options.ParserOptions options, gmime.format_options.FormatOptions format, string header)Folds a structured header according to the rules in rfc822.fn
bool utilsTextIs8bit(ubyte[] text)Determines if text contains 8bit characters within the first len bytes.fn
string utilsUnstructuredHeaderFold(gmime.parser_options.ParserOptions options, gmime.format_options.FormatOptions format, string header)Folds an unstructured header according to the rules in rfc822.fn
size_t ydecodeStep(ubyte[] inbuf, ref ubyte[] outbuf, ref int state, ref uint pcrc, ref uint crc)Performs a 'decode step' on a chunk of yEncoded data of length inlen pointed to by inbuf and writes to outbuf. Assumes the =ybegin and =ypart lines have already been stripped off.fn
size_t yencodeClose(ubyte[] inbuf, ref ubyte[] outbuf, ref int state, ref uint pcrc, ref uint crc)Call this function when finished encoding data with [gmime.global.yencodeStep] to flush off the remaining state.fn
size_t yencodeStep(ubyte[] inbuf, ref ubyte[] outbuf, ref int state, ref uint pcrc, ref uint crc)Performs an yEncode 'encode step' on a chunk of raw data of length inlen pointed to by inbuf and writes to outbuf.