libseahorse Reference Manual | ||||
---|---|---|---|---|
Top | Description |
Synopsis
#include <seahorse-source.h> #define SEAHORSE_SOURCE_GET_INTERFACE (obj) SeahorseSource; struct SeahorseSourceIface; SeahorseOperation * seahorse_source_load (SeahorseSource *sksrc
); void seahorse_source_load_sync (SeahorseSource *sksrc
); void seahorse_source_load_async (SeahorseSource *sksrc
); SeahorseOperation * seahorse_source_search (SeahorseSource *sksrc
,const gchar *match
); SeahorseOperation * seahorse_source_import (SeahorseSource *sksrc
,GInputStream *input
); gboolean seahorse_source_import_sync (SeahorseSource *sksrc
,GInputStream *input
,GError **err
); SeahorseOperation * seahorse_source_export_objects (GList *objects
,GOutputStream *output
); SeahorseOperation * seahorse_source_delete_objects (GList *objects
); SeahorseOperation * seahorse_source_export (SeahorseSource *sksrc
,GList *objects
,GOutputStream *output
); SeahorseOperation * seahorse_source_export_raw (SeahorseSource *sksrc
,GSList *ids
,GOutputStream *output
); GQuark seahorse_source_get_tag (SeahorseSource *sksrc
); SeahorseLocation seahorse_source_get_location (SeahorseSource *sksrc
);
Details
SEAHORSE_SOURCE_GET_INTERFACE()
#define SEAHORSE_SOURCE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), SEAHORSE_TYPE_SOURCE, SeahorseSourceIface))
struct SeahorseSourceIface
struct SeahorseSourceIface { GTypeInterface parent; /* virtual methods ------------------------------------------------- */ /** * load * @sksrc: The #SeahorseSource. * * Loads the requested objects, and add the objects to SeahorseContext. * * Returns: The load operation. */ SeahorseOperation* (*load) (SeahorseSource *sksrc); /** * search * @sksrc: The #SeahorseSource * @match: Match text * * Searches for objects in the source. * * Returns: The search operation. */ SeahorseOperation* (*search) (SeahorseSource *sksrc, const gchar *match); /** * import * @sksrc: The #SeahorseSource to import into. * @input: The data to import. * * Import objects into the source. When operation is 'done' a GList of * updated objects may be found as the operation result. * * Returns: The import operation */ SeahorseOperation* (*import) (SeahorseSource *sksrc, GInputStream *input); /** * export * @sksrc: The #SeahorseSource to export from. * @objects: A list of objects to export. * @output: Output stream to export to. * * Import objects into the object source. When operation is 'done' the result * of the operation will be a GOutputStream * * Returns: The export operation */ SeahorseOperation* (*export) (SeahorseSource *sksrc, GList *objects, GOutputStream *output); /** * export_raw * @sksrc: The #SeahorseSource to export from. * @ids: A list of ids to export. * @data: output stream to export to. * * Import objects into the source. When operation is 'done' the result * of the operation will be a GOutputStream * * Returns: The export operation */ SeahorseOperation* (*export_raw) (SeahorseSource *sksrc, GSList *ids, GOutputStream *output); };
seahorse_source_load ()
SeahorseOperation * seahorse_source_load (SeahorseSource *sksrc
);
Refreshes the SeahorseSource's internal object listing.
|
A SeahorseSource object |
Returns : |
the asynchronous refresh operation. |
seahorse_source_load_sync ()
void seahorse_source_load_sync (SeahorseSource *sksrc
);
Refreshes the SeahorseSource's internal object listing. Completes in the background.
|
A SeahorseSource object |
seahorse_source_search ()
SeahorseOperation * seahorse_source_search (SeahorseSource *sksrc
,const gchar *match
);
Refreshes the SeahorseSource's internal listing.
|
A SeahorseSource object |
|
Text to search for |
Returns : |
the asynchronous refresh operation. |
seahorse_source_import ()
SeahorseOperation * seahorse_source_import (SeahorseSource *sksrc
,GInputStream *input
);
Imports data from the stream
|
A SeahorseSource object |
|
A stream of data to import |
Returns : |
the asynchronous import operation |
seahorse_source_import_sync ()
gboolean seahorse_source_import_sync (SeahorseSource *sksrc
,GInputStream *input
,GError **err
);
Imports data from the stream
|
The SeahorseSource |
|
the input data |
|
error |
Returns : |
Imports the stream, synchronous |
seahorse_source_export_objects ()
SeahorseOperation * seahorse_source_export_objects (GList *objects
,GOutputStream *output
);
Exports objects. The objects are sorted by source.
|
The objects to export |
|
The output stream to export the objects to |
Returns : |
The SeahorseOperation created to export the data |
seahorse_source_delete_objects ()
SeahorseOperation * seahorse_source_delete_objects (GList *objects
);
Deletes a list of objects
|
A list of objects to delete |
Returns : |
The SeahorseOperation to delete the objects |
seahorse_source_export ()
SeahorseOperation * seahorse_source_export (SeahorseSource *sksrc
,GList *objects
,GOutputStream *output
);
|
The SeahorseSource |
|
The objects to export |
|
The resulting output stream |
Returns : |
An export Operation (SeahorseOperation) |
seahorse_source_export_raw ()
SeahorseOperation * seahorse_source_export_raw (SeahorseSource *sksrc
,GSList *ids
,GOutputStream *output
);
|
The SeahorseSource |
|
A list of IDs to export |
|
The resulting output stream |
Returns : |
An export Operation (SeahorseOperation) |
seahorse_source_get_tag ()
GQuark seahorse_source_get_tag (SeahorseSource *sksrc
);
|
The seahorse source object |
Returns : |
The source-tag property of the object. As GQuark |
seahorse_source_get_location ()
SeahorseLocation seahorse_source_get_location (SeahorseSource *sksrc
);
|
The seahorse source object |
Returns : |
The location (SeahorseLocation) of this object |