N
- The node class for this DataAccessorE
- The edge class for this DataAccessorpublic abstract class AbstractDataAccessor<N,E> extends java.lang.Object implements DataAccessor<N,E>
Constructor and Description |
---|
AbstractDataAccessor() |
Modifier and Type | Method and Description |
---|---|
protected void |
addStructure(DataStructureSpec spec)
Add a data structure specification to this accessor
|
protected void |
addTemplate(DataTemplate template)
Add a data template to this accessor.
|
java.util.Set<java.lang.String> |
getDatasetNames()
Get the names of the available datasets from this accessor.
|
java.util.Set<java.lang.String> |
getGraphNames()
Get the names of the available graphs from this accessor.
|
java.util.Set<java.lang.String> |
getGridNames()
Get the names of the available grids from this accessor.
|
DataStructureSpec |
getSpec(java.lang.String name)
Gets the named data structure specification.
|
DataStructureType |
getStructureType(java.lang.String dataName)
Get the data type for the specified dataName
|
DataTemplate |
getTemplate(java.lang.String name)
Gets the named DataTemplate.
|
java.util.Set<java.lang.String> |
getTemplateNames()
Get the names of all templates known by this accessor.
|
java.util.Set<java.lang.String> |
getTreeNames()
Get the names of the available trees from this accessor.
|
void |
setConfig(java.io.InputStream inStream)
Set the accessor data configuration information from an input stream.
|
void |
setConfigFile(java.lang.String configFile)
Set the configuration from a local file.
|
void |
setConfigFile(java.net.URL configUrl)
Set the configuration from a URL.
|
abstract void |
setQuery(java.lang.String query)
Set the query string used to retrieve records.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
extendGraph, extendTree, getDataset, getGraph, getGrid, getTree, setInitParameters
protected void addStructure(DataStructureSpec spec)
spec
- the new data structure specificationprotected void addTemplate(DataTemplate template)
template
- the template to addpublic java.util.Set<java.lang.String> getDatasetNames()
getDatasetNames
in interface DataAccessor<N,E>
public java.util.Set<java.lang.String> getGraphNames()
getGraphNames
in interface DataAccessor<N,E>
public java.util.Set<java.lang.String> getGridNames()
getGridNames
in interface DataAccessor<N,E>
public DataStructureSpec getSpec(java.lang.String name)
name
- the name of the data structure specificationpublic DataStructureType getStructureType(java.lang.String dataName)
getStructureType
in interface DataAccessor<N,E>
dataName
- the name of the data structurepublic DataTemplate getTemplate(java.lang.String name)
name
- the name of the data templatepublic java.util.Set<java.lang.String> getTemplateNames()
public java.util.Set<java.lang.String> getTreeNames()
getTreeNames
in interface DataAccessor<N,E>
public void setConfig(java.io.InputStream inStream)
setInitParameters
after loading all template and data
structure specifications.setConfig
in interface DataAccessor<N,E>
inStream
- Input stream which is the source of the configuration
informationpublic void setConfigFile(java.lang.String configFile) throws java.io.FileNotFoundException
setConfig(InputStream)
configFile
- The path to the configuration filejava.io.FileNotFoundException
- if the file is not foundpublic void setConfigFile(java.net.URL configUrl) throws java.io.IOException
setConfig(InputStream)
configUrl
- the configuration file as a URLjava.io.IOException
- if there is a problem opening or reading from the
URLpublic abstract void setQuery(java.lang.String query)
query
- the query string