
/* This file is generated by glib-mkenums, do not modify it. This code is licensed under the same license as the containing project. Note that it links to GLib, so must comply with the LGPL linking clauses. */

#include "mbim-enum-types.h"
/* enumerations from "../libmbim/src/libmbim-glib/mbim-cid.h" */
static const GEnumValue mbim_cid_basic_connect_values[] = {
    { MBIM_CID_BASIC_CONNECT_UNKNOWN, "MBIM_CID_BASIC_CONNECT_UNKNOWN", "unknown" },
    { MBIM_CID_BASIC_CONNECT_DEVICE_CAPS, "MBIM_CID_BASIC_CONNECT_DEVICE_CAPS", "device-caps" },
    { MBIM_CID_BASIC_CONNECT_SUBSCRIBER_READY_STATUS, "MBIM_CID_BASIC_CONNECT_SUBSCRIBER_READY_STATUS", "subscriber-ready-status" },
    { MBIM_CID_BASIC_CONNECT_RADIO_STATE, "MBIM_CID_BASIC_CONNECT_RADIO_STATE", "radio-state" },
    { MBIM_CID_BASIC_CONNECT_PIN, "MBIM_CID_BASIC_CONNECT_PIN", "pin" },
    { MBIM_CID_BASIC_CONNECT_PIN_LIST, "MBIM_CID_BASIC_CONNECT_PIN_LIST", "pin-list" },
    { MBIM_CID_BASIC_CONNECT_HOME_PROVIDER, "MBIM_CID_BASIC_CONNECT_HOME_PROVIDER", "home-provider" },
    { MBIM_CID_BASIC_CONNECT_PREFERRED_PROVIDERS, "MBIM_CID_BASIC_CONNECT_PREFERRED_PROVIDERS", "preferred-providers" },
    { MBIM_CID_BASIC_CONNECT_VISIBLE_PROVIDERS, "MBIM_CID_BASIC_CONNECT_VISIBLE_PROVIDERS", "visible-providers" },
    { MBIM_CID_BASIC_CONNECT_REGISTER_STATE, "MBIM_CID_BASIC_CONNECT_REGISTER_STATE", "register-state" },
    { MBIM_CID_BASIC_CONNECT_PACKET_SERVICE, "MBIM_CID_BASIC_CONNECT_PACKET_SERVICE", "packet-service" },
    { MBIM_CID_BASIC_CONNECT_SIGNAL_STATE, "MBIM_CID_BASIC_CONNECT_SIGNAL_STATE", "signal-state" },
    { MBIM_CID_BASIC_CONNECT_CONNECT, "MBIM_CID_BASIC_CONNECT_CONNECT", "connect" },
    { MBIM_CID_BASIC_CONNECT_PROVISIONED_CONTEXTS, "MBIM_CID_BASIC_CONNECT_PROVISIONED_CONTEXTS", "provisioned-contexts" },
    { MBIM_CID_BASIC_CONNECT_SERVICE_ACTIVATION, "MBIM_CID_BASIC_CONNECT_SERVICE_ACTIVATION", "service-activation" },
    { MBIM_CID_BASIC_CONNECT_IP_CONFIGURATION, "MBIM_CID_BASIC_CONNECT_IP_CONFIGURATION", "ip-configuration" },
    { MBIM_CID_BASIC_CONNECT_DEVICE_SERVICES, "MBIM_CID_BASIC_CONNECT_DEVICE_SERVICES", "device-services" },
    { MBIM_CID_BASIC_CONNECT_DEVICE_SERVICE_SUBSCRIBE_LIST, "MBIM_CID_BASIC_CONNECT_DEVICE_SERVICE_SUBSCRIBE_LIST", "device-service-subscribe-list" },
    { MBIM_CID_BASIC_CONNECT_PACKET_STATISTICS, "MBIM_CID_BASIC_CONNECT_PACKET_STATISTICS", "packet-statistics" },
    { MBIM_CID_BASIC_CONNECT_NETWORK_IDLE_HINT, "MBIM_CID_BASIC_CONNECT_NETWORK_IDLE_HINT", "network-idle-hint" },
    { MBIM_CID_BASIC_CONNECT_EMERGENCY_MODE, "MBIM_CID_BASIC_CONNECT_EMERGENCY_MODE", "emergency-mode" },
    { MBIM_CID_BASIC_CONNECT_IP_PACKET_FILTERS, "MBIM_CID_BASIC_CONNECT_IP_PACKET_FILTERS", "ip-packet-filters" },
    { MBIM_CID_BASIC_CONNECT_MULTICARRIER_PROVIDERS, "MBIM_CID_BASIC_CONNECT_MULTICARRIER_PROVIDERS", "multicarrier-providers" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_basic_connect_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidBasicConnect"),
                                      mbim_cid_basic_connect_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_BASIC_CONNECT_IS_ENUM__
const gchar *
mbim_cid_basic_connect_get_string (MbimCidBasicConnect val)
{
    guint i;

    for (i = 0; mbim_cid_basic_connect_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_basic_connect_values[i].value)
            return mbim_cid_basic_connect_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_BASIC_CONNECT_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_BASIC_CONNECT_IS_FLAGS__
gchar *
mbim_cid_basic_connect_build_string_from_mask (MbimCidBasicConnect mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_basic_connect_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_basic_connect_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_basic_connect_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_basic_connect_values[i].value) {
            guint c;
            gulong number = mbim_cid_basic_connect_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_basic_connect_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_BASIC_CONNECT_IS_FLAGS__ */
static const GEnumValue mbim_cid_sms_values[] = {
    { MBIM_CID_SMS_UNKNOWN, "MBIM_CID_SMS_UNKNOWN", "unknown" },
    { MBIM_CID_SMS_CONFIGURATION, "MBIM_CID_SMS_CONFIGURATION", "configuration" },
    { MBIM_CID_SMS_READ, "MBIM_CID_SMS_READ", "read" },
    { MBIM_CID_SMS_SEND, "MBIM_CID_SMS_SEND", "send" },
    { MBIM_CID_SMS_DELETE, "MBIM_CID_SMS_DELETE", "delete" },
    { MBIM_CID_SMS_MESSAGE_STORE_STATUS, "MBIM_CID_SMS_MESSAGE_STORE_STATUS", "message-store-status" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_sms_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidSms"),
                                      mbim_cid_sms_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_SMS_IS_ENUM__
const gchar *
mbim_cid_sms_get_string (MbimCidSms val)
{
    guint i;

    for (i = 0; mbim_cid_sms_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_sms_values[i].value)
            return mbim_cid_sms_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_SMS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_SMS_IS_FLAGS__
gchar *
mbim_cid_sms_build_string_from_mask (MbimCidSms mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_sms_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_sms_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_sms_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_sms_values[i].value) {
            guint c;
            gulong number = mbim_cid_sms_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_sms_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_SMS_IS_FLAGS__ */
static const GEnumValue mbim_cid_ussd_values[] = {
    { MBIM_CID_USSD_UNKNOWN, "MBIM_CID_USSD_UNKNOWN", "ussd-unknown" },
    { MBIM_CID_USSD, "MBIM_CID_USSD", "ussd" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ussd_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidUssd"),
                                      mbim_cid_ussd_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_USSD_IS_ENUM__
const gchar *
mbim_cid_ussd_get_string (MbimCidUssd val)
{
    guint i;

    for (i = 0; mbim_cid_ussd_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ussd_values[i].value)
            return mbim_cid_ussd_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_USSD_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_USSD_IS_FLAGS__
gchar *
mbim_cid_ussd_build_string_from_mask (MbimCidUssd mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ussd_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ussd_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ussd_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ussd_values[i].value) {
            guint c;
            gulong number = mbim_cid_ussd_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ussd_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_USSD_IS_FLAGS__ */
static const GEnumValue mbim_cid_phonebook_values[] = {
    { MBIM_CID_PHONEBOOK_UNKNOWN, "MBIM_CID_PHONEBOOK_UNKNOWN", "unknown" },
    { MBIM_CID_PHONEBOOK_CONFIGURATION, "MBIM_CID_PHONEBOOK_CONFIGURATION", "configuration" },
    { MBIM_CID_PHONEBOOK_READ, "MBIM_CID_PHONEBOOK_READ", "read" },
    { MBIM_CID_PHONEBOOK_DELETE, "MBIM_CID_PHONEBOOK_DELETE", "delete" },
    { MBIM_CID_PHONEBOOK_WRITE, "MBIM_CID_PHONEBOOK_WRITE", "write" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_phonebook_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidPhonebook"),
                                      mbim_cid_phonebook_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_PHONEBOOK_IS_ENUM__
const gchar *
mbim_cid_phonebook_get_string (MbimCidPhonebook val)
{
    guint i;

    for (i = 0; mbim_cid_phonebook_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_phonebook_values[i].value)
            return mbim_cid_phonebook_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_PHONEBOOK_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_PHONEBOOK_IS_FLAGS__
gchar *
mbim_cid_phonebook_build_string_from_mask (MbimCidPhonebook mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_phonebook_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_phonebook_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_phonebook_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_phonebook_values[i].value) {
            guint c;
            gulong number = mbim_cid_phonebook_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_phonebook_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_PHONEBOOK_IS_FLAGS__ */
static const GEnumValue mbim_cid_stk_values[] = {
    { MBIM_CID_STK_UNKNOWN, "MBIM_CID_STK_UNKNOWN", "unknown" },
    { MBIM_CID_STK_PAC, "MBIM_CID_STK_PAC", "pac" },
    { MBIM_CID_STK_TERMINAL_RESPONSE, "MBIM_CID_STK_TERMINAL_RESPONSE", "terminal-response" },
    { MBIM_CID_STK_ENVELOPE, "MBIM_CID_STK_ENVELOPE", "envelope" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_stk_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidStk"),
                                      mbim_cid_stk_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_STK_IS_ENUM__
const gchar *
mbim_cid_stk_get_string (MbimCidStk val)
{
    guint i;

    for (i = 0; mbim_cid_stk_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_stk_values[i].value)
            return mbim_cid_stk_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_STK_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_STK_IS_FLAGS__
gchar *
mbim_cid_stk_build_string_from_mask (MbimCidStk mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_stk_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_stk_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_stk_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_stk_values[i].value) {
            guint c;
            gulong number = mbim_cid_stk_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_stk_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_STK_IS_FLAGS__ */
static const GEnumValue mbim_cid_auth_values[] = {
    { MBIM_CID_AUTH_UNKNOWN, "MBIM_CID_AUTH_UNKNOWN", "unknown" },
    { MBIM_CID_AUTH_AKA, "MBIM_CID_AUTH_AKA", "aka" },
    { MBIM_CID_AUTH_AKAP, "MBIM_CID_AUTH_AKAP", "akap" },
    { MBIM_CID_AUTH_SIM, "MBIM_CID_AUTH_SIM", "sim" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_auth_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidAuth"),
                                      mbim_cid_auth_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_AUTH_IS_ENUM__
const gchar *
mbim_cid_auth_get_string (MbimCidAuth val)
{
    guint i;

    for (i = 0; mbim_cid_auth_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_auth_values[i].value)
            return mbim_cid_auth_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_AUTH_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_AUTH_IS_FLAGS__
gchar *
mbim_cid_auth_build_string_from_mask (MbimCidAuth mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_auth_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_auth_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_auth_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_auth_values[i].value) {
            guint c;
            gulong number = mbim_cid_auth_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_auth_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_AUTH_IS_FLAGS__ */
static const GEnumValue mbim_cid_dss_values[] = {
    { MBIM_CID_DSS_UNKNOWN, "MBIM_CID_DSS_UNKNOWN", "unknown" },
    { MBIM_CID_DSS_CONNECT, "MBIM_CID_DSS_CONNECT", "connect" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_dss_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidDss"),
                                      mbim_cid_dss_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_DSS_IS_ENUM__
const gchar *
mbim_cid_dss_get_string (MbimCidDss val)
{
    guint i;

    for (i = 0; mbim_cid_dss_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_dss_values[i].value)
            return mbim_cid_dss_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_DSS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_DSS_IS_FLAGS__
gchar *
mbim_cid_dss_build_string_from_mask (MbimCidDss mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_dss_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_dss_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_dss_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_dss_values[i].value) {
            guint c;
            gulong number = mbim_cid_dss_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_dss_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_DSS_IS_FLAGS__ */
static const GEnumValue mbim_cid_ms_firmware_id_values[] = {
    { MBIM_CID_MS_FIRMWARE_ID_UNKNOWN, "MBIM_CID_MS_FIRMWARE_ID_UNKNOWN", "unknown" },
    { MBIM_CID_MS_FIRMWARE_ID_GET, "MBIM_CID_MS_FIRMWARE_ID_GET", "get" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ms_firmware_id_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidMsFirmwareId"),
                                      mbim_cid_ms_firmware_id_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_MS_FIRMWARE_ID_IS_ENUM__
const gchar *
mbim_cid_ms_firmware_id_get_string (MbimCidMsFirmwareId val)
{
    guint i;

    for (i = 0; mbim_cid_ms_firmware_id_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ms_firmware_id_values[i].value)
            return mbim_cid_ms_firmware_id_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_MS_FIRMWARE_ID_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_MS_FIRMWARE_ID_IS_FLAGS__
gchar *
mbim_cid_ms_firmware_id_build_string_from_mask (MbimCidMsFirmwareId mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ms_firmware_id_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ms_firmware_id_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ms_firmware_id_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ms_firmware_id_values[i].value) {
            guint c;
            gulong number = mbim_cid_ms_firmware_id_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ms_firmware_id_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_MS_FIRMWARE_ID_IS_FLAGS__ */
static const GEnumValue mbim_cid_ms_host_shutdown_values[] = {
    { MBIM_CID_MS_HOST_SHUTDOWN_UNKNOWN, "MBIM_CID_MS_HOST_SHUTDOWN_UNKNOWN", "unknown" },
    { MBIM_CID_MS_HOST_SHUTDOWN_NOTIFY, "MBIM_CID_MS_HOST_SHUTDOWN_NOTIFY", "notify" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ms_host_shutdown_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidMsHostShutdown"),
                                      mbim_cid_ms_host_shutdown_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_MS_HOST_SHUTDOWN_IS_ENUM__
const gchar *
mbim_cid_ms_host_shutdown_get_string (MbimCidMsHostShutdown val)
{
    guint i;

    for (i = 0; mbim_cid_ms_host_shutdown_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ms_host_shutdown_values[i].value)
            return mbim_cid_ms_host_shutdown_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_MS_HOST_SHUTDOWN_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_MS_HOST_SHUTDOWN_IS_FLAGS__
gchar *
mbim_cid_ms_host_shutdown_build_string_from_mask (MbimCidMsHostShutdown mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ms_host_shutdown_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ms_host_shutdown_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ms_host_shutdown_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ms_host_shutdown_values[i].value) {
            guint c;
            gulong number = mbim_cid_ms_host_shutdown_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ms_host_shutdown_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_MS_HOST_SHUTDOWN_IS_FLAGS__ */
static const GEnumValue mbim_cid_ms_sar_values[] = {
    { MBIM_CID_MS_SAR_UNKNOWN, "MBIM_CID_MS_SAR_UNKNOWN", "unknown" },
    { MBIM_CID_MS_SAR_CONFIG, "MBIM_CID_MS_SAR_CONFIG", "config" },
    { MBIM_CID_MS_SAR_TRANSMISSION_STATUS, "MBIM_CID_MS_SAR_TRANSMISSION_STATUS", "transmission-status" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ms_sar_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidMsSar"),
                                      mbim_cid_ms_sar_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_MS_SAR_IS_ENUM__
const gchar *
mbim_cid_ms_sar_get_string (MbimCidMsSar val)
{
    guint i;

    for (i = 0; mbim_cid_ms_sar_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ms_sar_values[i].value)
            return mbim_cid_ms_sar_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_MS_SAR_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_MS_SAR_IS_FLAGS__
gchar *
mbim_cid_ms_sar_build_string_from_mask (MbimCidMsSar mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ms_sar_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ms_sar_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ms_sar_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ms_sar_values[i].value) {
            guint c;
            gulong number = mbim_cid_ms_sar_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ms_sar_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_MS_SAR_IS_FLAGS__ */
static const GEnumValue mbim_cid_proxy_control_values[] = {
    { MBIM_CID_PROXY_CONTROL_UNKNOWN, "MBIM_CID_PROXY_CONTROL_UNKNOWN", "unknown" },
    { MBIM_CID_PROXY_CONTROL_CONFIGURATION, "MBIM_CID_PROXY_CONTROL_CONFIGURATION", "configuration" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_proxy_control_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidProxyControl"),
                                      mbim_cid_proxy_control_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_PROXY_CONTROL_IS_ENUM__
const gchar *
mbim_cid_proxy_control_get_string (MbimCidProxyControl val)
{
    guint i;

    for (i = 0; mbim_cid_proxy_control_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_proxy_control_values[i].value)
            return mbim_cid_proxy_control_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_PROXY_CONTROL_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_PROXY_CONTROL_IS_FLAGS__
gchar *
mbim_cid_proxy_control_build_string_from_mask (MbimCidProxyControl mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_proxy_control_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_proxy_control_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_proxy_control_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_proxy_control_values[i].value) {
            guint c;
            gulong number = mbim_cid_proxy_control_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_proxy_control_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_PROXY_CONTROL_IS_FLAGS__ */
static const GEnumValue mbim_cid_qmi_values[] = {
    { MBIM_CID_QMI_UNKNOWN, "MBIM_CID_QMI_UNKNOWN", "unknown" },
    { MBIM_CID_QMI_MSG, "MBIM_CID_QMI_MSG", "msg" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_qmi_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidQmi"),
                                      mbim_cid_qmi_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_QMI_IS_ENUM__
const gchar *
mbim_cid_qmi_get_string (MbimCidQmi val)
{
    guint i;

    for (i = 0; mbim_cid_qmi_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_qmi_values[i].value)
            return mbim_cid_qmi_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_QMI_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_QMI_IS_FLAGS__
gchar *
mbim_cid_qmi_build_string_from_mask (MbimCidQmi mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_qmi_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_qmi_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_qmi_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_qmi_values[i].value) {
            guint c;
            gulong number = mbim_cid_qmi_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_qmi_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_QMI_IS_FLAGS__ */
static const GEnumValue mbim_cid_atds_values[] = {
    { MBIM_CID_ATDS_UNKNOWN, "MBIM_CID_ATDS_UNKNOWN", "unknown" },
    { MBIM_CID_ATDS_SIGNAL, "MBIM_CID_ATDS_SIGNAL", "signal" },
    { MBIM_CID_ATDS_LOCATION, "MBIM_CID_ATDS_LOCATION", "location" },
    { MBIM_CID_ATDS_OPERATORS, "MBIM_CID_ATDS_OPERATORS", "operators" },
    { MBIM_CID_ATDS_RAT, "MBIM_CID_ATDS_RAT", "rat" },
    { MBIM_CID_ATDS_REGISTER_STATE, "MBIM_CID_ATDS_REGISTER_STATE", "register-state" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_atds_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidAtds"),
                                      mbim_cid_atds_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_ATDS_IS_ENUM__
const gchar *
mbim_cid_atds_get_string (MbimCidAtds val)
{
    guint i;

    for (i = 0; mbim_cid_atds_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_atds_values[i].value)
            return mbim_cid_atds_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_ATDS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_ATDS_IS_FLAGS__
gchar *
mbim_cid_atds_build_string_from_mask (MbimCidAtds mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_atds_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_atds_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_atds_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_atds_values[i].value) {
            guint c;
            gulong number = mbim_cid_atds_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_atds_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_ATDS_IS_FLAGS__ */
static const GEnumValue mbim_cid_intel_firmware_update_values[] = {
    { MBIM_CID_INTEL_FIRMWARE_UPDATE_UNKNOWN, "MBIM_CID_INTEL_FIRMWARE_UPDATE_UNKNOWN", "unknown" },
    { MBIM_CID_INTEL_FIRMWARE_UPDATE_MODEM_REBOOT, "MBIM_CID_INTEL_FIRMWARE_UPDATE_MODEM_REBOOT", "modem-reboot" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_intel_firmware_update_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidIntelFirmwareUpdate"),
                                      mbim_cid_intel_firmware_update_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_INTEL_FIRMWARE_UPDATE_IS_ENUM__
const gchar *
mbim_cid_intel_firmware_update_get_string (MbimCidIntelFirmwareUpdate val)
{
    guint i;

    for (i = 0; mbim_cid_intel_firmware_update_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_intel_firmware_update_values[i].value)
            return mbim_cid_intel_firmware_update_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_INTEL_FIRMWARE_UPDATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_INTEL_FIRMWARE_UPDATE_IS_FLAGS__
gchar *
mbim_cid_intel_firmware_update_build_string_from_mask (MbimCidIntelFirmwareUpdate mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_intel_firmware_update_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_intel_firmware_update_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_intel_firmware_update_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_intel_firmware_update_values[i].value) {
            guint c;
            gulong number = mbim_cid_intel_firmware_update_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_intel_firmware_update_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_INTEL_FIRMWARE_UPDATE_IS_FLAGS__ */
static const GEnumValue mbim_cid_qdu_values[] = {
    { MBIM_CID_QDU_UNKNOWN, "MBIM_CID_QDU_UNKNOWN", "unknown" },
    { MBIM_CID_QDU_UPDATE_SESSION, "MBIM_CID_QDU_UPDATE_SESSION", "update-session" },
    { MBIM_CID_QDU_FILE_OPEN, "MBIM_CID_QDU_FILE_OPEN", "file-open" },
    { MBIM_CID_QDU_FILE_WRITE, "MBIM_CID_QDU_FILE_WRITE", "file-write" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_qdu_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidQdu"),
                                      mbim_cid_qdu_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_QDU_IS_ENUM__
const gchar *
mbim_cid_qdu_get_string (MbimCidQdu val)
{
    guint i;

    for (i = 0; mbim_cid_qdu_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_qdu_values[i].value)
            return mbim_cid_qdu_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_QDU_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_QDU_IS_FLAGS__
gchar *
mbim_cid_qdu_build_string_from_mask (MbimCidQdu mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_qdu_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_qdu_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_qdu_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_qdu_values[i].value) {
            guint c;
            gulong number = mbim_cid_qdu_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_qdu_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_QDU_IS_FLAGS__ */
static const GEnumValue mbim_cid_ms_basic_connect_extensions_values[] = {
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_UNKNOWN, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_UNKNOWN", "unknown" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_PROVISIONED_CONTEXTS, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_PROVISIONED_CONTEXTS", "provisioned-contexts" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_NETWORK_BLACKLIST, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_NETWORK_BLACKLIST", "network-blacklist" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_LTE_ATTACH_CONFIGURATION, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_LTE_ATTACH_CONFIGURATION", "lte-attach-configuration" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_LTE_ATTACH_INFO, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_LTE_ATTACH_INFO", "lte-attach-info" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_SYS_CAPS, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_SYS_CAPS", "sys-caps" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_CAPS, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_CAPS", "device-caps" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_SLOT_MAPPINGS, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_SLOT_MAPPINGS", "device-slot-mappings" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_SLOT_INFO_STATUS, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_SLOT_INFO_STATUS", "slot-info-status" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_PCO, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_PCO", "pco" },
    { MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_RESET, "MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_DEVICE_RESET", "device-reset" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ms_basic_connect_extensions_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidMsBasicConnectExtensions"),
                                      mbim_cid_ms_basic_connect_extensions_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_IS_ENUM__
const gchar *
mbim_cid_ms_basic_connect_extensions_get_string (MbimCidMsBasicConnectExtensions val)
{
    guint i;

    for (i = 0; mbim_cid_ms_basic_connect_extensions_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ms_basic_connect_extensions_values[i].value)
            return mbim_cid_ms_basic_connect_extensions_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_IS_FLAGS__
gchar *
mbim_cid_ms_basic_connect_extensions_build_string_from_mask (MbimCidMsBasicConnectExtensions mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ms_basic_connect_extensions_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ms_basic_connect_extensions_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ms_basic_connect_extensions_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ms_basic_connect_extensions_values[i].value) {
            guint c;
            gulong number = mbim_cid_ms_basic_connect_extensions_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ms_basic_connect_extensions_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_MS_BASIC_CONNECT_EXTENSIONS_IS_FLAGS__ */
static const GEnumValue mbim_cid_ms_uicc_low_level_access_values[] = {
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_UNKNOWN, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_UNKNOWN", "unknown" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_ATR, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_ATR", "atr" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_OPEN_CHANNEL, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_OPEN_CHANNEL", "open-channel" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_CLOSE_CHANNEL, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_CLOSE_CHANNEL", "close-channel" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_APDU, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_APDU", "apdu" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_TERMINAL_CAPABILITY, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_TERMINAL_CAPABILITY", "terminal-capability" },
    { MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_RESET, "MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_RESET", "reset" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_ms_uicc_low_level_access_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidMsUiccLowLevelAccess"),
                                      mbim_cid_ms_uicc_low_level_access_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_IS_ENUM__
const gchar *
mbim_cid_ms_uicc_low_level_access_get_string (MbimCidMsUiccLowLevelAccess val)
{
    guint i;

    for (i = 0; mbim_cid_ms_uicc_low_level_access_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_ms_uicc_low_level_access_values[i].value)
            return mbim_cid_ms_uicc_low_level_access_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_IS_FLAGS__
gchar *
mbim_cid_ms_uicc_low_level_access_build_string_from_mask (MbimCidMsUiccLowLevelAccess mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_ms_uicc_low_level_access_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_ms_uicc_low_level_access_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_ms_uicc_low_level_access_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_ms_uicc_low_level_access_values[i].value) {
            guint c;
            gulong number = mbim_cid_ms_uicc_low_level_access_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_ms_uicc_low_level_access_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_MS_UICC_LOW_LEVEL_ACCESS_IS_FLAGS__ */
static const GEnumValue mbim_cid_quectel_values[] = {
    { MBIM_CID_QUECTEL_UNKNOWN, "MBIM_CID_QUECTEL_UNKNOWN", "unknown" },
    { MBIM_CID_QUECTEL_RADIO_STATE, "MBIM_CID_QUECTEL_RADIO_STATE", "radio-state" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cid_quectel_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCidQuectel"),
                                      mbim_cid_quectel_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CID_QUECTEL_IS_ENUM__
const gchar *
mbim_cid_quectel_get_string (MbimCidQuectel val)
{
    guint i;

    for (i = 0; mbim_cid_quectel_values[i].value_nick; i++) {
        if ((gint)val == mbim_cid_quectel_values[i].value)
            return mbim_cid_quectel_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CID_QUECTEL_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CID_QUECTEL_IS_FLAGS__
gchar *
mbim_cid_quectel_build_string_from_mask (MbimCidQuectel mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cid_quectel_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cid_quectel_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cid_quectel_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cid_quectel_values[i].value) {
            guint c;
            gulong number = mbim_cid_quectel_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cid_quectel_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CID_QUECTEL_IS_FLAGS__ */
/* enumerations from "../libmbim/src/libmbim-glib/mbim-enums.h" */
static const GEnumValue mbim_device_type_values[] = {
    { MBIM_DEVICE_TYPE_UNKNOWN, "MBIM_DEVICE_TYPE_UNKNOWN", "unknown" },
    { MBIM_DEVICE_TYPE_EMBEDDED, "MBIM_DEVICE_TYPE_EMBEDDED", "embedded" },
    { MBIM_DEVICE_TYPE_REMOVABLE, "MBIM_DEVICE_TYPE_REMOVABLE", "removable" },
    { MBIM_DEVICE_TYPE_REMOTE, "MBIM_DEVICE_TYPE_REMOTE", "remote" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_device_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimDeviceType"),
                                      mbim_device_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_DEVICE_TYPE_IS_ENUM__
const gchar *
mbim_device_type_get_string (MbimDeviceType val)
{
    guint i;

    for (i = 0; mbim_device_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_device_type_values[i].value)
            return mbim_device_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_DEVICE_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_DEVICE_TYPE_IS_FLAGS__
gchar *
mbim_device_type_build_string_from_mask (MbimDeviceType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_device_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_device_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_device_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_device_type_values[i].value) {
            guint c;
            gulong number = mbim_device_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_device_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_DEVICE_TYPE_IS_FLAGS__ */
static const GFlagsValue mbim_cellular_class_values[] = {
    { MBIM_CELLULAR_CLASS_GSM, "MBIM_CELLULAR_CLASS_GSM", "gsm" },
    { MBIM_CELLULAR_CLASS_CDMA, "MBIM_CELLULAR_CLASS_CDMA", "cdma" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_cellular_class_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimCellularClass"),
                                      mbim_cellular_class_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CELLULAR_CLASS_IS_ENUM__
const gchar *
mbim_cellular_class_get_string (MbimCellularClass val)
{
    guint i;

    for (i = 0; mbim_cellular_class_values[i].value_nick; i++) {
        if ((gint)val == mbim_cellular_class_values[i].value)
            return mbim_cellular_class_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CELLULAR_CLASS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CELLULAR_CLASS_IS_FLAGS__
gchar *
mbim_cellular_class_build_string_from_mask (MbimCellularClass mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_cellular_class_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_cellular_class_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_cellular_class_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_cellular_class_values[i].value) {
            guint c;
            gulong number = mbim_cellular_class_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_cellular_class_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CELLULAR_CLASS_IS_FLAGS__ */
static const GEnumValue mbim_voice_class_values[] = {
    { MBIM_VOICE_CLASS_UNKNOWN, "MBIM_VOICE_CLASS_UNKNOWN", "unknown" },
    { MBIM_VOICE_CLASS_NO_VOICE, "MBIM_VOICE_CLASS_NO_VOICE", "no-voice" },
    { MBIM_VOICE_CLASS_SEPARATED_VOICE_DATA, "MBIM_VOICE_CLASS_SEPARATED_VOICE_DATA", "separated-voice-data" },
    { MBIM_VOICE_CLASS_SIMULTANEOUS_VOICE_DATA, "MBIM_VOICE_CLASS_SIMULTANEOUS_VOICE_DATA", "simultaneous-voice-data" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_voice_class_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimVoiceClass"),
                                      mbim_voice_class_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_VOICE_CLASS_IS_ENUM__
const gchar *
mbim_voice_class_get_string (MbimVoiceClass val)
{
    guint i;

    for (i = 0; mbim_voice_class_values[i].value_nick; i++) {
        if ((gint)val == mbim_voice_class_values[i].value)
            return mbim_voice_class_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_VOICE_CLASS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_VOICE_CLASS_IS_FLAGS__
gchar *
mbim_voice_class_build_string_from_mask (MbimVoiceClass mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_voice_class_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_voice_class_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_voice_class_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_voice_class_values[i].value) {
            guint c;
            gulong number = mbim_voice_class_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_voice_class_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_VOICE_CLASS_IS_FLAGS__ */
static const GFlagsValue mbim_sim_class_values[] = {
    { MBIM_SIM_CLASS_LOGICAL, "MBIM_SIM_CLASS_LOGICAL", "logical" },
    { MBIM_SIM_CLASS_REMOVABLE, "MBIM_SIM_CLASS_REMOVABLE", "removable" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sim_class_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimSimClass"),
                                      mbim_sim_class_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SIM_CLASS_IS_ENUM__
const gchar *
mbim_sim_class_get_string (MbimSimClass val)
{
    guint i;

    for (i = 0; mbim_sim_class_values[i].value_nick; i++) {
        if ((gint)val == mbim_sim_class_values[i].value)
            return mbim_sim_class_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SIM_CLASS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SIM_CLASS_IS_FLAGS__
gchar *
mbim_sim_class_build_string_from_mask (MbimSimClass mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sim_class_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sim_class_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sim_class_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sim_class_values[i].value) {
            guint c;
            gulong number = mbim_sim_class_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sim_class_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SIM_CLASS_IS_FLAGS__ */
static const GFlagsValue mbim_data_class_values[] = {
    { MBIM_DATA_CLASS_GPRS, "MBIM_DATA_CLASS_GPRS", "gprs" },
    { MBIM_DATA_CLASS_EDGE, "MBIM_DATA_CLASS_EDGE", "edge" },
    { MBIM_DATA_CLASS_UMTS, "MBIM_DATA_CLASS_UMTS", "umts" },
    { MBIM_DATA_CLASS_HSDPA, "MBIM_DATA_CLASS_HSDPA", "hsdpa" },
    { MBIM_DATA_CLASS_HSUPA, "MBIM_DATA_CLASS_HSUPA", "hsupa" },
    { MBIM_DATA_CLASS_LTE, "MBIM_DATA_CLASS_LTE", "lte" },
    { MBIM_DATA_CLASS_1XRTT, "MBIM_DATA_CLASS_1XRTT", "1xrtt" },
    { MBIM_DATA_CLASS_1XEVDO, "MBIM_DATA_CLASS_1XEVDO", "1xevdo" },
    { MBIM_DATA_CLASS_1XEVDO_REVA, "MBIM_DATA_CLASS_1XEVDO_REVA", "1xevdo-reva" },
    { MBIM_DATA_CLASS_1XEVDV, "MBIM_DATA_CLASS_1XEVDV", "1xevdv" },
    { MBIM_DATA_CLASS_3XRTT, "MBIM_DATA_CLASS_3XRTT", "3xrtt" },
    { MBIM_DATA_CLASS_1XEVDO_REVB, "MBIM_DATA_CLASS_1XEVDO_REVB", "1xevdo-revb" },
    { MBIM_DATA_CLASS_UMB, "MBIM_DATA_CLASS_UMB", "umb" },
    { MBIM_DATA_CLASS_CUSTOM, "MBIM_DATA_CLASS_CUSTOM", "custom" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_data_class_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimDataClass"),
                                      mbim_data_class_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_DATA_CLASS_IS_ENUM__
const gchar *
mbim_data_class_get_string (MbimDataClass val)
{
    guint i;

    for (i = 0; mbim_data_class_values[i].value_nick; i++) {
        if ((gint)val == mbim_data_class_values[i].value)
            return mbim_data_class_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_DATA_CLASS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_DATA_CLASS_IS_FLAGS__
gchar *
mbim_data_class_build_string_from_mask (MbimDataClass mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_data_class_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_data_class_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_data_class_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_data_class_values[i].value) {
            guint c;
            gulong number = mbim_data_class_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_data_class_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_DATA_CLASS_IS_FLAGS__ */
static const GFlagsValue mbim_sms_caps_values[] = {
    { MBIM_SMS_CAPS_PDU_RECEIVE, "MBIM_SMS_CAPS_PDU_RECEIVE", "pdu-receive" },
    { MBIM_SMS_CAPS_PDU_SEND, "MBIM_SMS_CAPS_PDU_SEND", "pdu-send" },
    { MBIM_SMS_CAPS_TEXT_RECEIVE, "MBIM_SMS_CAPS_TEXT_RECEIVE", "text-receive" },
    { MBIM_SMS_CAPS_TEXT_SEND, "MBIM_SMS_CAPS_TEXT_SEND", "text-send" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_caps_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimSmsCaps"),
                                      mbim_sms_caps_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_CAPS_IS_ENUM__
const gchar *
mbim_sms_caps_get_string (MbimSmsCaps val)
{
    guint i;

    for (i = 0; mbim_sms_caps_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_caps_values[i].value)
            return mbim_sms_caps_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_CAPS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_CAPS_IS_FLAGS__
gchar *
mbim_sms_caps_build_string_from_mask (MbimSmsCaps mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_caps_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_caps_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_caps_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_caps_values[i].value) {
            guint c;
            gulong number = mbim_sms_caps_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_caps_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_CAPS_IS_FLAGS__ */
static const GFlagsValue mbim_ctrl_caps_values[] = {
    { MBIM_CTRL_CAPS_REG_MANUAL, "MBIM_CTRL_CAPS_REG_MANUAL", "reg-manual" },
    { MBIM_CTRL_CAPS_HW_RADIO_SWITCH, "MBIM_CTRL_CAPS_HW_RADIO_SWITCH", "hw-radio-switch" },
    { MBIM_CTRL_CAPS_CDMA_MOBILE_IP, "MBIM_CTRL_CAPS_CDMA_MOBILE_IP", "cdma-mobile-ip" },
    { MBIM_CTRL_CAPS_CDMA_SIMPLE_IP, "MBIM_CTRL_CAPS_CDMA_SIMPLE_IP", "cdma-simple-ip" },
    { MBIM_CTRL_CAPS_MULTI_CARRIER, "MBIM_CTRL_CAPS_MULTI_CARRIER", "multi-carrier" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ctrl_caps_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimCtrlCaps"),
                                      mbim_ctrl_caps_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CTRL_CAPS_IS_ENUM__
const gchar *
mbim_ctrl_caps_get_string (MbimCtrlCaps val)
{
    guint i;

    for (i = 0; mbim_ctrl_caps_values[i].value_nick; i++) {
        if ((gint)val == mbim_ctrl_caps_values[i].value)
            return mbim_ctrl_caps_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CTRL_CAPS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CTRL_CAPS_IS_FLAGS__
gchar *
mbim_ctrl_caps_build_string_from_mask (MbimCtrlCaps mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ctrl_caps_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ctrl_caps_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ctrl_caps_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ctrl_caps_values[i].value) {
            guint c;
            gulong number = mbim_ctrl_caps_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ctrl_caps_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CTRL_CAPS_IS_FLAGS__ */
static const GEnumValue mbim_subscriber_ready_state_values[] = {
    { MBIM_SUBSCRIBER_READY_STATE_NOT_INITIALIZED, "MBIM_SUBSCRIBER_READY_STATE_NOT_INITIALIZED", "not-initialized" },
    { MBIM_SUBSCRIBER_READY_STATE_INITIALIZED, "MBIM_SUBSCRIBER_READY_STATE_INITIALIZED", "initialized" },
    { MBIM_SUBSCRIBER_READY_STATE_SIM_NOT_INSERTED, "MBIM_SUBSCRIBER_READY_STATE_SIM_NOT_INSERTED", "sim-not-inserted" },
    { MBIM_SUBSCRIBER_READY_STATE_BAD_SIM, "MBIM_SUBSCRIBER_READY_STATE_BAD_SIM", "bad-sim" },
    { MBIM_SUBSCRIBER_READY_STATE_FAILURE, "MBIM_SUBSCRIBER_READY_STATE_FAILURE", "failure" },
    { MBIM_SUBSCRIBER_READY_STATE_NOT_ACTIVATED, "MBIM_SUBSCRIBER_READY_STATE_NOT_ACTIVATED", "not-activated" },
    { MBIM_SUBSCRIBER_READY_STATE_DEVICE_LOCKED, "MBIM_SUBSCRIBER_READY_STATE_DEVICE_LOCKED", "device-locked" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_subscriber_ready_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSubscriberReadyState"),
                                      mbim_subscriber_ready_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SUBSCRIBER_READY_STATE_IS_ENUM__
const gchar *
mbim_subscriber_ready_state_get_string (MbimSubscriberReadyState val)
{
    guint i;

    for (i = 0; mbim_subscriber_ready_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_subscriber_ready_state_values[i].value)
            return mbim_subscriber_ready_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SUBSCRIBER_READY_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SUBSCRIBER_READY_STATE_IS_FLAGS__
gchar *
mbim_subscriber_ready_state_build_string_from_mask (MbimSubscriberReadyState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_subscriber_ready_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_subscriber_ready_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_subscriber_ready_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_subscriber_ready_state_values[i].value) {
            guint c;
            gulong number = mbim_subscriber_ready_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_subscriber_ready_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SUBSCRIBER_READY_STATE_IS_FLAGS__ */
static const GFlagsValue mbim_ready_info_flag_values[] = {
    { MBIM_READY_INFO_FLAG_NONE, "MBIM_READY_INFO_FLAG_NONE", "none" },
    { MBIM_READY_INFO_FLAG_PROTECT_UNIQUE_ID, "MBIM_READY_INFO_FLAG_PROTECT_UNIQUE_ID", "protect-unique-id" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ready_info_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimReadyInfoFlag"),
                                      mbim_ready_info_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_READY_INFO_FLAG_IS_ENUM__
const gchar *
mbim_ready_info_flag_get_string (MbimReadyInfoFlag val)
{
    guint i;

    for (i = 0; mbim_ready_info_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_ready_info_flag_values[i].value)
            return mbim_ready_info_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_READY_INFO_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_READY_INFO_FLAG_IS_FLAGS__
gchar *
mbim_ready_info_flag_build_string_from_mask (MbimReadyInfoFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ready_info_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ready_info_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ready_info_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ready_info_flag_values[i].value) {
            guint c;
            gulong number = mbim_ready_info_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ready_info_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_READY_INFO_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_radio_switch_state_values[] = {
    { MBIM_RADIO_SWITCH_STATE_OFF, "MBIM_RADIO_SWITCH_STATE_OFF", "off" },
    { MBIM_RADIO_SWITCH_STATE_ON, "MBIM_RADIO_SWITCH_STATE_ON", "on" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_radio_switch_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimRadioSwitchState"),
                                      mbim_radio_switch_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_RADIO_SWITCH_STATE_IS_ENUM__
const gchar *
mbim_radio_switch_state_get_string (MbimRadioSwitchState val)
{
    guint i;

    for (i = 0; mbim_radio_switch_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_radio_switch_state_values[i].value)
            return mbim_radio_switch_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_RADIO_SWITCH_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_RADIO_SWITCH_STATE_IS_FLAGS__
gchar *
mbim_radio_switch_state_build_string_from_mask (MbimRadioSwitchState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_radio_switch_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_radio_switch_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_radio_switch_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_radio_switch_state_values[i].value) {
            guint c;
            gulong number = mbim_radio_switch_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_radio_switch_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_RADIO_SWITCH_STATE_IS_FLAGS__ */
static const GEnumValue mbim_pin_type_values[] = {
    { MBIM_PIN_TYPE_UNKNOWN, "MBIM_PIN_TYPE_UNKNOWN", "unknown" },
    { MBIM_PIN_TYPE_CUSTOM, "MBIM_PIN_TYPE_CUSTOM", "custom" },
    { MBIM_PIN_TYPE_PIN1, "MBIM_PIN_TYPE_PIN1", "pin1" },
    { MBIM_PIN_TYPE_PIN2, "MBIM_PIN_TYPE_PIN2", "pin2" },
    { MBIM_PIN_TYPE_DEVICE_SIM_PIN, "MBIM_PIN_TYPE_DEVICE_SIM_PIN", "device-sim-pin" },
    { MBIM_PIN_TYPE_DEVICE_FIRST_SIM_PIN, "MBIM_PIN_TYPE_DEVICE_FIRST_SIM_PIN", "device-first-sim-pin" },
    { MBIM_PIN_TYPE_NETWORK_PIN, "MBIM_PIN_TYPE_NETWORK_PIN", "network-pin" },
    { MBIM_PIN_TYPE_NETWORK_SUBSET_PIN, "MBIM_PIN_TYPE_NETWORK_SUBSET_PIN", "network-subset-pin" },
    { MBIM_PIN_TYPE_SERVICE_PROVIDER_PIN, "MBIM_PIN_TYPE_SERVICE_PROVIDER_PIN", "service-provider-pin" },
    { MBIM_PIN_TYPE_CORPORATE_PIN, "MBIM_PIN_TYPE_CORPORATE_PIN", "corporate-pin" },
    { MBIM_PIN_TYPE_SUBSIDY_PIN, "MBIM_PIN_TYPE_SUBSIDY_PIN", "subsidy-pin" },
    { MBIM_PIN_TYPE_PUK1, "MBIM_PIN_TYPE_PUK1", "puk1" },
    { MBIM_PIN_TYPE_PUK2, "MBIM_PIN_TYPE_PUK2", "puk2" },
    { MBIM_PIN_TYPE_DEVICE_FIRST_SIM_PUK, "MBIM_PIN_TYPE_DEVICE_FIRST_SIM_PUK", "device-first-sim-puk" },
    { MBIM_PIN_TYPE_NETWORK_PUK, "MBIM_PIN_TYPE_NETWORK_PUK", "network-puk" },
    { MBIM_PIN_TYPE_NETWORK_SUBSET_PUK, "MBIM_PIN_TYPE_NETWORK_SUBSET_PUK", "network-subset-puk" },
    { MBIM_PIN_TYPE_SERVICE_PROVIDER_PUK, "MBIM_PIN_TYPE_SERVICE_PROVIDER_PUK", "service-provider-puk" },
    { MBIM_PIN_TYPE_CORPORATE_PUK, "MBIM_PIN_TYPE_CORPORATE_PUK", "corporate-puk" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pin_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPinType"),
                                      mbim_pin_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PIN_TYPE_IS_ENUM__
const gchar *
mbim_pin_type_get_string (MbimPinType val)
{
    guint i;

    for (i = 0; mbim_pin_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_pin_type_values[i].value)
            return mbim_pin_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PIN_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PIN_TYPE_IS_FLAGS__
gchar *
mbim_pin_type_build_string_from_mask (MbimPinType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pin_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pin_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pin_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pin_type_values[i].value) {
            guint c;
            gulong number = mbim_pin_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pin_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PIN_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_pin_state_values[] = {
    { MBIM_PIN_STATE_UNLOCKED, "MBIM_PIN_STATE_UNLOCKED", "unlocked" },
    { MBIM_PIN_STATE_LOCKED, "MBIM_PIN_STATE_LOCKED", "locked" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pin_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPinState"),
                                      mbim_pin_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PIN_STATE_IS_ENUM__
const gchar *
mbim_pin_state_get_string (MbimPinState val)
{
    guint i;

    for (i = 0; mbim_pin_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_pin_state_values[i].value)
            return mbim_pin_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PIN_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PIN_STATE_IS_FLAGS__
gchar *
mbim_pin_state_build_string_from_mask (MbimPinState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pin_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pin_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pin_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pin_state_values[i].value) {
            guint c;
            gulong number = mbim_pin_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pin_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PIN_STATE_IS_FLAGS__ */
static const GEnumValue mbim_pin_operation_values[] = {
    { MBIM_PIN_OPERATION_ENTER, "MBIM_PIN_OPERATION_ENTER", "enter" },
    { MBIM_PIN_OPERATION_ENABLE, "MBIM_PIN_OPERATION_ENABLE", "enable" },
    { MBIM_PIN_OPERATION_DISABLE, "MBIM_PIN_OPERATION_DISABLE", "disable" },
    { MBIM_PIN_OPERATION_CHANGE, "MBIM_PIN_OPERATION_CHANGE", "change" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pin_operation_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPinOperation"),
                                      mbim_pin_operation_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PIN_OPERATION_IS_ENUM__
const gchar *
mbim_pin_operation_get_string (MbimPinOperation val)
{
    guint i;

    for (i = 0; mbim_pin_operation_values[i].value_nick; i++) {
        if ((gint)val == mbim_pin_operation_values[i].value)
            return mbim_pin_operation_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PIN_OPERATION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PIN_OPERATION_IS_FLAGS__
gchar *
mbim_pin_operation_build_string_from_mask (MbimPinOperation mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pin_operation_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pin_operation_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pin_operation_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pin_operation_values[i].value) {
            guint c;
            gulong number = mbim_pin_operation_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pin_operation_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PIN_OPERATION_IS_FLAGS__ */
static const GEnumValue mbim_pin_mode_values[] = {
    { MBIM_PIN_MODE_NOT_SUPPORTED, "MBIM_PIN_MODE_NOT_SUPPORTED", "not-supported" },
    { MBIM_PIN_MODE_ENABLED, "MBIM_PIN_MODE_ENABLED", "enabled" },
    { MBIM_PIN_MODE_DISABLED, "MBIM_PIN_MODE_DISABLED", "disabled" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pin_mode_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPinMode"),
                                      mbim_pin_mode_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PIN_MODE_IS_ENUM__
const gchar *
mbim_pin_mode_get_string (MbimPinMode val)
{
    guint i;

    for (i = 0; mbim_pin_mode_values[i].value_nick; i++) {
        if ((gint)val == mbim_pin_mode_values[i].value)
            return mbim_pin_mode_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PIN_MODE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PIN_MODE_IS_FLAGS__
gchar *
mbim_pin_mode_build_string_from_mask (MbimPinMode mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pin_mode_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pin_mode_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pin_mode_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pin_mode_values[i].value) {
            guint c;
            gulong number = mbim_pin_mode_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pin_mode_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PIN_MODE_IS_FLAGS__ */
static const GEnumValue mbim_pin_format_values[] = {
    { MBIM_PIN_FORMAT_UNKNOWN, "MBIM_PIN_FORMAT_UNKNOWN", "unknown" },
    { MBIM_PIN_FORMAT_NUMERIC, "MBIM_PIN_FORMAT_NUMERIC", "numeric" },
    { MBIM_PIN_FORMAT_ALPHANUMERIC, "MBIM_PIN_FORMAT_ALPHANUMERIC", "alphanumeric" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pin_format_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPinFormat"),
                                      mbim_pin_format_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PIN_FORMAT_IS_ENUM__
const gchar *
mbim_pin_format_get_string (MbimPinFormat val)
{
    guint i;

    for (i = 0; mbim_pin_format_values[i].value_nick; i++) {
        if ((gint)val == mbim_pin_format_values[i].value)
            return mbim_pin_format_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PIN_FORMAT_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PIN_FORMAT_IS_FLAGS__
gchar *
mbim_pin_format_build_string_from_mask (MbimPinFormat mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pin_format_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pin_format_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pin_format_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pin_format_values[i].value) {
            guint c;
            gulong number = mbim_pin_format_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pin_format_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PIN_FORMAT_IS_FLAGS__ */
static const GFlagsValue mbim_provider_state_values[] = {
    { MBIM_PROVIDER_STATE_UNKNOWN, "MBIM_PROVIDER_STATE_UNKNOWN", "unknown" },
    { MBIM_PROVIDER_STATE_HOME, "MBIM_PROVIDER_STATE_HOME", "home" },
    { MBIM_PROVIDER_STATE_FORBIDDEN, "MBIM_PROVIDER_STATE_FORBIDDEN", "forbidden" },
    { MBIM_PROVIDER_STATE_PREFERRED, "MBIM_PROVIDER_STATE_PREFERRED", "preferred" },
    { MBIM_PROVIDER_STATE_VISIBLE, "MBIM_PROVIDER_STATE_VISIBLE", "visible" },
    { MBIM_PROVIDER_STATE_REGISTERED, "MBIM_PROVIDER_STATE_REGISTERED", "registered" },
    { MBIM_PROVIDER_STATE_PREFERRED_MULTICARRIER, "MBIM_PROVIDER_STATE_PREFERRED_MULTICARRIER", "preferred-multicarrier" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_provider_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimProviderState"),
                                      mbim_provider_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PROVIDER_STATE_IS_ENUM__
const gchar *
mbim_provider_state_get_string (MbimProviderState val)
{
    guint i;

    for (i = 0; mbim_provider_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_provider_state_values[i].value)
            return mbim_provider_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PROVIDER_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PROVIDER_STATE_IS_FLAGS__
gchar *
mbim_provider_state_build_string_from_mask (MbimProviderState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_provider_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_provider_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_provider_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_provider_state_values[i].value) {
            guint c;
            gulong number = mbim_provider_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_provider_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PROVIDER_STATE_IS_FLAGS__ */
static const GEnumValue mbim_visible_providers_action_values[] = {
    { MBIM_VISIBLE_PROVIDERS_ACTION_FULL_SCAN, "MBIM_VISIBLE_PROVIDERS_ACTION_FULL_SCAN", "full-scan" },
    { MBIM_VISIBLE_PROVIDERS_ACTION_RESTRICTED_SCAN, "MBIM_VISIBLE_PROVIDERS_ACTION_RESTRICTED_SCAN", "restricted-scan" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_visible_providers_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimVisibleProvidersAction"),
                                      mbim_visible_providers_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_VISIBLE_PROVIDERS_ACTION_IS_ENUM__
const gchar *
mbim_visible_providers_action_get_string (MbimVisibleProvidersAction val)
{
    guint i;

    for (i = 0; mbim_visible_providers_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_visible_providers_action_values[i].value)
            return mbim_visible_providers_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_VISIBLE_PROVIDERS_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_VISIBLE_PROVIDERS_ACTION_IS_FLAGS__
gchar *
mbim_visible_providers_action_build_string_from_mask (MbimVisibleProvidersAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_visible_providers_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_visible_providers_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_visible_providers_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_visible_providers_action_values[i].value) {
            guint c;
            gulong number = mbim_visible_providers_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_visible_providers_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_VISIBLE_PROVIDERS_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_nw_error_values[] = {
    { MBIM_NW_ERROR_UNKNOWN, "MBIM_NW_ERROR_UNKNOWN", "unknown" },
    { MBIM_NW_ERROR_IMSI_UNKNOWN_IN_HLR, "MBIM_NW_ERROR_IMSI_UNKNOWN_IN_HLR", "imsi-unknown-in-hlr" },
    { MBIM_NW_ERROR_ILLEGAL_MS, "MBIM_NW_ERROR_ILLEGAL_MS", "illegal-ms" },
    { MBIM_NW_ERROR_IMSI_UNKNOWN_IN_VLR, "MBIM_NW_ERROR_IMSI_UNKNOWN_IN_VLR", "imsi-unknown-in-vlr" },
    { MBIM_NW_ERROR_IMEI_NOT_ACCEPTED, "MBIM_NW_ERROR_IMEI_NOT_ACCEPTED", "imei-not-accepted" },
    { MBIM_NW_ERROR_ILLEGAL_ME, "MBIM_NW_ERROR_ILLEGAL_ME", "illegal-me" },
    { MBIM_NW_ERROR_GPRS_NOT_ALLOWED, "MBIM_NW_ERROR_GPRS_NOT_ALLOWED", "gprs-not-allowed" },
    { MBIM_NW_ERROR_GPRS_AND_NON_GPRS_NOT_ALLOWED, "MBIM_NW_ERROR_GPRS_AND_NON_GPRS_NOT_ALLOWED", "gprs-and-non-gprs-not-allowed" },
    { MBIM_NW_ERROR_MS_IDENTITY_NOT_DERIVED_BY_NETWORK, "MBIM_NW_ERROR_MS_IDENTITY_NOT_DERIVED_BY_NETWORK", "ms-identity-not-derived-by-network" },
    { MBIM_NW_ERROR_IMPLICITLY_DETACHED, "MBIM_NW_ERROR_IMPLICITLY_DETACHED", "implicitly-detached" },
    { MBIM_NW_ERROR_PLMN_NOT_ALLOWED, "MBIM_NW_ERROR_PLMN_NOT_ALLOWED", "plmn-not-allowed" },
    { MBIM_NW_ERROR_LOCATION_AREA_NOT_ALLOWED, "MBIM_NW_ERROR_LOCATION_AREA_NOT_ALLOWED", "location-area-not-allowed" },
    { MBIM_NW_ERROR_ROAMING_NOT_ALLOWED_IN_LOCATION_AREA, "MBIM_NW_ERROR_ROAMING_NOT_ALLOWED_IN_LOCATION_AREA", "roaming-not-allowed-in-location-area" },
    { MBIM_NW_ERROR_GPRS_NOT_ALLOWED_IN_PLMN, "MBIM_NW_ERROR_GPRS_NOT_ALLOWED_IN_PLMN", "gprs-not-allowed-in-plmn" },
    { MBIM_NW_ERROR_NO_CELLS_IN_LOCATION_AREA, "MBIM_NW_ERROR_NO_CELLS_IN_LOCATION_AREA", "no-cells-in-location-area" },
    { MBIM_NW_ERROR_MSC_TEMPORARILY_NOT_REACHABLE, "MBIM_NW_ERROR_MSC_TEMPORARILY_NOT_REACHABLE", "msc-temporarily-not-reachable" },
    { MBIM_NW_ERROR_NETWORK_FAILURE, "MBIM_NW_ERROR_NETWORK_FAILURE", "network-failure" },
    { MBIM_NW_ERROR_MAC_FAILURE, "MBIM_NW_ERROR_MAC_FAILURE", "mac-failure" },
    { MBIM_NW_ERROR_SYNCH_FAILURE, "MBIM_NW_ERROR_SYNCH_FAILURE", "synch-failure" },
    { MBIM_NW_ERROR_CONGESTION, "MBIM_NW_ERROR_CONGESTION", "congestion" },
    { MBIM_NW_ERROR_GSM_AUTHENTICATION_UNACCEPTABLE, "MBIM_NW_ERROR_GSM_AUTHENTICATION_UNACCEPTABLE", "gsm-authentication-unacceptable" },
    { MBIM_NW_ERROR_NOT_AUTHORIZED_FOR_CSG, "MBIM_NW_ERROR_NOT_AUTHORIZED_FOR_CSG", "not-authorized-for-csg" },
    { MBIM_NW_ERROR_INSUFFICIENT_RESOURCES, "MBIM_NW_ERROR_INSUFFICIENT_RESOURCES", "insufficient-resources" },
    { MBIM_NW_ERROR_MISSING_OR_UNKNOWN_APN, "MBIM_NW_ERROR_MISSING_OR_UNKNOWN_APN", "missing-or-unknown-apn" },
    { MBIM_NW_ERROR_UNKNOWN_PDP_ADDRESS_OR_TYPE, "MBIM_NW_ERROR_UNKNOWN_PDP_ADDRESS_OR_TYPE", "unknown-pdp-address-or-type" },
    { MBIM_NW_ERROR_USER_AUTHENTICATION_FAILED, "MBIM_NW_ERROR_USER_AUTHENTICATION_FAILED", "user-authentication-failed" },
    { MBIM_NW_ERROR_ACTIVATION_REJECTED_BY_GGSN_OR_GW, "MBIM_NW_ERROR_ACTIVATION_REJECTED_BY_GGSN_OR_GW", "activation-rejected-by-ggsn-or-gw" },
    { MBIM_NW_ERROR_ACTIVATION_REJECTED_UNSPECIFIED, "MBIM_NW_ERROR_ACTIVATION_REJECTED_UNSPECIFIED", "activation-rejected-unspecified" },
    { MBIM_NW_ERROR_SERVICE_OPTION_NOT_SUPPORTED, "MBIM_NW_ERROR_SERVICE_OPTION_NOT_SUPPORTED", "service-option-not-supported" },
    { MBIM_NW_ERROR_REQUESTED_SERVICE_OPTION_NOT_SUBSCRIBED, "MBIM_NW_ERROR_REQUESTED_SERVICE_OPTION_NOT_SUBSCRIBED", "requested-service-option-not-subscribed" },
    { MBIM_NW_ERROR_SERVICE_OPTION_TEMPORARILY_OUT_OF_ORDER, "MBIM_NW_ERROR_SERVICE_OPTION_TEMPORARILY_OUT_OF_ORDER", "service-option-temporarily-out-of-order" },
    { MBIM_NW_ERROR_NO_PDP_CONTEXT_ACTIVATED, "MBIM_NW_ERROR_NO_PDP_CONTEXT_ACTIVATED", "no-pdp-context-activated" },
    { MBIM_NW_ERROR_PDP_TYPE_IPV4_ONLY_ALLOWED, "MBIM_NW_ERROR_PDP_TYPE_IPV4_ONLY_ALLOWED", "pdp-type-ipv4-only-allowed" },
    { MBIM_NW_ERROR_PDP_TYPE_IPV6_ONLY_ALLOWED, "MBIM_NW_ERROR_PDP_TYPE_IPV6_ONLY_ALLOWED", "pdp-type-ipv6-only-allowed" },
    { MBIM_NW_ERROR_MAXIMUM_NUMBER_OF_PDP_CONTEXTS_REACHED, "MBIM_NW_ERROR_MAXIMUM_NUMBER_OF_PDP_CONTEXTS_REACHED", "maximum-number-of-pdp-contexts-reached" },
    { MBIM_NW_ERROR_REQUESTED_APN_NOT_SUPPORTED_IN_CURRENT_RAT_AND_PLMN, "MBIM_NW_ERROR_REQUESTED_APN_NOT_SUPPORTED_IN_CURRENT_RAT_AND_PLMN", "requested-apn-not-supported-in-current-rat-and-plmn" },
    { MBIM_NW_ERROR_SEMANTICALLY_INCORRECT_MESSAGE, "MBIM_NW_ERROR_SEMANTICALLY_INCORRECT_MESSAGE", "semantically-incorrect-message" },
    { MBIM_NW_ERROR_INVALID_MANDATORY_INFORMATION, "MBIM_NW_ERROR_INVALID_MANDATORY_INFORMATION", "invalid-mandatory-information" },
    { MBIM_NW_ERROR_MESSAGE_TYPE_NON_EXISTENT_OR_NOT_IMPLEMENTED, "MBIM_NW_ERROR_MESSAGE_TYPE_NON_EXISTENT_OR_NOT_IMPLEMENTED", "message-type-non-existent-or-not-implemented" },
    { MBIM_NW_ERROR_MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE, "MBIM_NW_ERROR_MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE", "message-type-not-compatible-with-protocol-state" },
    { MBIM_NW_ERROR_INFORMATION_ELEMENT_NON_EXISTENT_OR_NOT_IMPLEMENTED, "MBIM_NW_ERROR_INFORMATION_ELEMENT_NON_EXISTENT_OR_NOT_IMPLEMENTED", "information-element-non-existent-or-not-implemented" },
    { MBIM_NW_ERROR_CONDITIONAL_IE_ERROR, "MBIM_NW_ERROR_CONDITIONAL_IE_ERROR", "conditional-ie-error" },
    { MBIM_NW_ERROR_MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE, "MBIM_NW_ERROR_MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE", "message-not-compatible-with-protocol-state" },
    { MBIM_NW_ERROR_PROTOCOL_ERROR_UNSPECIFIED, "MBIM_NW_ERROR_PROTOCOL_ERROR_UNSPECIFIED", "protocol-error-unspecified" },
    { MBIM_NW_ERROR_APN_RESTRICTION_VALUE_INCOMPATIBLE_WITH_ACTIVE_PDP_CONTEXT, "MBIM_NW_ERROR_APN_RESTRICTION_VALUE_INCOMPATIBLE_WITH_ACTIVE_PDP_CONTEXT", "apn-restriction-value-incompatible-with-active-pdp-context" },
    { MBIM_NW_ERROR_MULTIPLE_ACCESSES_TO_A_PDN_CONNECTION_NOT_ALLOWED, "MBIM_NW_ERROR_MULTIPLE_ACCESSES_TO_A_PDN_CONNECTION_NOT_ALLOWED", "multiple-accesses-to-a-pdn-connection-not-allowed" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_nw_error_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimNwError"),
                                      mbim_nw_error_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_NW_ERROR_IS_ENUM__
const gchar *
mbim_nw_error_get_string (MbimNwError val)
{
    guint i;

    for (i = 0; mbim_nw_error_values[i].value_nick; i++) {
        if ((gint)val == mbim_nw_error_values[i].value)
            return mbim_nw_error_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_NW_ERROR_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_NW_ERROR_IS_FLAGS__
gchar *
mbim_nw_error_build_string_from_mask (MbimNwError mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_nw_error_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_nw_error_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_nw_error_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_nw_error_values[i].value) {
            guint c;
            gulong number = mbim_nw_error_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_nw_error_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_NW_ERROR_IS_FLAGS__ */
static const GEnumValue mbim_register_action_values[] = {
    { MBIM_REGISTER_ACTION_AUTOMATIC, "MBIM_REGISTER_ACTION_AUTOMATIC", "automatic" },
    { MBIM_REGISTER_ACTION_MANUAL, "MBIM_REGISTER_ACTION_MANUAL", "manual" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_register_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimRegisterAction"),
                                      mbim_register_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_REGISTER_ACTION_IS_ENUM__
const gchar *
mbim_register_action_get_string (MbimRegisterAction val)
{
    guint i;

    for (i = 0; mbim_register_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_register_action_values[i].value)
            return mbim_register_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_REGISTER_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_REGISTER_ACTION_IS_FLAGS__
gchar *
mbim_register_action_build_string_from_mask (MbimRegisterAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_register_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_register_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_register_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_register_action_values[i].value) {
            guint c;
            gulong number = mbim_register_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_register_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_REGISTER_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_register_state_values[] = {
    { MBIM_REGISTER_STATE_UNKNOWN, "MBIM_REGISTER_STATE_UNKNOWN", "unknown" },
    { MBIM_REGISTER_STATE_DEREGISTERED, "MBIM_REGISTER_STATE_DEREGISTERED", "deregistered" },
    { MBIM_REGISTER_STATE_SEARCHING, "MBIM_REGISTER_STATE_SEARCHING", "searching" },
    { MBIM_REGISTER_STATE_HOME, "MBIM_REGISTER_STATE_HOME", "home" },
    { MBIM_REGISTER_STATE_ROAMING, "MBIM_REGISTER_STATE_ROAMING", "roaming" },
    { MBIM_REGISTER_STATE_PARTNER, "MBIM_REGISTER_STATE_PARTNER", "partner" },
    { MBIM_REGISTER_STATE_DENIED, "MBIM_REGISTER_STATE_DENIED", "denied" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_register_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimRegisterState"),
                                      mbim_register_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_REGISTER_STATE_IS_ENUM__
const gchar *
mbim_register_state_get_string (MbimRegisterState val)
{
    guint i;

    for (i = 0; mbim_register_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_register_state_values[i].value)
            return mbim_register_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_REGISTER_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_REGISTER_STATE_IS_FLAGS__
gchar *
mbim_register_state_build_string_from_mask (MbimRegisterState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_register_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_register_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_register_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_register_state_values[i].value) {
            guint c;
            gulong number = mbim_register_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_register_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_REGISTER_STATE_IS_FLAGS__ */
static const GEnumValue mbim_register_mode_values[] = {
    { MBIM_REGISTER_MODE_UNKNOWN, "MBIM_REGISTER_MODE_UNKNOWN", "unknown" },
    { MBIM_REGISTER_MODE_AUTOMATIC, "MBIM_REGISTER_MODE_AUTOMATIC", "automatic" },
    { MBIM_REGISTER_MODE_MANUAL, "MBIM_REGISTER_MODE_MANUAL", "manual" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_register_mode_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimRegisterMode"),
                                      mbim_register_mode_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_REGISTER_MODE_IS_ENUM__
const gchar *
mbim_register_mode_get_string (MbimRegisterMode val)
{
    guint i;

    for (i = 0; mbim_register_mode_values[i].value_nick; i++) {
        if ((gint)val == mbim_register_mode_values[i].value)
            return mbim_register_mode_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_REGISTER_MODE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_REGISTER_MODE_IS_FLAGS__
gchar *
mbim_register_mode_build_string_from_mask (MbimRegisterMode mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_register_mode_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_register_mode_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_register_mode_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_register_mode_values[i].value) {
            guint c;
            gulong number = mbim_register_mode_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_register_mode_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_REGISTER_MODE_IS_FLAGS__ */
static const GFlagsValue mbim_registration_flag_values[] = {
    { MBIM_REGISTRATION_FLAG_NONE, "MBIM_REGISTRATION_FLAG_NONE", "none" },
    { MBIM_REGISTRATION_FLAG_MANUAL_SELECTION_NOT_AVAILABLE, "MBIM_REGISTRATION_FLAG_MANUAL_SELECTION_NOT_AVAILABLE", "manual-selection-not-available" },
    { MBIM_REGISTRATION_FLAG_PACKET_SERVICE_AUTOMATIC_ATTACH, "MBIM_REGISTRATION_FLAG_PACKET_SERVICE_AUTOMATIC_ATTACH", "packet-service-automatic-attach" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_registration_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimRegistrationFlag"),
                                      mbim_registration_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_REGISTRATION_FLAG_IS_ENUM__
const gchar *
mbim_registration_flag_get_string (MbimRegistrationFlag val)
{
    guint i;

    for (i = 0; mbim_registration_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_registration_flag_values[i].value)
            return mbim_registration_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_REGISTRATION_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_REGISTRATION_FLAG_IS_FLAGS__
gchar *
mbim_registration_flag_build_string_from_mask (MbimRegistrationFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_registration_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_registration_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_registration_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_registration_flag_values[i].value) {
            guint c;
            gulong number = mbim_registration_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_registration_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_REGISTRATION_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_packet_service_action_values[] = {
    { MBIM_PACKET_SERVICE_ACTION_ATTACH, "MBIM_PACKET_SERVICE_ACTION_ATTACH", "attach" },
    { MBIM_PACKET_SERVICE_ACTION_DETACH, "MBIM_PACKET_SERVICE_ACTION_DETACH", "detach" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_packet_service_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPacketServiceAction"),
                                      mbim_packet_service_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PACKET_SERVICE_ACTION_IS_ENUM__
const gchar *
mbim_packet_service_action_get_string (MbimPacketServiceAction val)
{
    guint i;

    for (i = 0; mbim_packet_service_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_packet_service_action_values[i].value)
            return mbim_packet_service_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PACKET_SERVICE_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PACKET_SERVICE_ACTION_IS_FLAGS__
gchar *
mbim_packet_service_action_build_string_from_mask (MbimPacketServiceAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_packet_service_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_packet_service_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_packet_service_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_packet_service_action_values[i].value) {
            guint c;
            gulong number = mbim_packet_service_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_packet_service_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PACKET_SERVICE_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_packet_service_state_values[] = {
    { MBIM_PACKET_SERVICE_STATE_UNKNOWN, "MBIM_PACKET_SERVICE_STATE_UNKNOWN", "unknown" },
    { MBIM_PACKET_SERVICE_STATE_ATTACHING, "MBIM_PACKET_SERVICE_STATE_ATTACHING", "attaching" },
    { MBIM_PACKET_SERVICE_STATE_ATTACHED, "MBIM_PACKET_SERVICE_STATE_ATTACHED", "attached" },
    { MBIM_PACKET_SERVICE_STATE_DETACHING, "MBIM_PACKET_SERVICE_STATE_DETACHING", "detaching" },
    { MBIM_PACKET_SERVICE_STATE_DETACHED, "MBIM_PACKET_SERVICE_STATE_DETACHED", "detached" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_packet_service_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPacketServiceState"),
                                      mbim_packet_service_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PACKET_SERVICE_STATE_IS_ENUM__
const gchar *
mbim_packet_service_state_get_string (MbimPacketServiceState val)
{
    guint i;

    for (i = 0; mbim_packet_service_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_packet_service_state_values[i].value)
            return mbim_packet_service_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PACKET_SERVICE_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PACKET_SERVICE_STATE_IS_FLAGS__
gchar *
mbim_packet_service_state_build_string_from_mask (MbimPacketServiceState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_packet_service_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_packet_service_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_packet_service_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_packet_service_state_values[i].value) {
            guint c;
            gulong number = mbim_packet_service_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_packet_service_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PACKET_SERVICE_STATE_IS_FLAGS__ */
static const GEnumValue mbim_activation_command_values[] = {
    { MBIM_ACTIVATION_COMMAND_DEACTIVATE, "MBIM_ACTIVATION_COMMAND_DEACTIVATE", "deactivate" },
    { MBIM_ACTIVATION_COMMAND_ACTIVATE, "MBIM_ACTIVATION_COMMAND_ACTIVATE", "activate" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_activation_command_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimActivationCommand"),
                                      mbim_activation_command_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_ACTIVATION_COMMAND_IS_ENUM__
const gchar *
mbim_activation_command_get_string (MbimActivationCommand val)
{
    guint i;

    for (i = 0; mbim_activation_command_values[i].value_nick; i++) {
        if ((gint)val == mbim_activation_command_values[i].value)
            return mbim_activation_command_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_ACTIVATION_COMMAND_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_ACTIVATION_COMMAND_IS_FLAGS__
gchar *
mbim_activation_command_build_string_from_mask (MbimActivationCommand mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_activation_command_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_activation_command_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_activation_command_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_activation_command_values[i].value) {
            guint c;
            gulong number = mbim_activation_command_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_activation_command_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_ACTIVATION_COMMAND_IS_FLAGS__ */
static const GEnumValue mbim_compression_values[] = {
    { MBIM_COMPRESSION_NONE, "MBIM_COMPRESSION_NONE", "none" },
    { MBIM_COMPRESSION_ENABLE, "MBIM_COMPRESSION_ENABLE", "enable" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_compression_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimCompression"),
                                      mbim_compression_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_COMPRESSION_IS_ENUM__
const gchar *
mbim_compression_get_string (MbimCompression val)
{
    guint i;

    for (i = 0; mbim_compression_values[i].value_nick; i++) {
        if ((gint)val == mbim_compression_values[i].value)
            return mbim_compression_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_COMPRESSION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_COMPRESSION_IS_FLAGS__
gchar *
mbim_compression_build_string_from_mask (MbimCompression mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_compression_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_compression_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_compression_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_compression_values[i].value) {
            guint c;
            gulong number = mbim_compression_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_compression_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_COMPRESSION_IS_FLAGS__ */
static const GEnumValue mbim_auth_protocol_values[] = {
    { MBIM_AUTH_PROTOCOL_NONE, "MBIM_AUTH_PROTOCOL_NONE", "none" },
    { MBIM_AUTH_PROTOCOL_PAP, "MBIM_AUTH_PROTOCOL_PAP", "pap" },
    { MBIM_AUTH_PROTOCOL_CHAP, "MBIM_AUTH_PROTOCOL_CHAP", "chap" },
    { MBIM_AUTH_PROTOCOL_MSCHAPV2, "MBIM_AUTH_PROTOCOL_MSCHAPV2", "mschapv2" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_auth_protocol_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimAuthProtocol"),
                                      mbim_auth_protocol_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_AUTH_PROTOCOL_IS_ENUM__
const gchar *
mbim_auth_protocol_get_string (MbimAuthProtocol val)
{
    guint i;

    for (i = 0; mbim_auth_protocol_values[i].value_nick; i++) {
        if ((gint)val == mbim_auth_protocol_values[i].value)
            return mbim_auth_protocol_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_AUTH_PROTOCOL_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_AUTH_PROTOCOL_IS_FLAGS__
gchar *
mbim_auth_protocol_build_string_from_mask (MbimAuthProtocol mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_auth_protocol_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_auth_protocol_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_auth_protocol_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_auth_protocol_values[i].value) {
            guint c;
            gulong number = mbim_auth_protocol_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_auth_protocol_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_AUTH_PROTOCOL_IS_FLAGS__ */
static const GEnumValue mbim_context_ip_type_values[] = {
    { MBIM_CONTEXT_IP_TYPE_DEFAULT, "MBIM_CONTEXT_IP_TYPE_DEFAULT", "default" },
    { MBIM_CONTEXT_IP_TYPE_IPV4, "MBIM_CONTEXT_IP_TYPE_IPV4", "ipv4" },
    { MBIM_CONTEXT_IP_TYPE_IPV6, "MBIM_CONTEXT_IP_TYPE_IPV6", "ipv6" },
    { MBIM_CONTEXT_IP_TYPE_IPV4V6, "MBIM_CONTEXT_IP_TYPE_IPV4V6", "ipv4v6" },
    { MBIM_CONTEXT_IP_TYPE_IPV4_AND_IPV6, "MBIM_CONTEXT_IP_TYPE_IPV4_AND_IPV6", "ipv4-and-ipv6" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_context_ip_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimContextIpType"),
                                      mbim_context_ip_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CONTEXT_IP_TYPE_IS_ENUM__
const gchar *
mbim_context_ip_type_get_string (MbimContextIpType val)
{
    guint i;

    for (i = 0; mbim_context_ip_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_context_ip_type_values[i].value)
            return mbim_context_ip_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CONTEXT_IP_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CONTEXT_IP_TYPE_IS_FLAGS__
gchar *
mbim_context_ip_type_build_string_from_mask (MbimContextIpType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_context_ip_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_context_ip_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_context_ip_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_context_ip_type_values[i].value) {
            guint c;
            gulong number = mbim_context_ip_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_context_ip_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CONTEXT_IP_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_activation_state_values[] = {
    { MBIM_ACTIVATION_STATE_UNKNOWN, "MBIM_ACTIVATION_STATE_UNKNOWN", "unknown" },
    { MBIM_ACTIVATION_STATE_ACTIVATED, "MBIM_ACTIVATION_STATE_ACTIVATED", "activated" },
    { MBIM_ACTIVATION_STATE_ACTIVATING, "MBIM_ACTIVATION_STATE_ACTIVATING", "activating" },
    { MBIM_ACTIVATION_STATE_DEACTIVATED, "MBIM_ACTIVATION_STATE_DEACTIVATED", "deactivated" },
    { MBIM_ACTIVATION_STATE_DEACTIVATING, "MBIM_ACTIVATION_STATE_DEACTIVATING", "deactivating" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_activation_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimActivationState"),
                                      mbim_activation_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_ACTIVATION_STATE_IS_ENUM__
const gchar *
mbim_activation_state_get_string (MbimActivationState val)
{
    guint i;

    for (i = 0; mbim_activation_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_activation_state_values[i].value)
            return mbim_activation_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_ACTIVATION_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_ACTIVATION_STATE_IS_FLAGS__
gchar *
mbim_activation_state_build_string_from_mask (MbimActivationState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_activation_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_activation_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_activation_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_activation_state_values[i].value) {
            guint c;
            gulong number = mbim_activation_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_activation_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_ACTIVATION_STATE_IS_FLAGS__ */
static const GEnumValue mbim_voice_call_state_values[] = {
    { MBIM_VOICE_CALL_STATE_NONE, "MBIM_VOICE_CALL_STATE_NONE", "none" },
    { MBIM_VOICE_CALL_STATE_IN_PROGRESS, "MBIM_VOICE_CALL_STATE_IN_PROGRESS", "in-progress" },
    { MBIM_VOICE_CALL_STATE_HANG_UP, "MBIM_VOICE_CALL_STATE_HANG_UP", "hang-up" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_voice_call_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimVoiceCallState"),
                                      mbim_voice_call_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_VOICE_CALL_STATE_IS_ENUM__
const gchar *
mbim_voice_call_state_get_string (MbimVoiceCallState val)
{
    guint i;

    for (i = 0; mbim_voice_call_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_voice_call_state_values[i].value)
            return mbim_voice_call_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_VOICE_CALL_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_VOICE_CALL_STATE_IS_FLAGS__
gchar *
mbim_voice_call_state_build_string_from_mask (MbimVoiceCallState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_voice_call_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_voice_call_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_voice_call_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_voice_call_state_values[i].value) {
            guint c;
            gulong number = mbim_voice_call_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_voice_call_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_VOICE_CALL_STATE_IS_FLAGS__ */
static const GFlagsValue mbim_ip_configuration_available_flag_values[] = {
    { MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_NONE, "MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_NONE", "none" },
    { MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_ADDRESS, "MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_ADDRESS", "address" },
    { MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_GATEWAY, "MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_GATEWAY", "gateway" },
    { MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_DNS, "MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_DNS", "dns" },
    { MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_MTU, "MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_MTU", "mtu" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ip_configuration_available_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_flags_register_static (g_intern_static_string ("MbimIPConfigurationAvailableFlag"),
                                      mbim_ip_configuration_available_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_IS_ENUM__
const gchar *
mbim_ip_configuration_available_flag_get_string (MbimIPConfigurationAvailableFlag val)
{
    guint i;

    for (i = 0; mbim_ip_configuration_available_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_ip_configuration_available_flag_values[i].value)
            return mbim_ip_configuration_available_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_IS_FLAGS__
gchar *
mbim_ip_configuration_available_flag_build_string_from_mask (MbimIPConfigurationAvailableFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ip_configuration_available_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ip_configuration_available_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ip_configuration_available_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ip_configuration_available_flag_values[i].value) {
            guint c;
            gulong number = mbim_ip_configuration_available_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ip_configuration_available_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_IP_CONFIGURATION_AVAILABLE_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_sms_storage_state_values[] = {
    { MBIM_SMS_STORAGE_STATE_NOT_INITIALIZED, "MBIM_SMS_STORAGE_STATE_NOT_INITIALIZED", "not-initialized" },
    { MBIM_SMS_STORAGE_STATE_INITIALIZED, "MBIM_SMS_STORAGE_STATE_INITIALIZED", "initialized" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_storage_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsStorageState"),
                                      mbim_sms_storage_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_STORAGE_STATE_IS_ENUM__
const gchar *
mbim_sms_storage_state_get_string (MbimSmsStorageState val)
{
    guint i;

    for (i = 0; mbim_sms_storage_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_storage_state_values[i].value)
            return mbim_sms_storage_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_STORAGE_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_STORAGE_STATE_IS_FLAGS__
gchar *
mbim_sms_storage_state_build_string_from_mask (MbimSmsStorageState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_storage_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_storage_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_storage_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_storage_state_values[i].value) {
            guint c;
            gulong number = mbim_sms_storage_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_storage_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_STORAGE_STATE_IS_FLAGS__ */
static const GEnumValue mbim_sms_format_values[] = {
    { MBIM_SMS_FORMAT_PDU, "MBIM_SMS_FORMAT_PDU", "pdu" },
    { MBIM_SMS_FORMAT_CDMA, "MBIM_SMS_FORMAT_CDMA", "cdma" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_format_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsFormat"),
                                      mbim_sms_format_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_FORMAT_IS_ENUM__
const gchar *
mbim_sms_format_get_string (MbimSmsFormat val)
{
    guint i;

    for (i = 0; mbim_sms_format_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_format_values[i].value)
            return mbim_sms_format_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_FORMAT_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_FORMAT_IS_FLAGS__
gchar *
mbim_sms_format_build_string_from_mask (MbimSmsFormat mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_format_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_format_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_format_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_format_values[i].value) {
            guint c;
            gulong number = mbim_sms_format_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_format_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_FORMAT_IS_FLAGS__ */
static const GEnumValue mbim_sms_flag_values[] = {
    { MBIM_SMS_FLAG_ALL, "MBIM_SMS_FLAG_ALL", "all" },
    { MBIM_SMS_FLAG_INDEX, "MBIM_SMS_FLAG_INDEX", "index" },
    { MBIM_SMS_FLAG_NEW, "MBIM_SMS_FLAG_NEW", "new" },
    { MBIM_SMS_FLAG_OLD, "MBIM_SMS_FLAG_OLD", "old" },
    { MBIM_SMS_FLAG_SENT, "MBIM_SMS_FLAG_SENT", "sent" },
    { MBIM_SMS_FLAG_DRAFT, "MBIM_SMS_FLAG_DRAFT", "draft" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsFlag"),
                                      mbim_sms_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_FLAG_IS_ENUM__
const gchar *
mbim_sms_flag_get_string (MbimSmsFlag val)
{
    guint i;

    for (i = 0; mbim_sms_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_flag_values[i].value)
            return mbim_sms_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_FLAG_IS_FLAGS__
gchar *
mbim_sms_flag_build_string_from_mask (MbimSmsFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_flag_values[i].value) {
            guint c;
            gulong number = mbim_sms_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_sms_cdma_lang_values[] = {
    { MBIM_SMS_CDMA_LANG_UNKNOWN, "MBIM_SMS_CDMA_LANG_UNKNOWN", "unknown" },
    { MBIM_SMS_CDMA_LANG_ENGLISH, "MBIM_SMS_CDMA_LANG_ENGLISH", "english" },
    { MBIM_SMS_CDMA_LANG_FRENCH, "MBIM_SMS_CDMA_LANG_FRENCH", "french" },
    { MBIM_SMS_CDMA_LANG_SPANISH, "MBIM_SMS_CDMA_LANG_SPANISH", "spanish" },
    { MBIM_SMS_CDMA_LANG_JAPANESE, "MBIM_SMS_CDMA_LANG_JAPANESE", "japanese" },
    { MBIM_SMS_CDMA_LANG_KOREAN, "MBIM_SMS_CDMA_LANG_KOREAN", "korean" },
    { MBIM_SMS_CDMA_LANG_CHINESE, "MBIM_SMS_CDMA_LANG_CHINESE", "chinese" },
    { MBIM_SMS_CDMA_LANG_HEBREW, "MBIM_SMS_CDMA_LANG_HEBREW", "hebrew" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_cdma_lang_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsCdmaLang"),
                                      mbim_sms_cdma_lang_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_CDMA_LANG_IS_ENUM__
const gchar *
mbim_sms_cdma_lang_get_string (MbimSmsCdmaLang val)
{
    guint i;

    for (i = 0; mbim_sms_cdma_lang_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_cdma_lang_values[i].value)
            return mbim_sms_cdma_lang_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_CDMA_LANG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_CDMA_LANG_IS_FLAGS__
gchar *
mbim_sms_cdma_lang_build_string_from_mask (MbimSmsCdmaLang mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_cdma_lang_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_cdma_lang_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_cdma_lang_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_cdma_lang_values[i].value) {
            guint c;
            gulong number = mbim_sms_cdma_lang_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_cdma_lang_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_CDMA_LANG_IS_FLAGS__ */
static const GEnumValue mbim_sms_cdma_encoding_values[] = {
    { MBIM_SMS_CDMA_ENCODING_OCTET, "MBIM_SMS_CDMA_ENCODING_OCTET", "octet" },
    { MBIM_SMS_CDMA_ENCODING_EPM, "MBIM_SMS_CDMA_ENCODING_EPM", "epm" },
    { MBIM_SMS_CDMA_ENCODING_7BIT_ASCII, "MBIM_SMS_CDMA_ENCODING_7BIT_ASCII", "7bit-ascii" },
    { MBIM_SMS_CDMA_ENCODING_LA5, "MBIM_SMS_CDMA_ENCODING_LA5", "la5" },
    { MBIM_SMS_CDMA_ENCODING_UNICODE, "MBIM_SMS_CDMA_ENCODING_UNICODE", "unicode" },
    { MBIM_SMS_CDMA_ENCODING_SHIFT_JIS, "MBIM_SMS_CDMA_ENCODING_SHIFT_JIS", "shift-jis" },
    { MBIM_SMS_CDMA_ENCODING_KOREAN, "MBIM_SMS_CDMA_ENCODING_KOREAN", "korean" },
    { MBIM_SMS_CDMA_ENCODING_LATIN_HEBREW, "MBIM_SMS_CDMA_ENCODING_LATIN_HEBREW", "latin-hebrew" },
    { MBIM_SMS_CDMA_ENCODING_LATIN, "MBIM_SMS_CDMA_ENCODING_LATIN", "latin" },
    { MBIM_SMS_CDMA_ENCODING_GSM_7BIT, "MBIM_SMS_CDMA_ENCODING_GSM_7BIT", "gsm-7bit" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_cdma_encoding_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsCdmaEncoding"),
                                      mbim_sms_cdma_encoding_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_CDMA_ENCODING_IS_ENUM__
const gchar *
mbim_sms_cdma_encoding_get_string (MbimSmsCdmaEncoding val)
{
    guint i;

    for (i = 0; mbim_sms_cdma_encoding_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_cdma_encoding_values[i].value)
            return mbim_sms_cdma_encoding_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_CDMA_ENCODING_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_CDMA_ENCODING_IS_FLAGS__
gchar *
mbim_sms_cdma_encoding_build_string_from_mask (MbimSmsCdmaEncoding mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_cdma_encoding_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_cdma_encoding_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_cdma_encoding_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_cdma_encoding_values[i].value) {
            guint c;
            gulong number = mbim_sms_cdma_encoding_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_cdma_encoding_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_CDMA_ENCODING_IS_FLAGS__ */
static const GEnumValue mbim_sms_status_values[] = {
    { MBIM_SMS_STATUS_NEW, "MBIM_SMS_STATUS_NEW", "new" },
    { MBIM_SMS_STATUS_OLD, "MBIM_SMS_STATUS_OLD", "old" },
    { MBIM_SMS_STATUS_DRAFT, "MBIM_SMS_STATUS_DRAFT", "draft" },
    { MBIM_SMS_STATUS_SENT, "MBIM_SMS_STATUS_SENT", "sent" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_status_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsStatus"),
                                      mbim_sms_status_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_STATUS_IS_ENUM__
const gchar *
mbim_sms_status_get_string (MbimSmsStatus val)
{
    guint i;

    for (i = 0; mbim_sms_status_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_status_values[i].value)
            return mbim_sms_status_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_STATUS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_STATUS_IS_FLAGS__
gchar *
mbim_sms_status_build_string_from_mask (MbimSmsStatus mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_status_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_status_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_status_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_status_values[i].value) {
            guint c;
            gulong number = mbim_sms_status_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_status_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_STATUS_IS_FLAGS__ */
static const GEnumValue mbim_sms_status_flag_values[] = {
    { MBIM_SMS_STATUS_FLAG_NONE, "MBIM_SMS_STATUS_FLAG_NONE", "none" },
    { MBIM_SMS_STATUS_FLAG_MESSAGE_STORE_FULL, "MBIM_SMS_STATUS_FLAG_MESSAGE_STORE_FULL", "message-store-full" },
    { MBIM_SMS_STATUS_FLAG_NEW_MESSAGE, "MBIM_SMS_STATUS_FLAG_NEW_MESSAGE", "new-message" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sms_status_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSmsStatusFlag"),
                                      mbim_sms_status_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SMS_STATUS_FLAG_IS_ENUM__
const gchar *
mbim_sms_status_flag_get_string (MbimSmsStatusFlag val)
{
    guint i;

    for (i = 0; mbim_sms_status_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_sms_status_flag_values[i].value)
            return mbim_sms_status_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SMS_STATUS_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SMS_STATUS_FLAG_IS_FLAGS__
gchar *
mbim_sms_status_flag_build_string_from_mask (MbimSmsStatusFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sms_status_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sms_status_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sms_status_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sms_status_flag_values[i].value) {
            guint c;
            gulong number = mbim_sms_status_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sms_status_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SMS_STATUS_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_ussd_action_values[] = {
    { MBIM_USSD_ACTION_INITIATE, "MBIM_USSD_ACTION_INITIATE", "initiate" },
    { MBIM_USSD_ACTION_CONTINUE, "MBIM_USSD_ACTION_CONTINUE", "continue" },
    { MBIM_USSD_ACTION_CANCEL, "MBIM_USSD_ACTION_CANCEL", "cancel" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ussd_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUssdAction"),
                                      mbim_ussd_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_USSD_ACTION_IS_ENUM__
const gchar *
mbim_ussd_action_get_string (MbimUssdAction val)
{
    guint i;

    for (i = 0; mbim_ussd_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_ussd_action_values[i].value)
            return mbim_ussd_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_USSD_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_USSD_ACTION_IS_FLAGS__
gchar *
mbim_ussd_action_build_string_from_mask (MbimUssdAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ussd_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ussd_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ussd_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ussd_action_values[i].value) {
            guint c;
            gulong number = mbim_ussd_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ussd_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_USSD_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_ussd_response_values[] = {
    { MBIM_USSD_RESPONSE_NO_ACTION_REQUIRED, "MBIM_USSD_RESPONSE_NO_ACTION_REQUIRED", "no-action-required" },
    { MBIM_USSD_RESPONSE_ACTION_REQUIRED, "MBIM_USSD_RESPONSE_ACTION_REQUIRED", "action-required" },
    { MBIM_USSD_RESPONSE_TERMINATED_BY_NETWORK, "MBIM_USSD_RESPONSE_TERMINATED_BY_NETWORK", "terminated-by-network" },
    { MBIM_USSD_RESPONSE_OTHER_LOCAL_CLIENT, "MBIM_USSD_RESPONSE_OTHER_LOCAL_CLIENT", "other-local-client" },
    { MBIM_USSD_RESPONSE_OPERATION_NOT_SUPPORTED, "MBIM_USSD_RESPONSE_OPERATION_NOT_SUPPORTED", "operation-not-supported" },
    { MBIM_USSD_RESPONSE_NETWORK_TIMEOUT, "MBIM_USSD_RESPONSE_NETWORK_TIMEOUT", "network-timeout" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ussd_response_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUssdResponse"),
                                      mbim_ussd_response_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_USSD_RESPONSE_IS_ENUM__
const gchar *
mbim_ussd_response_get_string (MbimUssdResponse val)
{
    guint i;

    for (i = 0; mbim_ussd_response_values[i].value_nick; i++) {
        if ((gint)val == mbim_ussd_response_values[i].value)
            return mbim_ussd_response_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_USSD_RESPONSE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_USSD_RESPONSE_IS_FLAGS__
gchar *
mbim_ussd_response_build_string_from_mask (MbimUssdResponse mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ussd_response_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ussd_response_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ussd_response_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ussd_response_values[i].value) {
            guint c;
            gulong number = mbim_ussd_response_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ussd_response_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_USSD_RESPONSE_IS_FLAGS__ */
static const GEnumValue mbim_ussd_session_state_values[] = {
    { MBIM_USSD_SESSION_STATE_NEW_SESSION, "MBIM_USSD_SESSION_STATE_NEW_SESSION", "new-session" },
    { MBIM_USSD_SESSION_STATE_EXISTING_SESSION, "MBIM_USSD_SESSION_STATE_EXISTING_SESSION", "existing-session" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_ussd_session_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUssdSessionState"),
                                      mbim_ussd_session_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_USSD_SESSION_STATE_IS_ENUM__
const gchar *
mbim_ussd_session_state_get_string (MbimUssdSessionState val)
{
    guint i;

    for (i = 0; mbim_ussd_session_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_ussd_session_state_values[i].value)
            return mbim_ussd_session_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_USSD_SESSION_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_USSD_SESSION_STATE_IS_FLAGS__
gchar *
mbim_ussd_session_state_build_string_from_mask (MbimUssdSessionState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_ussd_session_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_ussd_session_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_ussd_session_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_ussd_session_state_values[i].value) {
            guint c;
            gulong number = mbim_ussd_session_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_ussd_session_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_USSD_SESSION_STATE_IS_FLAGS__ */
static const GEnumValue mbim_phonebook_state_values[] = {
    { MBIM_PHONEBOOK_STATE_NOT_INITIALIZED, "MBIM_PHONEBOOK_STATE_NOT_INITIALIZED", "not-initialized" },
    { MBIM_PHONEBOOK_STATE_INITIALIZED, "MBIM_PHONEBOOK_STATE_INITIALIZED", "initialized" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_phonebook_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPhonebookState"),
                                      mbim_phonebook_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PHONEBOOK_STATE_IS_ENUM__
const gchar *
mbim_phonebook_state_get_string (MbimPhonebookState val)
{
    guint i;

    for (i = 0; mbim_phonebook_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_phonebook_state_values[i].value)
            return mbim_phonebook_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PHONEBOOK_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PHONEBOOK_STATE_IS_FLAGS__
gchar *
mbim_phonebook_state_build_string_from_mask (MbimPhonebookState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_phonebook_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_phonebook_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_phonebook_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_phonebook_state_values[i].value) {
            guint c;
            gulong number = mbim_phonebook_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_phonebook_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PHONEBOOK_STATE_IS_FLAGS__ */
static const GEnumValue mbim_phonebook_flag_values[] = {
    { MBIM_PHONEBOOK_FLAG_ALL, "MBIM_PHONEBOOK_FLAG_ALL", "all" },
    { MBIM_PHONEBOOK_FLAG_INDEX, "MBIM_PHONEBOOK_FLAG_INDEX", "index" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_phonebook_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPhonebookFlag"),
                                      mbim_phonebook_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PHONEBOOK_FLAG_IS_ENUM__
const gchar *
mbim_phonebook_flag_get_string (MbimPhonebookFlag val)
{
    guint i;

    for (i = 0; mbim_phonebook_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_phonebook_flag_values[i].value)
            return mbim_phonebook_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PHONEBOOK_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PHONEBOOK_FLAG_IS_FLAGS__
gchar *
mbim_phonebook_flag_build_string_from_mask (MbimPhonebookFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_phonebook_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_phonebook_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_phonebook_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_phonebook_flag_values[i].value) {
            guint c;
            gulong number = mbim_phonebook_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_phonebook_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PHONEBOOK_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_phonebook_write_flag_values[] = {
    { MBIM_PHONEBOOK_WRITE_FLAG_SAVE_UNUSED, "MBIM_PHONEBOOK_WRITE_FLAG_SAVE_UNUSED", "unused" },
    { MBIM_PHONEBOOK_WRITE_FLAG_SAVE_INDEX, "MBIM_PHONEBOOK_WRITE_FLAG_SAVE_INDEX", "index" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_phonebook_write_flag_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPhonebookWriteFlag"),
                                      mbim_phonebook_write_flag_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PHONEBOOK_WRITE_FLAG_IS_ENUM__
const gchar *
mbim_phonebook_write_flag_get_string (MbimPhonebookWriteFlag val)
{
    guint i;

    for (i = 0; mbim_phonebook_write_flag_values[i].value_nick; i++) {
        if ((gint)val == mbim_phonebook_write_flag_values[i].value)
            return mbim_phonebook_write_flag_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PHONEBOOK_WRITE_FLAG_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PHONEBOOK_WRITE_FLAG_IS_FLAGS__
gchar *
mbim_phonebook_write_flag_build_string_from_mask (MbimPhonebookWriteFlag mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_phonebook_write_flag_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_phonebook_write_flag_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_phonebook_write_flag_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_phonebook_write_flag_values[i].value) {
            guint c;
            gulong number = mbim_phonebook_write_flag_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_phonebook_write_flag_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PHONEBOOK_WRITE_FLAG_IS_FLAGS__ */
static const GEnumValue mbim_stk_pac_profile_values[] = {
    { MBIM_STK_PAC_PROFILE_NOT_HANDLED_BY_FUNCTION_HANDLED_BY_HOST, "MBIM_STK_PAC_PROFILE_NOT_HANDLED_BY_FUNCTION_HANDLED_BY_HOST", "not-handled-by-function-handled-by-host" },
    { MBIM_STK_PAC_PROFILE_NOT_HANDLED_BY_FUNCTION_MAY_BE_HANDLED_BY_HOST, "MBIM_STK_PAC_PROFILE_NOT_HANDLED_BY_FUNCTION_MAY_BE_HANDLED_BY_HOST", "not-handled-by-function-may-be-handled-by-host" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_ONLY_TRANSPARENT_TO_HOST, "MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_ONLY_TRANSPARENT_TO_HOST", "handled-by-function-only-transparent-to-host" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_NOTIFICATION_TO_HOST_POSSIBLE, "MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_NOTIFICATION_TO_HOST_POSSIBLE", "handled-by-function-notification-to-host-possible" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_NOTIFICATIONS_TO_HOST_ENABLED, "MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_NOTIFICATIONS_TO_HOST_ENABLED", "handled-by-function-notifications-to-host-enabled" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_CAN_BE_OVERRIDEN_BY_HOST, "MBIM_STK_PAC_PROFILE_HANDLED_BY_FUNCTION_CAN_BE_OVERRIDEN_BY_HOST", "handled-by-function-can-be-overriden-by-host" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_HOST_FUNCTION_NOT_ABLE_TO_HANDLE, "MBIM_STK_PAC_PROFILE_HANDLED_BY_HOST_FUNCTION_NOT_ABLE_TO_HANDLE", "handled-by-host-function-not-able-to-handle" },
    { MBIM_STK_PAC_PROFILE_HANDLED_BY_HOST_FUNCTION_ABLE_TO_HANDLE, "MBIM_STK_PAC_PROFILE_HANDLED_BY_HOST_FUNCTION_ABLE_TO_HANDLE", "handled-by-host-function-able-to-handle" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_stk_pac_profile_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimStkPacProfile"),
                                      mbim_stk_pac_profile_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_STK_PAC_PROFILE_IS_ENUM__
const gchar *
mbim_stk_pac_profile_get_string (MbimStkPacProfile val)
{
    guint i;

    for (i = 0; mbim_stk_pac_profile_values[i].value_nick; i++) {
        if ((gint)val == mbim_stk_pac_profile_values[i].value)
            return mbim_stk_pac_profile_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_STK_PAC_PROFILE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_STK_PAC_PROFILE_IS_FLAGS__
gchar *
mbim_stk_pac_profile_build_string_from_mask (MbimStkPacProfile mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_stk_pac_profile_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_stk_pac_profile_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_stk_pac_profile_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_stk_pac_profile_values[i].value) {
            guint c;
            gulong number = mbim_stk_pac_profile_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_stk_pac_profile_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_STK_PAC_PROFILE_IS_FLAGS__ */
static const GEnumValue mbim_stk_pac_type_values[] = {
    { MBIM_STK_PAC_TYPE_PROACTIVE_COMMAND, "MBIM_STK_PAC_TYPE_PROACTIVE_COMMAND", "proactive-command" },
    { MBIM_STK_PAC_TYPE_NOTIFICATION, "MBIM_STK_PAC_TYPE_NOTIFICATION", "notification" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_stk_pac_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimStkPacType"),
                                      mbim_stk_pac_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_STK_PAC_TYPE_IS_ENUM__
const gchar *
mbim_stk_pac_type_get_string (MbimStkPacType val)
{
    guint i;

    for (i = 0; mbim_stk_pac_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_stk_pac_type_values[i].value)
            return mbim_stk_pac_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_STK_PAC_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_STK_PAC_TYPE_IS_FLAGS__
gchar *
mbim_stk_pac_type_build_string_from_mask (MbimStkPacType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_stk_pac_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_stk_pac_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_stk_pac_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_stk_pac_type_values[i].value) {
            guint c;
            gulong number = mbim_stk_pac_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_stk_pac_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_STK_PAC_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_network_idle_hint_state_values[] = {
    { MBIM_NETWORK_IDLE_HINT_STATE_DISABLED, "MBIM_NETWORK_IDLE_HINT_STATE_DISABLED", "disabled" },
    { MBIM_NETWORK_IDLE_HINT_STATE_ENABLED, "MBIM_NETWORK_IDLE_HINT_STATE_ENABLED", "enabled" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_network_idle_hint_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimNetworkIdleHintState"),
                                      mbim_network_idle_hint_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_NETWORK_IDLE_HINT_STATE_IS_ENUM__
const gchar *
mbim_network_idle_hint_state_get_string (MbimNetworkIdleHintState val)
{
    guint i;

    for (i = 0; mbim_network_idle_hint_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_network_idle_hint_state_values[i].value)
            return mbim_network_idle_hint_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_NETWORK_IDLE_HINT_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_NETWORK_IDLE_HINT_STATE_IS_FLAGS__
gchar *
mbim_network_idle_hint_state_build_string_from_mask (MbimNetworkIdleHintState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_network_idle_hint_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_network_idle_hint_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_network_idle_hint_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_network_idle_hint_state_values[i].value) {
            guint c;
            gulong number = mbim_network_idle_hint_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_network_idle_hint_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_NETWORK_IDLE_HINT_STATE_IS_FLAGS__ */
static const GEnumValue mbim_emergency_mode_state_values[] = {
    { MBIM_EMERGENCY_MODE_STATE_OFF, "MBIM_EMERGENCY_MODE_STATE_OFF", "off" },
    { MBIM_EMERGENCY_MODE_STATE_ON, "MBIM_EMERGENCY_MODE_STATE_ON", "on" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_emergency_mode_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimEmergencyModeState"),
                                      mbim_emergency_mode_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_EMERGENCY_MODE_STATE_IS_ENUM__
const gchar *
mbim_emergency_mode_state_get_string (MbimEmergencyModeState val)
{
    guint i;

    for (i = 0; mbim_emergency_mode_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_emergency_mode_state_values[i].value)
            return mbim_emergency_mode_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_EMERGENCY_MODE_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_EMERGENCY_MODE_STATE_IS_FLAGS__
gchar *
mbim_emergency_mode_state_build_string_from_mask (MbimEmergencyModeState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_emergency_mode_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_emergency_mode_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_emergency_mode_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_emergency_mode_state_values[i].value) {
            guint c;
            gulong number = mbim_emergency_mode_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_emergency_mode_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_EMERGENCY_MODE_STATE_IS_FLAGS__ */
static const GEnumValue mbim_dss_link_state_values[] = {
    { MBIM_DSS_LINK_STATE_DEACTIVATE, "MBIM_DSS_LINK_STATE_DEACTIVATE", "deactivate" },
    { MBIM_DSS_LINK_STATE_ACTIVATE, "MBIM_DSS_LINK_STATE_ACTIVATE", "activate" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_dss_link_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimDssLinkState"),
                                      mbim_dss_link_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_DSS_LINK_STATE_IS_ENUM__
const gchar *
mbim_dss_link_state_get_string (MbimDssLinkState val)
{
    guint i;

    for (i = 0; mbim_dss_link_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_dss_link_state_values[i].value)
            return mbim_dss_link_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_DSS_LINK_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_DSS_LINK_STATE_IS_FLAGS__
gchar *
mbim_dss_link_state_build_string_from_mask (MbimDssLinkState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_dss_link_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_dss_link_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_dss_link_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_dss_link_state_values[i].value) {
            guint c;
            gulong number = mbim_dss_link_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_dss_link_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_DSS_LINK_STATE_IS_FLAGS__ */
static const GEnumValue mbim_qdu_session_action_values[] = {
    { MBIM_QDU_SESSION_ACTION_START, "MBIM_QDU_SESSION_ACTION_START", "start" },
    { MBIM_QDU_SESSION_ACTION_STOP, "MBIM_QDU_SESSION_ACTION_STOP", "stop" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_qdu_session_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQduSessionAction"),
                                      mbim_qdu_session_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QDU_SESSION_ACTION_IS_ENUM__
const gchar *
mbim_qdu_session_action_get_string (MbimQduSessionAction val)
{
    guint i;

    for (i = 0; mbim_qdu_session_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_qdu_session_action_values[i].value)
            return mbim_qdu_session_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QDU_SESSION_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QDU_SESSION_ACTION_IS_FLAGS__
gchar *
mbim_qdu_session_action_build_string_from_mask (MbimQduSessionAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_qdu_session_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_qdu_session_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_qdu_session_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_qdu_session_action_values[i].value) {
            guint c;
            gulong number = mbim_qdu_session_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_qdu_session_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QDU_SESSION_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_qdu_session_type_values[] = {
    { MBIM_QDU_SESSION_TYPE_NONE, "MBIM_QDU_SESSION_TYPE_NONE", "none" },
    { MBIM_QDU_SESSION_TYPE_LE, "MBIM_QDU_SESSION_TYPE_LE", "le" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_qdu_session_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQduSessionType"),
                                      mbim_qdu_session_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QDU_SESSION_TYPE_IS_ENUM__
const gchar *
mbim_qdu_session_type_get_string (MbimQduSessionType val)
{
    guint i;

    for (i = 0; mbim_qdu_session_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_qdu_session_type_values[i].value)
            return mbim_qdu_session_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QDU_SESSION_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QDU_SESSION_TYPE_IS_FLAGS__
gchar *
mbim_qdu_session_type_build_string_from_mask (MbimQduSessionType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_qdu_session_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_qdu_session_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_qdu_session_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_qdu_session_type_values[i].value) {
            guint c;
            gulong number = mbim_qdu_session_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_qdu_session_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QDU_SESSION_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_qdu_session_status_values[] = {
    { MBIM_QDU_SESSION_STATUS_INACTIVE, "MBIM_QDU_SESSION_STATUS_INACTIVE", "inactive" },
    { MBIM_QDU_SESSION_STATUS_FILE_TRANSFER, "MBIM_QDU_SESSION_STATUS_FILE_TRANSFER", "file-transfer" },
    { MBIM_QDU_SESSION_STATUS_APPLY_UPDATE, "MBIM_QDU_SESSION_STATUS_APPLY_UPDATE", "apply-update" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_qdu_session_status_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQduSessionStatus"),
                                      mbim_qdu_session_status_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QDU_SESSION_STATUS_IS_ENUM__
const gchar *
mbim_qdu_session_status_get_string (MbimQduSessionStatus val)
{
    guint i;

    for (i = 0; mbim_qdu_session_status_values[i].value_nick; i++) {
        if ((gint)val == mbim_qdu_session_status_values[i].value)
            return mbim_qdu_session_status_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QDU_SESSION_STATUS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QDU_SESSION_STATUS_IS_FLAGS__
gchar *
mbim_qdu_session_status_build_string_from_mask (MbimQduSessionStatus mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_qdu_session_status_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_qdu_session_status_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_qdu_session_status_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_qdu_session_status_values[i].value) {
            guint c;
            gulong number = mbim_qdu_session_status_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_qdu_session_status_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QDU_SESSION_STATUS_IS_FLAGS__ */
static const GEnumValue mbim_qdu_session_result_values[] = {
    { MBIM_QDU_SESSION_RESULT_SUCCESS, "MBIM_QDU_SESSION_RESULT_SUCCESS", "success" },
    { MBIM_QDU_SESSION_RESULT_FAILURE, "MBIM_QDU_SESSION_RESULT_FAILURE", "failure" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_qdu_session_result_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQduSessionResult"),
                                      mbim_qdu_session_result_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QDU_SESSION_RESULT_IS_ENUM__
const gchar *
mbim_qdu_session_result_get_string (MbimQduSessionResult val)
{
    guint i;

    for (i = 0; mbim_qdu_session_result_values[i].value_nick; i++) {
        if ((gint)val == mbim_qdu_session_result_values[i].value)
            return mbim_qdu_session_result_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QDU_SESSION_RESULT_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QDU_SESSION_RESULT_IS_FLAGS__
gchar *
mbim_qdu_session_result_build_string_from_mask (MbimQduSessionResult mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_qdu_session_result_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_qdu_session_result_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_qdu_session_result_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_qdu_session_result_values[i].value) {
            guint c;
            gulong number = mbim_qdu_session_result_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_qdu_session_result_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QDU_SESSION_RESULT_IS_FLAGS__ */
static const GEnumValue mbim_qdu_file_type_values[] = {
    { MBIM_QDU_FILE_TYPE_LITTLE_ENDIAN_PACKAGE, "MBIM_QDU_FILE_TYPE_LITTLE_ENDIAN_PACKAGE", "package" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_qdu_file_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQduFileType"),
                                      mbim_qdu_file_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QDU_FILE_TYPE_IS_ENUM__
const gchar *
mbim_qdu_file_type_get_string (MbimQduFileType val)
{
    guint i;

    for (i = 0; mbim_qdu_file_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_qdu_file_type_values[i].value)
            return mbim_qdu_file_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QDU_FILE_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QDU_FILE_TYPE_IS_FLAGS__
gchar *
mbim_qdu_file_type_build_string_from_mask (MbimQduFileType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_qdu_file_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_qdu_file_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_qdu_file_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_qdu_file_type_values[i].value) {
            guint c;
            gulong number = mbim_qdu_file_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_qdu_file_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QDU_FILE_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_atds_rat_mode_values[] = {
    { MBIM_ATDS_RAT_MODE_AUTOMATIC, "MBIM_ATDS_RAT_MODE_AUTOMATIC", "automatic" },
    { MBIM_ATDS_RAT_MODE_2G_ONLY, "MBIM_ATDS_RAT_MODE_2G_ONLY", "2g-only" },
    { MBIM_ATDS_RAT_MODE_3G_ONLY, "MBIM_ATDS_RAT_MODE_3G_ONLY", "3g-only" },
    { MBIM_ATDS_RAT_MODE_4G_ONLY, "MBIM_ATDS_RAT_MODE_4G_ONLY", "4g-only" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_atds_rat_mode_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimAtdsRatMode"),
                                      mbim_atds_rat_mode_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_ATDS_RAT_MODE_IS_ENUM__
const gchar *
mbim_atds_rat_mode_get_string (MbimAtdsRatMode val)
{
    guint i;

    for (i = 0; mbim_atds_rat_mode_values[i].value_nick; i++) {
        if ((gint)val == mbim_atds_rat_mode_values[i].value)
            return mbim_atds_rat_mode_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_ATDS_RAT_MODE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_ATDS_RAT_MODE_IS_FLAGS__
gchar *
mbim_atds_rat_mode_build_string_from_mask (MbimAtdsRatMode mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_atds_rat_mode_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_atds_rat_mode_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_atds_rat_mode_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_atds_rat_mode_values[i].value) {
            guint c;
            gulong number = mbim_atds_rat_mode_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_atds_rat_mode_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_ATDS_RAT_MODE_IS_FLAGS__ */
static const GEnumValue mbim_atds_provider_plmn_mode_values[] = {
    { MBIM_ATDS_PROVIDER_PLMN_MODE_GSM, "MBIM_ATDS_PROVIDER_PLMN_MODE_GSM", "gsm" },
    { MBIM_ATDS_PROVIDER_PLMN_MODE_UTRAN, "MBIM_ATDS_PROVIDER_PLMN_MODE_UTRAN", "utran" },
    { MBIM_ATDS_PROVIDER_PLMN_MODE_LTE, "MBIM_ATDS_PROVIDER_PLMN_MODE_LTE", "lte" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_atds_provider_plmn_mode_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimAtdsProviderPlmnMode"),
                                      mbim_atds_provider_plmn_mode_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_ATDS_PROVIDER_PLMN_MODE_IS_ENUM__
const gchar *
mbim_atds_provider_plmn_mode_get_string (MbimAtdsProviderPlmnMode val)
{
    guint i;

    for (i = 0; mbim_atds_provider_plmn_mode_values[i].value_nick; i++) {
        if ((gint)val == mbim_atds_provider_plmn_mode_values[i].value)
            return mbim_atds_provider_plmn_mode_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_ATDS_PROVIDER_PLMN_MODE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_ATDS_PROVIDER_PLMN_MODE_IS_FLAGS__
gchar *
mbim_atds_provider_plmn_mode_build_string_from_mask (MbimAtdsProviderPlmnMode mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_atds_provider_plmn_mode_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_atds_provider_plmn_mode_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_atds_provider_plmn_mode_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_atds_provider_plmn_mode_values[i].value) {
            guint c;
            gulong number = mbim_atds_provider_plmn_mode_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_atds_provider_plmn_mode_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_ATDS_PROVIDER_PLMN_MODE_IS_FLAGS__ */
static const GEnumValue mbim_pco_type_values[] = {
    { MBIM_PCO_TYPE_COMPLETE, "MBIM_PCO_TYPE_COMPLETE", "complete" },
    { MBIM_PCO_TYPE_PARTIAL, "MBIM_PCO_TYPE_PARTIAL", "partial" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_pco_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimPcoType"),
                                      mbim_pco_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_PCO_TYPE_IS_ENUM__
const gchar *
mbim_pco_type_get_string (MbimPcoType val)
{
    guint i;

    for (i = 0; mbim_pco_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_pco_type_values[i].value)
            return mbim_pco_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_PCO_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_PCO_TYPE_IS_FLAGS__
gchar *
mbim_pco_type_build_string_from_mask (MbimPcoType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_pco_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_pco_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_pco_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_pco_type_values[i].value) {
            guint c;
            gulong number = mbim_pco_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_pco_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_PCO_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_lte_attach_context_operation_values[] = {
    { MBIM_LTE_ATTACH_CONTEXT_OPERATION_DEFAULT, "MBIM_LTE_ATTACH_CONTEXT_OPERATION_DEFAULT", "default" },
    { MBIM_LTE_ATTACH_CONTEXT_OPERATION_RESTORE_FACTORY, "MBIM_LTE_ATTACH_CONTEXT_OPERATION_RESTORE_FACTORY", "restore-factory" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_lte_attach_context_operation_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimLteAttachContextOperation"),
                                      mbim_lte_attach_context_operation_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_LTE_ATTACH_CONTEXT_OPERATION_IS_ENUM__
const gchar *
mbim_lte_attach_context_operation_get_string (MbimLteAttachContextOperation val)
{
    guint i;

    for (i = 0; mbim_lte_attach_context_operation_values[i].value_nick; i++) {
        if ((gint)val == mbim_lte_attach_context_operation_values[i].value)
            return mbim_lte_attach_context_operation_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_LTE_ATTACH_CONTEXT_OPERATION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_LTE_ATTACH_CONTEXT_OPERATION_IS_FLAGS__
gchar *
mbim_lte_attach_context_operation_build_string_from_mask (MbimLteAttachContextOperation mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_lte_attach_context_operation_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_lte_attach_context_operation_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_lte_attach_context_operation_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_lte_attach_context_operation_values[i].value) {
            guint c;
            gulong number = mbim_lte_attach_context_operation_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_lte_attach_context_operation_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_LTE_ATTACH_CONTEXT_OPERATION_IS_FLAGS__ */
static const GEnumValue mbim_lte_attach_context_roaming_control_values[] = {
    { MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_HOME, "MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_HOME", "home" },
    { MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_PARTNER, "MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_PARTNER", "partner" },
    { MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_NON_PARTNER, "MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_NON_PARTNER", "non-partner" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_lte_attach_context_roaming_control_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimLteAttachContextRoamingControl"),
                                      mbim_lte_attach_context_roaming_control_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_IS_ENUM__
const gchar *
mbim_lte_attach_context_roaming_control_get_string (MbimLteAttachContextRoamingControl val)
{
    guint i;

    for (i = 0; mbim_lte_attach_context_roaming_control_values[i].value_nick; i++) {
        if ((gint)val == mbim_lte_attach_context_roaming_control_values[i].value)
            return mbim_lte_attach_context_roaming_control_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_IS_FLAGS__
gchar *
mbim_lte_attach_context_roaming_control_build_string_from_mask (MbimLteAttachContextRoamingControl mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_lte_attach_context_roaming_control_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_lte_attach_context_roaming_control_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_lte_attach_context_roaming_control_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_lte_attach_context_roaming_control_values[i].value) {
            guint c;
            gulong number = mbim_lte_attach_context_roaming_control_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_lte_attach_context_roaming_control_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_LTE_ATTACH_CONTEXT_ROAMING_CONTROL_IS_FLAGS__ */
static const GEnumValue mbim_context_source_values[] = {
    { MBIM_CONTEXT_SOURCE_ADMIN, "MBIM_CONTEXT_SOURCE_ADMIN", "admin" },
    { MBIM_CONTEXT_SOURCE_USER, "MBIM_CONTEXT_SOURCE_USER", "user" },
    { MBIM_CONTEXT_SOURCE_OPERATOR, "MBIM_CONTEXT_SOURCE_OPERATOR", "operator" },
    { MBIM_CONTEXT_SOURCE_MODEM, "MBIM_CONTEXT_SOURCE_MODEM", "modem" },
    { MBIM_CONTEXT_SOURCE_DEVICE, "MBIM_CONTEXT_SOURCE_DEVICE", "device" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_context_source_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimContextSource"),
                                      mbim_context_source_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CONTEXT_SOURCE_IS_ENUM__
const gchar *
mbim_context_source_get_string (MbimContextSource val)
{
    guint i;

    for (i = 0; mbim_context_source_values[i].value_nick; i++) {
        if ((gint)val == mbim_context_source_values[i].value)
            return mbim_context_source_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CONTEXT_SOURCE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CONTEXT_SOURCE_IS_FLAGS__
gchar *
mbim_context_source_build_string_from_mask (MbimContextSource mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_context_source_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_context_source_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_context_source_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_context_source_values[i].value) {
            guint c;
            gulong number = mbim_context_source_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_context_source_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CONTEXT_SOURCE_IS_FLAGS__ */
static const GEnumValue mbim_lte_attach_state_values[] = {
    { MBIM_LTE_ATTACH_STATE_DETACHED, "MBIM_LTE_ATTACH_STATE_DETACHED", "detached" },
    { MBIM_LTE_ATTACH_STATE_ATTACHED, "MBIM_LTE_ATTACH_STATE_ATTACHED", "attached" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_lte_attach_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimLteAttachState"),
                                      mbim_lte_attach_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_LTE_ATTACH_STATE_IS_ENUM__
const gchar *
mbim_lte_attach_state_get_string (MbimLteAttachState val)
{
    guint i;

    for (i = 0; mbim_lte_attach_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_lte_attach_state_values[i].value)
            return mbim_lte_attach_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_LTE_ATTACH_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_LTE_ATTACH_STATE_IS_FLAGS__
gchar *
mbim_lte_attach_state_build_string_from_mask (MbimLteAttachState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_lte_attach_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_lte_attach_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_lte_attach_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_lte_attach_state_values[i].value) {
            guint c;
            gulong number = mbim_lte_attach_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_lte_attach_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_LTE_ATTACH_STATE_IS_FLAGS__ */
static const GEnumValue mbim_sar_control_mode_values[] = {
    { MBIM_SAR_CONTROL_MODE_DEVICE, "MBIM_SAR_CONTROL_MODE_DEVICE", "device" },
    { MBIM_SAR_CONTROL_MODE_OS, "MBIM_SAR_CONTROL_MODE_OS", "os" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sar_control_mode_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSarControlMode"),
                                      mbim_sar_control_mode_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SAR_CONTROL_MODE_IS_ENUM__
const gchar *
mbim_sar_control_mode_get_string (MbimSarControlMode val)
{
    guint i;

    for (i = 0; mbim_sar_control_mode_values[i].value_nick; i++) {
        if ((gint)val == mbim_sar_control_mode_values[i].value)
            return mbim_sar_control_mode_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SAR_CONTROL_MODE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SAR_CONTROL_MODE_IS_FLAGS__
gchar *
mbim_sar_control_mode_build_string_from_mask (MbimSarControlMode mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sar_control_mode_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sar_control_mode_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sar_control_mode_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sar_control_mode_values[i].value) {
            guint c;
            gulong number = mbim_sar_control_mode_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sar_control_mode_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SAR_CONTROL_MODE_IS_FLAGS__ */
static const GEnumValue mbim_sar_backoff_state_values[] = {
    { MBIM_SAR_BACKOFF_STATE_DISABLED, "MBIM_SAR_BACKOFF_STATE_DISABLED", "disabled" },
    { MBIM_SAR_BACKOFF_STATE_ENABLED, "MBIM_SAR_BACKOFF_STATE_ENABLED", "enabled" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sar_backoff_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSarBackoffState"),
                                      mbim_sar_backoff_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SAR_BACKOFF_STATE_IS_ENUM__
const gchar *
mbim_sar_backoff_state_get_string (MbimSarBackoffState val)
{
    guint i;

    for (i = 0; mbim_sar_backoff_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_sar_backoff_state_values[i].value)
            return mbim_sar_backoff_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SAR_BACKOFF_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SAR_BACKOFF_STATE_IS_FLAGS__
gchar *
mbim_sar_backoff_state_build_string_from_mask (MbimSarBackoffState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sar_backoff_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sar_backoff_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sar_backoff_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sar_backoff_state_values[i].value) {
            guint c;
            gulong number = mbim_sar_backoff_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sar_backoff_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SAR_BACKOFF_STATE_IS_FLAGS__ */
static const GEnumValue mbim_sar_wifi_hardware_state_values[] = {
    { MBIM_SAR_WIFI_HARDWARE_STATE_INTEGRATED, "MBIM_SAR_WIFI_HARDWARE_STATE_INTEGRATED", "integrated" },
    { MBIM_SAR_WIFI_HARDWARE_STATE_NOT_INTEGRATED, "MBIM_SAR_WIFI_HARDWARE_STATE_NOT_INTEGRATED", "not-integrated" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_sar_wifi_hardware_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimSarWifiHardwareState"),
                                      mbim_sar_wifi_hardware_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SAR_WIFI_HARDWARE_STATE_IS_ENUM__
const gchar *
mbim_sar_wifi_hardware_state_get_string (MbimSarWifiHardwareState val)
{
    guint i;

    for (i = 0; mbim_sar_wifi_hardware_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_sar_wifi_hardware_state_values[i].value)
            return mbim_sar_wifi_hardware_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SAR_WIFI_HARDWARE_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SAR_WIFI_HARDWARE_STATE_IS_FLAGS__
gchar *
mbim_sar_wifi_hardware_state_build_string_from_mask (MbimSarWifiHardwareState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_sar_wifi_hardware_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_sar_wifi_hardware_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_sar_wifi_hardware_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_sar_wifi_hardware_state_values[i].value) {
            guint c;
            gulong number = mbim_sar_wifi_hardware_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_sar_wifi_hardware_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SAR_WIFI_HARDWARE_STATE_IS_FLAGS__ */
static const GEnumValue mbim_transmission_notification_status_values[] = {
    { MBIM_TRANSMISSION_NOTIFICATION_STATUS_DISABLED, "MBIM_TRANSMISSION_NOTIFICATION_STATUS_DISABLED", "disabled" },
    { MBIM_TRANSMISSION_NOTIFICATION_STATUS_ENABLED, "MBIM_TRANSMISSION_NOTIFICATION_STATUS_ENABLED", "enabled" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_transmission_notification_status_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimTransmissionNotificationStatus"),
                                      mbim_transmission_notification_status_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_TRANSMISSION_NOTIFICATION_STATUS_IS_ENUM__
const gchar *
mbim_transmission_notification_status_get_string (MbimTransmissionNotificationStatus val)
{
    guint i;

    for (i = 0; mbim_transmission_notification_status_values[i].value_nick; i++) {
        if ((gint)val == mbim_transmission_notification_status_values[i].value)
            return mbim_transmission_notification_status_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_TRANSMISSION_NOTIFICATION_STATUS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_TRANSMISSION_NOTIFICATION_STATUS_IS_FLAGS__
gchar *
mbim_transmission_notification_status_build_string_from_mask (MbimTransmissionNotificationStatus mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_transmission_notification_status_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_transmission_notification_status_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_transmission_notification_status_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_transmission_notification_status_values[i].value) {
            guint c;
            gulong number = mbim_transmission_notification_status_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_transmission_notification_status_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_TRANSMISSION_NOTIFICATION_STATUS_IS_FLAGS__ */
static const GEnumValue mbim_transmission_state_values[] = {
    { MBIM_TRANSMISSION_STATE_INACTIVE, "MBIM_TRANSMISSION_STATE_INACTIVE", "inactive" },
    { MBIM_TRANSMISSION_STATE_ACTIVE, "MBIM_TRANSMISSION_STATE_ACTIVE", "active" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_transmission_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimTransmissionState"),
                                      mbim_transmission_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_TRANSMISSION_STATE_IS_ENUM__
const gchar *
mbim_transmission_state_get_string (MbimTransmissionState val)
{
    guint i;

    for (i = 0; mbim_transmission_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_transmission_state_values[i].value)
            return mbim_transmission_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_TRANSMISSION_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_TRANSMISSION_STATE_IS_FLAGS__
gchar *
mbim_transmission_state_build_string_from_mask (MbimTransmissionState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_transmission_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_transmission_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_transmission_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_transmission_state_values[i].value) {
            guint c;
            gulong number = mbim_transmission_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_transmission_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_TRANSMISSION_STATE_IS_FLAGS__ */
static const GEnumValue mbim_uicc_slot_state_values[] = {
    { MBIM_UICC_SLOT_STATE_UNKNOWN, "MBIM_UICC_SLOT_STATE_UNKNOWN", "state-unknown" },
    { MBIM_UICC_SLOT_SATE_OFF_EMPTY, "MBIM_UICC_SLOT_SATE_OFF_EMPTY", "sate-off-empty" },
    { MBIM_UICC_SLOT_STATE_OFF, "MBIM_UICC_SLOT_STATE_OFF", "state-off" },
    { MBIM_UICC_SLOT_STATE_EMPTY, "MBIM_UICC_SLOT_STATE_EMPTY", "state-empty" },
    { MBIM_UICC_SLOT_STATE_NOT_READY, "MBIM_UICC_SLOT_STATE_NOT_READY", "state-not-ready" },
    { MBIM_UICC_SLOT_STATE_ACTIVE, "MBIM_UICC_SLOT_STATE_ACTIVE", "state-active" },
    { MBIM_UICC_SLOT_STATE_ERROR, "MBIM_UICC_SLOT_STATE_ERROR", "state-error" },
    { MBIM_UICC_SLOT_STATE_ACTIVE_ESIM, "MBIM_UICC_SLOT_STATE_ACTIVE_ESIM", "state-active-esim" },
    { MBIM_UICC_SLOT_STATE_ACTIVE_ESIM_NO_PROFILES, "MBIM_UICC_SLOT_STATE_ACTIVE_ESIM_NO_PROFILES", "state-active-esim-no-profiles" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_uicc_slot_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUiccSlotState"),
                                      mbim_uicc_slot_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_UICC_SLOT_STATE_IS_ENUM__
const gchar *
mbim_uicc_slot_state_get_string (MbimUiccSlotState val)
{
    guint i;

    for (i = 0; mbim_uicc_slot_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_uicc_slot_state_values[i].value)
            return mbim_uicc_slot_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_UICC_SLOT_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_UICC_SLOT_STATE_IS_FLAGS__
gchar *
mbim_uicc_slot_state_build_string_from_mask (MbimUiccSlotState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_uicc_slot_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_uicc_slot_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_uicc_slot_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_uicc_slot_state_values[i].value) {
            guint c;
            gulong number = mbim_uicc_slot_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_uicc_slot_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_UICC_SLOT_STATE_IS_FLAGS__ */
static const GEnumValue mbim_uicc_secure_messaging_values[] = {
    { MBIM_UICC_SECURE_MESSAGING_NONE, "MBIM_UICC_SECURE_MESSAGING_NONE", "none" },
    { MBIM_UICC_SECURE_MESSAGING_NO_HDR_AUTH, "MBIM_UICC_SECURE_MESSAGING_NO_HDR_AUTH", "no-hdr-auth" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_uicc_secure_messaging_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUiccSecureMessaging"),
                                      mbim_uicc_secure_messaging_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_UICC_SECURE_MESSAGING_IS_ENUM__
const gchar *
mbim_uicc_secure_messaging_get_string (MbimUiccSecureMessaging val)
{
    guint i;

    for (i = 0; mbim_uicc_secure_messaging_values[i].value_nick; i++) {
        if ((gint)val == mbim_uicc_secure_messaging_values[i].value)
            return mbim_uicc_secure_messaging_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_UICC_SECURE_MESSAGING_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_UICC_SECURE_MESSAGING_IS_FLAGS__
gchar *
mbim_uicc_secure_messaging_build_string_from_mask (MbimUiccSecureMessaging mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_uicc_secure_messaging_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_uicc_secure_messaging_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_uicc_secure_messaging_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_uicc_secure_messaging_values[i].value) {
            guint c;
            gulong number = mbim_uicc_secure_messaging_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_uicc_secure_messaging_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_UICC_SECURE_MESSAGING_IS_FLAGS__ */
static const GEnumValue mbim_uicc_class_byte_type_values[] = {
    { MBIM_UICC_CLASS_BYTE_TYPE_INTER_INDUSTRY, "MBIM_UICC_CLASS_BYTE_TYPE_INTER_INDUSTRY", "inter-industry" },
    { MBIM_UICC_CLASS_BYTE_TYPE_EXTENDED, "MBIM_UICC_CLASS_BYTE_TYPE_EXTENDED", "extended" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_uicc_class_byte_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUiccClassByteType"),
                                      mbim_uicc_class_byte_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_UICC_CLASS_BYTE_TYPE_IS_ENUM__
const gchar *
mbim_uicc_class_byte_type_get_string (MbimUiccClassByteType val)
{
    guint i;

    for (i = 0; mbim_uicc_class_byte_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_uicc_class_byte_type_values[i].value)
            return mbim_uicc_class_byte_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_UICC_CLASS_BYTE_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_UICC_CLASS_BYTE_TYPE_IS_FLAGS__
gchar *
mbim_uicc_class_byte_type_build_string_from_mask (MbimUiccClassByteType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_uicc_class_byte_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_uicc_class_byte_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_uicc_class_byte_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_uicc_class_byte_type_values[i].value) {
            guint c;
            gulong number = mbim_uicc_class_byte_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_uicc_class_byte_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_UICC_CLASS_BYTE_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_uicc_pass_through_action_values[] = {
    { MBIM_UICC_PASS_THROUGH_ACTION_DISABLE, "MBIM_UICC_PASS_THROUGH_ACTION_DISABLE", "disable" },
    { MBIM_UICC_PASS_THROUGH_ACTION_ENABLE, "MBIM_UICC_PASS_THROUGH_ACTION_ENABLE", "enable" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_uicc_pass_through_action_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUiccPassThroughAction"),
                                      mbim_uicc_pass_through_action_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_UICC_PASS_THROUGH_ACTION_IS_ENUM__
const gchar *
mbim_uicc_pass_through_action_get_string (MbimUiccPassThroughAction val)
{
    guint i;

    for (i = 0; mbim_uicc_pass_through_action_values[i].value_nick; i++) {
        if ((gint)val == mbim_uicc_pass_through_action_values[i].value)
            return mbim_uicc_pass_through_action_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_UICC_PASS_THROUGH_ACTION_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_UICC_PASS_THROUGH_ACTION_IS_FLAGS__
gchar *
mbim_uicc_pass_through_action_build_string_from_mask (MbimUiccPassThroughAction mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_uicc_pass_through_action_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_uicc_pass_through_action_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_uicc_pass_through_action_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_uicc_pass_through_action_values[i].value) {
            guint c;
            gulong number = mbim_uicc_pass_through_action_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_uicc_pass_through_action_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_UICC_PASS_THROUGH_ACTION_IS_FLAGS__ */
static const GEnumValue mbim_uicc_pass_through_status_values[] = {
    { MBIM_UICC_PASS_THROUGH_STATUS_DISABLED, "MBIM_UICC_PASS_THROUGH_STATUS_DISABLED", "disabled" },
    { MBIM_UICC_PASS_THROUGH_STATUS_ENABLED, "MBIM_UICC_PASS_THROUGH_STATUS_ENABLED", "enabled" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_uicc_pass_through_status_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimUiccPassThroughStatus"),
                                      mbim_uicc_pass_through_status_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_UICC_PASS_THROUGH_STATUS_IS_ENUM__
const gchar *
mbim_uicc_pass_through_status_get_string (MbimUiccPassThroughStatus val)
{
    guint i;

    for (i = 0; mbim_uicc_pass_through_status_values[i].value_nick; i++) {
        if ((gint)val == mbim_uicc_pass_through_status_values[i].value)
            return mbim_uicc_pass_through_status_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_UICC_PASS_THROUGH_STATUS_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_UICC_PASS_THROUGH_STATUS_IS_FLAGS__
gchar *
mbim_uicc_pass_through_status_build_string_from_mask (MbimUiccPassThroughStatus mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_uicc_pass_through_status_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_uicc_pass_through_status_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_uicc_pass_through_status_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_uicc_pass_through_status_values[i].value) {
            guint c;
            gulong number = mbim_uicc_pass_through_status_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_uicc_pass_through_status_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_UICC_PASS_THROUGH_STATUS_IS_FLAGS__ */
static const GEnumValue mbim_quectel_radio_switch_state_values[] = {
    { MBIM_QUECTEL_RADIO_SWITCH_STATE_OFF, "MBIM_QUECTEL_RADIO_SWITCH_STATE_OFF", "off" },
    { MBIM_QUECTEL_RADIO_SWITCH_STATE_ON, "MBIM_QUECTEL_RADIO_SWITCH_STATE_ON", "on" },
    { MBIM_QUECTEL_RADIO_SWITCH_STATE_FCC_LOCKED, "MBIM_QUECTEL_RADIO_SWITCH_STATE_FCC_LOCKED", "fcc-locked" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_quectel_radio_switch_state_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimQuectelRadioSwitchState"),
                                      mbim_quectel_radio_switch_state_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_QUECTEL_RADIO_SWITCH_STATE_IS_ENUM__
const gchar *
mbim_quectel_radio_switch_state_get_string (MbimQuectelRadioSwitchState val)
{
    guint i;

    for (i = 0; mbim_quectel_radio_switch_state_values[i].value_nick; i++) {
        if ((gint)val == mbim_quectel_radio_switch_state_values[i].value)
            return mbim_quectel_radio_switch_state_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_QUECTEL_RADIO_SWITCH_STATE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_QUECTEL_RADIO_SWITCH_STATE_IS_FLAGS__
gchar *
mbim_quectel_radio_switch_state_build_string_from_mask (MbimQuectelRadioSwitchState mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_quectel_radio_switch_state_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_quectel_radio_switch_state_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_quectel_radio_switch_state_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_quectel_radio_switch_state_values[i].value) {
            guint c;
            gulong number = mbim_quectel_radio_switch_state_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_quectel_radio_switch_state_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_QUECTEL_RADIO_SWITCH_STATE_IS_FLAGS__ */
/* enumerations from "../libmbim/src/libmbim-glib/mbim-message.h" */
static const GEnumValue mbim_message_type_values[] = {
    { MBIM_MESSAGE_TYPE_INVALID, "MBIM_MESSAGE_TYPE_INVALID", "invalid" },
    { MBIM_MESSAGE_TYPE_OPEN, "MBIM_MESSAGE_TYPE_OPEN", "open" },
    { MBIM_MESSAGE_TYPE_CLOSE, "MBIM_MESSAGE_TYPE_CLOSE", "close" },
    { MBIM_MESSAGE_TYPE_COMMAND, "MBIM_MESSAGE_TYPE_COMMAND", "command" },
    { MBIM_MESSAGE_TYPE_HOST_ERROR, "MBIM_MESSAGE_TYPE_HOST_ERROR", "host-error" },
    { MBIM_MESSAGE_TYPE_OPEN_DONE, "MBIM_MESSAGE_TYPE_OPEN_DONE", "open-done" },
    { MBIM_MESSAGE_TYPE_CLOSE_DONE, "MBIM_MESSAGE_TYPE_CLOSE_DONE", "close-done" },
    { MBIM_MESSAGE_TYPE_COMMAND_DONE, "MBIM_MESSAGE_TYPE_COMMAND_DONE", "command-done" },
    { MBIM_MESSAGE_TYPE_FUNCTION_ERROR, "MBIM_MESSAGE_TYPE_FUNCTION_ERROR", "function-error" },
    { MBIM_MESSAGE_TYPE_INDICATE_STATUS, "MBIM_MESSAGE_TYPE_INDICATE_STATUS", "indicate-status" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_message_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimMessageType"),
                                      mbim_message_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_MESSAGE_TYPE_IS_ENUM__
const gchar *
mbim_message_type_get_string (MbimMessageType val)
{
    guint i;

    for (i = 0; mbim_message_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_message_type_values[i].value)
            return mbim_message_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_MESSAGE_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_MESSAGE_TYPE_IS_FLAGS__
gchar *
mbim_message_type_build_string_from_mask (MbimMessageType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_message_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_message_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_message_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_message_type_values[i].value) {
            guint c;
            gulong number = mbim_message_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_message_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_MESSAGE_TYPE_IS_FLAGS__ */
static const GEnumValue mbim_message_command_type_values[] = {
    { MBIM_MESSAGE_COMMAND_TYPE_UNKNOWN, "MBIM_MESSAGE_COMMAND_TYPE_UNKNOWN", "unknown" },
    { MBIM_MESSAGE_COMMAND_TYPE_QUERY, "MBIM_MESSAGE_COMMAND_TYPE_QUERY", "query" },
    { MBIM_MESSAGE_COMMAND_TYPE_SET, "MBIM_MESSAGE_COMMAND_TYPE_SET", "set" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_message_command_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimMessageCommandType"),
                                      mbim_message_command_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_MESSAGE_COMMAND_TYPE_IS_ENUM__
const gchar *
mbim_message_command_type_get_string (MbimMessageCommandType val)
{
    guint i;

    for (i = 0; mbim_message_command_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_message_command_type_values[i].value)
            return mbim_message_command_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_MESSAGE_COMMAND_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_MESSAGE_COMMAND_TYPE_IS_FLAGS__
gchar *
mbim_message_command_type_build_string_from_mask (MbimMessageCommandType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_message_command_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_message_command_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_message_command_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_message_command_type_values[i].value) {
            guint c;
            gulong number = mbim_message_command_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_message_command_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_MESSAGE_COMMAND_TYPE_IS_FLAGS__ */
/* enumerations from "../libmbim/src/libmbim-glib/mbim-uuid.h" */
static const GEnumValue mbim_service_values[] = {
    { MBIM_SERVICE_INVALID, "MBIM_SERVICE_INVALID", "invalid" },
    { MBIM_SERVICE_BASIC_CONNECT, "MBIM_SERVICE_BASIC_CONNECT", "basic-connect" },
    { MBIM_SERVICE_SMS, "MBIM_SERVICE_SMS", "sms" },
    { MBIM_SERVICE_USSD, "MBIM_SERVICE_USSD", "ussd" },
    { MBIM_SERVICE_PHONEBOOK, "MBIM_SERVICE_PHONEBOOK", "phonebook" },
    { MBIM_SERVICE_STK, "MBIM_SERVICE_STK", "stk" },
    { MBIM_SERVICE_AUTH, "MBIM_SERVICE_AUTH", "auth" },
    { MBIM_SERVICE_DSS, "MBIM_SERVICE_DSS", "dss" },
    { MBIM_SERVICE_MS_FIRMWARE_ID, "MBIM_SERVICE_MS_FIRMWARE_ID", "ms-firmware-id" },
    { MBIM_SERVICE_MS_HOST_SHUTDOWN, "MBIM_SERVICE_MS_HOST_SHUTDOWN", "ms-host-shutdown" },
    { MBIM_SERVICE_PROXY_CONTROL, "MBIM_SERVICE_PROXY_CONTROL", "proxy-control" },
    { MBIM_SERVICE_QMI, "MBIM_SERVICE_QMI", "qmi" },
    { MBIM_SERVICE_ATDS, "MBIM_SERVICE_ATDS", "atds" },
    { MBIM_SERVICE_INTEL_FIRMWARE_UPDATE, "MBIM_SERVICE_INTEL_FIRMWARE_UPDATE", "intel-firmware-update" },
    { MBIM_SERVICE_MS_BASIC_CONNECT_EXTENSIONS, "MBIM_SERVICE_MS_BASIC_CONNECT_EXTENSIONS", "ms-basic-connect-extensions" },
    { MBIM_SERVICE_MS_SAR, "MBIM_SERVICE_MS_SAR", "ms-sar" },
    { MBIM_SERVICE_QDU, "MBIM_SERVICE_QDU", "qdu" },
    { MBIM_SERVICE_MS_UICC_LOW_LEVEL_ACCESS, "MBIM_SERVICE_MS_UICC_LOW_LEVEL_ACCESS", "ms-uicc-low-level-access" },
    { MBIM_SERVICE_QUECTEL, "MBIM_SERVICE_QUECTEL", "quectel" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_service_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimService"),
                                      mbim_service_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_SERVICE_IS_ENUM__
const gchar *
mbim_service_get_string (MbimService val)
{
    guint i;

    for (i = 0; mbim_service_values[i].value_nick; i++) {
        if ((gint)val == mbim_service_values[i].value)
            return mbim_service_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_SERVICE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_SERVICE_IS_FLAGS__
gchar *
mbim_service_build_string_from_mask (MbimService mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_service_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_service_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_service_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_service_values[i].value) {
            guint c;
            gulong number = mbim_service_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_service_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_SERVICE_IS_FLAGS__ */
static const GEnumValue mbim_context_type_values[] = {
    { MBIM_CONTEXT_TYPE_INVALID, "MBIM_CONTEXT_TYPE_INVALID", "invalid" },
    { MBIM_CONTEXT_TYPE_NONE, "MBIM_CONTEXT_TYPE_NONE", "none" },
    { MBIM_CONTEXT_TYPE_INTERNET, "MBIM_CONTEXT_TYPE_INTERNET", "internet" },
    { MBIM_CONTEXT_TYPE_VPN, "MBIM_CONTEXT_TYPE_VPN", "vpn" },
    { MBIM_CONTEXT_TYPE_VOICE, "MBIM_CONTEXT_TYPE_VOICE", "voice" },
    { MBIM_CONTEXT_TYPE_VIDEO_SHARE, "MBIM_CONTEXT_TYPE_VIDEO_SHARE", "video-share" },
    { MBIM_CONTEXT_TYPE_PURCHASE, "MBIM_CONTEXT_TYPE_PURCHASE", "purchase" },
    { MBIM_CONTEXT_TYPE_IMS, "MBIM_CONTEXT_TYPE_IMS", "ims" },
    { MBIM_CONTEXT_TYPE_MMS, "MBIM_CONTEXT_TYPE_MMS", "mms" },
    { MBIM_CONTEXT_TYPE_LOCAL, "MBIM_CONTEXT_TYPE_LOCAL", "local" },
    { 0, NULL, NULL }
};

/* Define type-specific symbols */

GType
mbim_context_type_get_type (void)
{
    static gsize g_define_type_id_initialized = 0;

    if (g_once_init_enter (&g_define_type_id_initialized)) {
        GType g_define_type_id =
            g_enum_register_static (g_intern_static_string ("MbimContextType"),
                                      mbim_context_type_values);
        g_once_init_leave (&g_define_type_id_initialized, g_define_type_id);
    }

    return g_define_type_id_initialized;
}

/* Enum-specific method to get the value as a string.
 * We get the nick of the GEnumValue. Note that this will be
 * valid even if the GEnumClass is not referenced anywhere. */
#if defined __MBIM_CONTEXT_TYPE_IS_ENUM__
const gchar *
mbim_context_type_get_string (MbimContextType val)
{
    guint i;

    for (i = 0; mbim_context_type_values[i].value_nick; i++) {
        if ((gint)val == mbim_context_type_values[i].value)
            return mbim_context_type_values[i].value_nick;
    }

    return NULL;
}
#endif /* __MBIM_CONTEXT_TYPE_IS_ENUM__ */

/* Flags-specific method to build a string with the given mask.
 * We get a comma separated list of the nicks of the GFlagsValues.
 * Note that this will be valid even if the GFlagsClass is not referenced
 * anywhere. */
#if defined __MBIM_CONTEXT_TYPE_IS_FLAGS__
gchar *
mbim_context_type_build_string_from_mask (MbimContextType mask)
{
    guint i;
    gboolean first = TRUE;
    GString *str = NULL;

    for (i = 0; mbim_context_type_values[i].value_nick; i++) {
        /* We also look for exact matches */
        if ((guint)mask == mbim_context_type_values[i].value) {
            if (str)
                g_string_free (str, TRUE);
            return g_strdup (mbim_context_type_values[i].value_nick);
        }

        /* Build list with single-bit masks */
        if (mask & mbim_context_type_values[i].value) {
            guint c;
            gulong number = mbim_context_type_values[i].value;

            for (c = 0; number; c++)
                number &= number - 1;

            if (c == 1) {
                if (!str)
                    str = g_string_new ("");
                g_string_append_printf (str, "%s%s",
                                        first ? "" : ", ",
                                        mbim_context_type_values[i].value_nick);
                if (first)
                    first = FALSE;
            }
        }
    }

    return (str ? g_string_free (str, FALSE) : NULL);
}
#endif /* __MBIM_CONTEXT_TYPE_IS_FLAGS__ */

/* Generated data ends here */

