|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.topbraid.sparqlmotion.util.AbstractSMGraphStore
public abstract class AbstractSMGraphStore
A generic IGraphStore implementation that operates on SparqlMotion modules. The module must be stored in the config file in N3 format. When opened, this graph store uses the first instance of a given SparqlMotion module type. The URI of that resource is the base URI of the resulting graph.
| Constructor Summary | |
|---|---|
AbstractSMGraphStore(com.hp.hpl.jena.rdf.model.Resource moduleType,
boolean buffering)
|
|
| Method Summary | |
|---|---|
void |
close(org.eclipse.core.resources.IFile file)
Closes any resources allocated by a given file. |
java.net.URI |
getBaseURI(org.eclipse.core.resources.IFile file,
java.util.Set<java.net.URI> imports)
Gets the declared base URI and the owl:imports of a given file. |
protected com.hp.hpl.jena.rdf.model.Resource |
getConfig(org.eclipse.core.resources.IFile file)
|
java.lang.String[] |
getFileExtensions()
Returns an (optional) array of file extensions that this graph store can handle. |
com.hp.hpl.jena.graph.Graph |
getGraph(org.eclipse.core.resources.IFile file,
org.eclipse.core.runtime.IProgressMonitor monitor)
|
ImageMetadata |
getImageMetadata()
Gets a (base) image to display files of this type in the Navigator (and potentially elsewhere). |
boolean |
isReadOnly(org.eclipse.core.resources.IFile file)
Checks if a given IFile is read-only. |
com.hp.hpl.jena.graph.Graph |
load(org.eclipse.core.resources.IFile file,
org.eclipse.core.runtime.IProgressMonitor monitor)
Creates a new Jena Graph for a given IFile. |
void |
save(org.eclipse.core.resources.IFile file,
com.hp.hpl.jena.graph.Graph graph,
java.lang.String baseURI)
|
boolean |
saveAs(org.eclipse.core.resources.IFile file,
com.hp.hpl.jena.graph.Graph graph,
java.lang.String baseURI)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractSMGraphStore(com.hp.hpl.jena.rdf.model.Resource moduleType,
boolean buffering)
| Method Detail |
|---|
public void close(org.eclipse.core.resources.IFile file)
throws java.lang.Exception
IGraphStore
close in interface IGraphStorefile - the file representing the store
java.lang.Exception
public java.net.URI getBaseURI(org.eclipse.core.resources.IFile file,
java.util.Set<java.net.URI> imports)
throws java.lang.Exception
IGraphStore
getBaseURI in interface IGraphStorefile - the file to get the base URI ofimports - an initially empty Set that will contain imported URIs
java.lang.Exception
protected com.hp.hpl.jena.rdf.model.Resource getConfig(org.eclipse.core.resources.IFile file)
throws java.lang.Exception
java.lang.Exceptionpublic java.lang.String[] getFileExtensions()
IGraphStore
getFileExtensions in interface IGraphStore
public com.hp.hpl.jena.graph.Graph getGraph(org.eclipse.core.resources.IFile file,
org.eclipse.core.runtime.IProgressMonitor monitor)
throws java.lang.Throwable
java.lang.Throwablepublic ImageMetadata getImageMetadata()
IGraphStore
getImageMetadata in interface IGraphStorepublic boolean isReadOnly(org.eclipse.core.resources.IFile file)
IGraphStore
isReadOnly in interface IGraphStore
public com.hp.hpl.jena.graph.Graph load(org.eclipse.core.resources.IFile file,
org.eclipse.core.runtime.IProgressMonitor monitor)
throws java.lang.Exception
IGraphStore
load in interface IGraphStorefile - the file to loadmonitor - the monitor for status reports or null
java.lang.Exception - if something went wrong
public void save(org.eclipse.core.resources.IFile file,
com.hp.hpl.jena.graph.Graph graph,
java.lang.String baseURI)
throws java.io.IOException
save in interface IGraphStorejava.io.IOException
public boolean saveAs(org.eclipse.core.resources.IFile file,
com.hp.hpl.jena.graph.Graph graph,
java.lang.String baseURI)
throws java.lang.Exception
saveAs in interface IGraphStorejava.lang.Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||