gmime: GMime 2.6 Reference Manual

## gmime gmime — Initialization, shutdown and version-check routines |

## Functions

#define | GMIME_CHECK_VERSION()
void | g_mime_init ()
void | g_mime_shutdown ()
gboolean | g_mime_check_version ()

## Types and Values

#define | GMIME_MAJOR_VERSION
#define | GMIME_MICRO_VERSION
#define | GMIME_MINOR_VERSION
#define | GMIME_BINARY_AGE
#define | GMIME_INTERFACE_AGE
#define | GMIME_ENABLE_RFC2047_WORKAROUNDS
#define | GMIME_ENABLE_USE_ONLY_USER_CHARSETS
extern const guint | gmime_major_version
extern const guint | gmime_minor_version
extern const guint | gmime_micro_version
extern const guint | gmime_binary_age
extern const guint | gmime_interface_age

## Description

Initialization, shutdown, and version-check functions.

## Functions

### GMIME_CHECK_VERSION()

    #define             GMIME_CHECK_VERSION(major,minor,micro)

Check whether a GMime version equal to or greater than `major` .`minor` .`micro` is present.

#### Parameters

major | Minimum major version |
minor | Minimum minor version |
micro | Minimum micro version |

### g_mime_init ()

    void
    g_mime_init (guint32 flags);

Initializes GMime.

Note: Calls `g_mime_charset_map_init()` and `g_mime_iconv_init()` as well.

#### Parameters

flags | initialization flags |

### g_mime_shutdown ()

    void
    g_mime_shutdown (void);

Frees internally allocated tables created in `g_mime_init()`. Also calls `g_mime_charset_map_shutdown()` and `g_mime_iconv_shutdown()`.

### g_mime_check_version ()

    gboolean
    g_mime_check_version (guint major,
                          guint minor,
                          guint micro);

Checks that the GMime library version meets the requirements of the required version.

#### Parameters

major | Minimum major version |
minor | Minimum minor version |
micro | Minimum micro version |

#### Returns

`TRUE` if the requirement is met or `FALSE` otherwise.

## Types and Values

### GMIME_MAJOR_VERSION

    #define GMIME_MAJOR_VERSION (2)

GMime's major version.

### GMIME_MICRO_VERSION

    #define GMIME_MICRO_VERSION (22)

GMime's micro version.

### GMIME_MINOR_VERSION

    #define GMIME_MINOR_VERSION (6)

GMime's minor version.

### GMIME_BINARY_AGE

    #define GMIME_BINARY_AGE    (622)

GMime's binary age.

### GMIME_INTERFACE_AGE

    #define GMIME_INTERFACE_AGE (0)

GMime's interface age.

### GMIME_ENABLE_RFC2047_WORKAROUNDS

    #define GMIME_ENABLE_RFC2047_WORKAROUNDS     (1 << 0)

Initialization flag to enable workarounds for badly formed rfc2047 encoded-words.

### GMIME_ENABLE_USE_ONLY_USER_CHARSETS

    #define GMIME_ENABLE_USE_ONLY_USER_CHARSETS  (1 << 1)

Initialization flag that hints to the rfc2047 encoder to use only the configured user-charsets (set via `g_mime_set_user_charsets()`) instead of trying to first use iso-8859-1.

Since: 2.6.16

### gmime_major_version

    extern const guint gmime_major_version;

GMime's major version.

### gmime_minor_version

    extern const guint gmime_minor_version;

GMime's minor version.

### gmime_micro_version

    extern const guint gmime_micro_version;

GMime's micro version.

### gmime_binary_age

    extern const guint gmime_binary_age;

GMime's binary age.

### gmime_interface_age

    extern const guint gmime_interface_age;

GMime's interface age.