PyOpenWorm.command module¶
-
class
PyOpenWorm.command.POW[source]¶ Bases:
objectAttributes set on this object parameterize commands, but they are not to be changed by the commands
-
add_graph(url=None, context=None, include_imports=True)[source]¶ Fetch a graph and add it to the local store.
Parameters: - url : str
The URL of the graph to fetch
- context : rdflib.term.URIRef
If provided, only this context and, optionally, its imported graphs will be added.
- include_imports : bool
If True, imports of the named context will be included. Has no effect if context is None.
-
clone(url=None, update_existing_config=False)[source]¶ Clone a data store
Parameters: - url : str
URL of the data store to clone
-
init(update_existing_config=False)[source]¶ Makes a new graph store.
The configuration file will be created if it does not exist. If it does exist, the location of the database store will, by default, not be changed in that file
Parameters: - update_existing_config : bool
If True, updates the existing config file to point to the given file for the store configuration
-
reconstitute(data_source)[source]¶ Recreate a data source by executing the chain of translators that went into making it.
-
translate(translator, output_key=None, *data_sources, **named_data_sources)[source]¶ Do a translation with the named translator and inputs
-
config_file= None¶ The config file name
-
graph_accessor_finder= None¶ Callable that returns a graph accessor when given a URL for the graph
-
store_name= None¶ The file name of the database store
-