From 55654d5b462f59ec5d6d77de759a1b7012f3d5c6 Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Mon, 19 Dec 2011 12:28:49 +0100 Subject: cli: new helper to get name of MMBearerIpMethod --- cli/mmcli-common.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'cli/mmcli-common.c') diff --git a/cli/mmcli-common.c b/cli/mmcli-common.c index 11b4b831..9eff59fb 100644 --- a/cli/mmcli-common.c +++ b/cli/mmcli-common.c @@ -237,6 +237,19 @@ mmcli_get_modem_sync (GDBusConnection *connection, return found; } +const gchar * +mmcli_get_bearer_ip_method_string (MMBearerIpMethod method) +{ + static GEnumClass *enum_class = NULL; + GEnumValue *value; + + if (!enum_class) + enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_BEARER_IP_METHOD)); + + value = g_enum_get_value (enum_class, method); + return value->value_nick; +} + const gchar * mmcli_get_state_string (MMModemState state) { -- cgit v1.2.3-70-g09d2