EDataServer.OAuth2Services¶
| Subclasses: | None | 
|---|
Methods¶
| Inherited: | GObject.Object (37), EDataServer.Extensible (2) | 
|---|---|
| Structs: | GObject.ObjectClass (5) | 
| class | is_oauth2_alias_static(auth_method) | 
| class | is_supported() | 
| class | new() | 
| add(service) | |
| find(source) | |
| guess(protocol, hostname) | |
| is_oauth2_alias(auth_method) | |
| list() | |
| remove(service) | 
Virtual Methods¶
| Inherited: | GObject.Object (7) | 
|---|
Properties¶
None
Signals¶
| Inherited: | GObject.Object (1) | 
|---|
Class Details¶
- 
class EDataServer.OAuth2Services(**kwargs)¶
- Bases: - GObject.Object,- EDataServer.Extensible- Abstract: - No - Structure: - EDataServer.OAuth2ServicesClass- Contains only private data that should be read and manipulated using the functions below. - New in version 3.28. - 
classmethod is_oauth2_alias_static(auth_method)¶
- Parameters: - auth_method ( - stror- None) – an authentication method, or- None- Returns: - whether exists any - EDataServer.OAuth2Service, with the same name as auth_method.- Return type: - bool- This is the same as - EDataServer.OAuth2Services.is_oauth2_alias(), except it creates its own- EDataServer.OAuth2Servicesinstance and frees it at the end. The- EDataServer.OAuth2Servicesis implemented as a singleton, thus it won’t be much trouble, as long as there is something else having created one instance.- New in version 3.28. 
 - 
classmethod is_supported()¶
- Returns: - True, when evolution-data-server had been compiled with OAuth2 authentication enabled,- Falseotherwise.- Return type: - bool- New in version 3.28. 
 - 
classmethod new()¶
- Returns: - an - EDataServer.OAuth2Services- Return type: - EDataServer.OAuth2Services- Creates a new - EDataServer.OAuth2Servicesinstance.- New in version 3.28. 
 - 
add(service)¶
- Parameters: - service ( - EDataServer.OAuth2Service) – an- EDataServer.OAuth2Serviceto add- Adds the service to the list of known OAuth2 services into self. It also adds a reference to service. - New in version 3.28. 
 - 
find(source)¶
- Parameters: - source ( - EDataServer.Source) – an- EDataServer.Source- Returns: - a referenced - EDataServer.OAuth2Service, which can be used with given source, or- None, when none was found.- Return type: - EDataServer.OAuth2Serviceor- None- Searches the list of currently known OAuth2 services for the one which can be used with the given source. - The returned - EDataServer.OAuth2Serviceis referenced for thread safety, if found.- New in version 3.28. 
 - 
guess(protocol, hostname)¶
- Parameters: - Returns: - a referenced - EDataServer.OAuth2Service, which can be used with given constraints, or- None, when none was found.- Return type: - Searches the list of currently known OAuth2 services for the one which can be used with the given protocol and/or hostname. Any of protocol and hostname can be - None, but not both. It’s up to each- EDataServer.OAuth2Serviceto decide, which of the arguments are important and whether all or only any of them can be required.- The returned - EDataServer.OAuth2Serviceis referenced for thread safety, if found.- New in version 3.28. 
 - 
is_oauth2_alias(auth_method)¶
- Parameters: - auth_method ( - stror- None) – an authentication method, or- None- Returns: - whether exists any - EDataServer.OAuth2Service, with the same name as auth_method.- Return type: - bool- New in version 3.28. 
 - 
list()¶
- Returns: - a newly allocated - GLib.SListwith all currently known- EDataServer.OAuth2Servicereferenced instances- Return type: - [ - EDataServer.OAuth2Service]- Lists all currently known services, which had been added with - EDataServer.OAuth2Services.add(). Free the returned- GLib.SListwith g_slist_remove_full (known_services,- GObject.Object.unref); when no longer needed.- New in version 3.28. 
 - 
remove(service)¶
- Parameters: - service ( - EDataServer.OAuth2Service) – an- EDataServer.OAuth2Serviceto remove- Removes the service from the list of known services in self. The function does nothing, if the service had not been added. - New in version 3.28. 
 
- 
classmethod