X-Git-Url: http://git.maemo.org/git/?p=modest;a=blobdiff_plain;f=src%2Fmodest-protocol-info.h;h=dc1d2c0ebdab54c02d95b9d74df5b5f051fcbc61;hp=3b567ff93dc186fc1c033f055266eb0501152883;hb=74e08db4fa22d92bdd87f31bde34b076248ece1e;hpb=6bab4bfef92fef73852d6acd51d1ebf381a338e4 diff --git a/src/modest-protocol-info.h b/src/modest-protocol-info.h index 3b567ff..dc1d2c0 100644 --- a/src/modest-protocol-info.h +++ b/src/modest-protocol-info.h @@ -79,6 +79,23 @@ ModestPairList* modest_protocol_info_get_transport_store_protocol_pair_list (); /** + * modest_protocol_info_get_supported_store_protocol_pair_list: + * + * return the list of -tuples of + * store protocols. + * The elements of the returned list are ModestPairs + * This is a convenience function for use with ModestComboBox + * + * In this case it only returns the UI exposed protocols for + * storage (IMAP, POP3). + * + * Returns: a list of protocols. After use, it should be freed + * with modest_pair_list_free + */ +ModestPairList* +modest_protocol_info_get_supported_store_protocol_pair_list (); + +/** * modest_protocol_info_get_auth_protocol_pair_list: * * return the list of -tupels of protocols. @@ -88,8 +105,7 @@ modest_protocol_info_get_transport_store_protocol_pair_list (); * Returns: a list of protocols. After use, it should be freed * with modest_pair_list_free */ -ModestPairList* -modest_protocol_info_get_auth_protocol_pair_list (); +ModestPairList* modest_protocol_info_get_auth_protocol_pair_list (void); /** @@ -102,21 +118,38 @@ modest_protocol_info_get_auth_protocol_pair_list (); * Returns: a list of protocols. After use, it should be freed * with modest_pair_list_free */ -ModestPairList* -modest_protocol_info_get_connection_protocol_pair_list (); +ModestPairList* modest_protocol_info_get_connection_protocol_pair_list (void); /** * modest_protocol_info_get_transport_store_protocol: - * @name: the name of the ModestTransportStoreProtocol - * @proto_type: the type of protocol you want to have + * @name: the name of the #ModestTransportStoreProtocol * * return the id of the protocol with the given name * * Returns: the id of the protocol or MODEST_PROTOCOL_TRANSPORT_STORE_UNKNOWN */ -ModestTransportStoreProtocol -modest_protocol_info_get_transport_store_protocol (const gchar* name); +ModestTransportStoreProtocol modest_protocol_info_get_transport_store_protocol (const gchar* name); + +/** + * modest_protocol_info_get_auth_protocol: + * @name: The name of the #ModestAuthProtocol + * + * Returns the ID of the protocol with the given name + * + * Returns: The ID of the protocol or MODEST_PROTOCOL_AUTH_NONE + */ +ModestAuthProtocol modest_protocol_info_get_auth_protocol (const gchar* name); + +/** + * modest_protocol_info_get_connection_protocol: + * @name: The name of the #ModestConnectionProtocol + * + * Returns the ID of the protocol with the given name + * + * Returns: The ID of the protocol or MODEST_CONNECTION_PROTOCOL_NORMAL + */ +ModestConnectionProtocol modest_protocol_info_get_connection_protocol (const gchar* name); /** * modest_protocol_info_get_transport_store_protocol_name: @@ -126,8 +159,7 @@ modest_protocol_info_get_transport_store_protocol (const gchar* name); * * Returns: string id of the proto as a constant string, that should NOT be modified or freed */ -const gchar* -modest_protocol_info_get_transport_store_protocol_name (ModestTransportStoreProtocol proto); +const gchar* modest_protocol_info_get_transport_store_protocol_name (ModestTransportStoreProtocol proto); /** * modest_protocol_info_get_auth_protocol_name: @@ -137,8 +169,7 @@ modest_protocol_info_get_transport_store_protocol_name (ModestTransportStoreProt * * Returns: string id of the proto as a constant string, that should NOT be modified or freed */ -const gchar* -modest_protocol_info_get_auth_protocol_name (ModestAuthProtocol proto); +const gchar* modest_protocol_info_get_auth_protocol_name (ModestAuthProtocol proto); /* * modest_protocol_get_auth_protocol_pair_list: @@ -148,9 +179,7 @@ modest_protocol_info_get_auth_protocol_name (ModestAuthProtocol proto); * * Returns: List of method/display name pairs */ - -ModestPairList* -modest_protocol_info_get_auth_protocol_pair_list (); +ModestPairList* modest_protocol_info_get_auth_protocol_pair_list (void); /** * modest_protocol_info_get_auth_protocol_name: @@ -188,6 +217,29 @@ gboolean modest_protocol_info_protocol_is_store (ModestTransportStoreProtocol pr gboolean modest_protocol_info_protocol_is_local_store (ModestTransportStoreProtocol proto); +/** + * modest_protocol_info_is_secure: + * @protocol + * + * is the protocol connection secure (e.g encrypted)? + * + * Returns: TRUE if it is secure, FALSE otherwise + * + */ +gboolean modest_protocol_info_is_secure(ModestConnectionProtocol protocol); + +/** + * modest_protocol_info_auth_is_secure: + * @protocol + * + * is the protocol authentication secure (e.g encrypted)? + * + * Returns: TRUE if it is secure, FALSE otherwise + * + */ +gboolean modest_protocol_info_auth_is_secure(ModestAuthProtocol protocol); + + G_END_DECLS #endif /* __MODEST_PROTOCOL_INFO_H__ */