seahorse-source

seahorse-source — This class stores and handles key sources

Description

Details

SEAHORSE_SOURCE_GET_INTERFACE()

#define SEAHORSE_SOURCE_GET_INTERFACE(obj)  (G_TYPE_INSTANCE_GET_INTERFACE ((obj), SEAHORSE_TYPE_SOURCE, SeahorseSourceIface))


SeahorseSource

typedef struct _SeahorseSource SeahorseSource;


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.

sksrc :

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.

sksrc :

A SeahorseSource object

seahorse_source_load_async ()

void                seahorse_source_load_async          (SeahorseSource *sksrc);


seahorse_source_search ()

SeahorseOperation *   seahorse_source_search            (SeahorseSource *sksrc,
                                                         const gchar *match);

Refreshes the SeahorseSource's internal listing.

sksrc :

A SeahorseSource object

match :

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

sksrc :

A SeahorseSource object

input :

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

sksrc :

The SeahorseSource

input :

the input data

err :

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.

objects :

The objects to export

output :

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

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);

sksrc :

The SeahorseSource

objects :

The objects to export

output :

The resulting output stream

Returns :

An export Operation (SeahorseOperation)

seahorse_source_export_raw ()

SeahorseOperation *   seahorse_source_export_raw        (SeahorseSource *sksrc,
                                                         GSList *ids,
                                                         GOutputStream *output);

sksrc :

The SeahorseSource

ids :

A list of IDs to export

output :

The resulting output stream

Returns :

An export Operation (SeahorseOperation)

seahorse_source_get_tag ()

GQuark              seahorse_source_get_tag             (SeahorseSource *sksrc);

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);

sksrc :

The seahorse source object

Returns :

The location (SeahorseLocation) of this object