api,dbus: 'ip-type' property now given as a MMBearerIpFamily (u)

Instead of using a predefined set of string values for 'ip-type' in
Modem.CreateBearer() and Simple.Connect(), we'll use an enumeration. The
implementation will then need to convert the requested IP family type to e.g.
the correct PDP type in 3GPP modems.

This change also consolidates the use of enums in dictionary properties when
possible to do so, as with the Rm Protocol.
This commit is contained in:
Aleksander Morgado
2012-08-22 09:35:15 +02:00
parent c15525a1b3
commit 1ac18a06bb
15 changed files with 162 additions and 61 deletions

View File

@@ -444,6 +444,22 @@ typedef enum { /*< underscore_name=mm_bearer_ip_method >*/
MM_BEARER_IP_METHOD_DHCP = 3,
} MMBearerIpMethod;
/**
* MMBearerIpFamily:
* @MM_BEARER_IP_FAMILY_UNKNOWN: Unknown.
* @MM_BEARER_IP_FAMILY_IPV4: IPv4.
* @MM_BEARER_IP_FAMILY_IPV6: IPv6.
* @MM_BEARER_IP_FAMILY_IPV4V6: IPv4 and IPv6.
*
* Type of IP family to be used in a given Bearer.
*/
typedef enum { /*< underscore_name=mm_bearer_ip_family >*/
MM_BEARER_IP_FAMILY_UNKNOWN = 0,
MM_BEARER_IP_FAMILY_IPV4 = 4,
MM_BEARER_IP_FAMILY_IPV6 = 6,
MM_BEARER_IP_FAMILY_IPV4V6 = 10
} MMBearerIpFamily;
/**
* MMModemCdmaRegistrationState:
* @MM_MODEM_CDMA_REGISTRATION_STATE_UNKNOWN: Registration status is unknown or the device is not registered.