The surf.plugin.writer Module

class surf.plugin.writer.RDFWriter(reader, *args, **kwargs)[source]

Bases: surf.plugin.Plugin

Super class for all surf Writer plugins.

add_triple(s=None, p=None, o=None, context=None)[source]

Add a triple to the store, in the specified context.

None can be used as a wildcard.

clear(context=None)[source]

Remove all triples from the store.

If context is specified, only the specified context will be cleared.

close()[source]

Close the plugin.

enable_logging(enable=True)

Enables or disable logging for the current plugin.

index_triples(**kwargs)[source]

Perform index of the triples if such functionality is present.

Return True if operation successful.

is_enable_logging()

True if logging is enabled.

load_triples(**kwargs)[source]

Load triples from supported sources if such functionality is present.

Return True if operation successful.

remove(*resources, **kwargs)[source]

Completely remove the *resources from the store.

remove_triple(s=None, p=None, o=None, context=None)[source]

Remove a triple from the store, from the specified context.

None can be used as a wildcard.

save(*resources)[source]

Replace the *resources in store with their current state.

set_triple(s=None, p=None, o=None, context=None)[source]

Replace a triple in the store and specified context.

None can be used as a wildcard.

size()[source]

Return the number of triples in the current store.

update(*resources)[source]

Update the *resources to the store - persist.

Previous topic

The surf.plugin.query_reader Module

Next topic

The surf.query Module

This Page