|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface SpeciesStore
| Method Summary | |
|---|---|
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> |
add(org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> treeStream)
Adds many trees at once to the store. |
org.gcube.data.trees.data.Tree |
add(org.gcube.data.trees.data.Tree doc)
Adds a tree to the store. |
long |
cardinality()
Returns the cardinality of the store. |
void |
delete()
Deletes a store, stopping it if it has been started. |
Iterator<org.gcube.data.trees.data.Tree> |
get(org.gcube.data.trees.patterns.Pattern pattern)
Returns all the trees in the store which match a given pattern, after pruning them with it. |
org.gcube.data.trees.data.Tree |
get(String id,
org.gcube.data.trees.patterns.Pattern pattern)
Returns a tree in the store with a given identifier, after pruning it with a given pattern. |
String |
id()
Returns the store identifier. |
File |
location()
Returns the location of the store. |
void |
start(File storageLocation)
Starts the store in a given storage location, |
void |
stop()
Stops a started store. |
| Method Detail |
|---|
String id()
void start(File storageLocation)
storageLocation - the locationvoid stop()
void delete()
File location()
long cardinality()
org.gcube.data.trees.data.Tree get(String id,
org.gcube.data.trees.patterns.Pattern pattern)
throws org.gcube.data.tmf.api.exceptions.UnknownTreeException,
org.gcube.data.tmf.api.exceptions.InvalidTreeException,
Exception
id - the identifierpattern - the pattern
org.gcube.data.tmf.api.exceptions.UnknownTreeException - if the store does not contain a tree with the given identifier
org.gcube.data.tmf.api.exceptions.InvalidTreeException - if the Tree with the the given identifier does not match the Pattern
Exception - if the operation fails for any other error
Iterator<org.gcube.data.trees.data.Tree> get(org.gcube.data.trees.patterns.Pattern pattern)
throws Exception
pattern - the pattern
Exception - if the operation fails for an unexpected error
org.gcube.data.trees.data.Tree add(org.gcube.data.trees.data.Tree doc)
throws org.gcube.data.tmf.api.exceptions.InvalidTreeException
tree - the tree
org.gcube.data.tmf.api.exceptions.InvalidTreeException - if the tree does is invalid for addition (e.g. some of its nodes have already
identifiers)
UnsupportedOperationException - if the store does not support this operation
Exception - if the operation fails for any other reason
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> add(org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> treeStream)
throws Exception
treeStream - the stream of trees
Exception - if the operation fails as a whole for an unexpected error
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||