list_find_service_type


Description:

[ Version ( since = "1.4" ) ]
public static string list_find_service_type (SList<VpnPluginInfo> list, string name)

A VPN plugin provides one or several service-types, like org.

freedesktop.NetworkManager.libreswan Certain plugins provide more then one service type, via aliases (org.freedesktop.NetworkManager.openswan). This function looks up a service-type (or an alias) based on a name.

Preferably, the name can be a full service-type/alias of an installed plugin. Otherwise, it can be the name of a VPN plugin (in which case, the primary, non-aliased service-type is returned). Otherwise, it can be one of several well known short-names (which is a hard-coded list of types in libnm). On success, this returns a full qualified service-type (or an alias). It doesn't say, that such an plugin is actually available, but it could be retrieved via list_find_by_service.

Parameters:

list

a possibly empty SList of VpnPluginInfo instances

name

a name to lookup the service-type.

Returns:

the resolved service-type or null on failure.