Branch data Line data Source code
1 : : /* libsecret - GLib wrapper for Secret Service 2 : : * 3 : : * Copyright 2019 Red Hat, Inc. 4 : : * 5 : : * This program is free software: you can redistribute it and/or modify 6 : : * it under the terms of the GNU Lesser General Public License as published 7 : : * by the Free Software Foundation; either version 2.1 of the licence or (at 8 : : * your option) any later version. 9 : : * 10 : : * See the included COPYING file for more information. 11 : : * 12 : : * Author: Daiki Ueno 13 : : */ 14 : : 15 : : #if !defined (__SECRET_INSIDE_HEADER__) && !defined (SECRET_COMPILATION) 16 : : #error "Only <libsecret/secret.h> can be included directly." 17 : : #endif 18 : : 19 : : #ifndef __SECRET_RETRIEVABLE_H__ 20 : : #define __SECRET_RETRIEVABLE_H__ 21 : : 22 : : #include <glib-object.h> 23 : : #include "secret-value.h" 24 : : 25 : : G_BEGIN_DECLS 26 : : 27 : : #define SECRET_TYPE_RETRIEVABLE secret_retrievable_get_type () 28 [ - + + - : 82 : G_DECLARE_INTERFACE (SecretRetrievable, secret_retrievable, SECRET, RETRIEVABLE, GObject) - + ] 29 : : 30 : : struct _SecretRetrievableInterface 31 : : { 32 : : GTypeInterface parent_iface; 33 : : 34 : : void (*retrieve_secret) (SecretRetrievable *self, 35 : : GCancellable *cancellable, 36 : : GAsyncReadyCallback callback, 37 : : gpointer user_data); 38 : : SecretValue *(*retrieve_secret_finish) (SecretRetrievable *self, 39 : : GAsyncResult *result, 40 : : GError **error); 41 : : }; 42 : : 43 : : void secret_retrievable_retrieve_secret (SecretRetrievable *self, 44 : : GCancellable *cancellable, 45 : : GAsyncReadyCallback callback, 46 : : gpointer user_data); 47 : : 48 : : SecretValue *secret_retrievable_retrieve_secret_finish (SecretRetrievable *self, 49 : : GAsyncResult *result, 50 : : GError **error); 51 : : 52 : : SecretValue *secret_retrievable_retrieve_secret_sync (SecretRetrievable *self, 53 : : GCancellable *cancellable, 54 : : GError **error); 55 : : 56 : : GHashTable *secret_retrievable_get_attributes (SecretRetrievable *self); 57 : : gchar *secret_retrievable_get_label (SecretRetrievable *self); 58 : : guint64 secret_retrievable_get_created (SecretRetrievable *self); 59 : : guint64 secret_retrievable_get_modified (SecretRetrievable *self); 60 : : 61 : : 62 : : G_END_DECLS 63 : : 64 : : #endif /* __SECRET_RETRIEVABLE_H__ */