|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface SourceReader
Returns trees and node from a data source.
Trees and nodes are expected to conform to the 'data type' of the source.
Source.reader(),
Tree,
Pattern| Method Summary | |
|---|---|
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> |
get(org.gcube.data.trees.patterns.Pattern pattern)
Returns all the trees in the source which match a given pattern, after pruning them with it. |
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> |
get(org.gcube.data.streams.Stream<String> idStream,
org.gcube.data.trees.patterns.Pattern pattern)
Returns trees in the source with given identifiers, after pruning them with a given pattern. |
org.gcube.data.trees.data.Tree |
get(String id,
org.gcube.data.trees.patterns.Pattern pattern)
Returns a tree in the source with a given identifier, after pruning it with a given pattern. |
org.gcube.data.trees.data.Node |
getNode(String... path)
Returns a tree node in the source from the path of identifiers which connects it to the root of the tree. |
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Node> |
getNodes(org.gcube.data.streams.Stream<Path> pathStream)
Returns tree nodes in the source from the paths of identifiers which connect them to the roots of the trees. |
| Method Detail |
|---|
org.gcube.data.trees.data.Tree get(String id,
org.gcube.data.trees.patterns.Pattern pattern)
throws UnsupportedOperationException,
UnsupportedRequestException,
UnknownTreeException,
InvalidTreeException,
Exception
id - the identifierpattern - the pattern
UnknownTreeException - if the source does not contain a tree with the given
identifier
InvalidTreeException - if the Tree with the the given identifier does not
match the Pattern
UnsupportedOperationException - if the data source does not support this operation
Exception - if the operation fails for any other error
UnsupportedRequestException
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> get(org.gcube.data.streams.Stream<String> idStream,
org.gcube.data.trees.patterns.Pattern pattern)
throws UnsupportedOperationException,
UnsupportedRequestException,
Exception
idStream - a stream of tree identifierspattern - the pattern
UnsupportedOperationException - if the data source does not support this operation
Exception - if the operation fails for an unexpected error
UnsupportedRequestException
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Tree> get(org.gcube.data.trees.patterns.Pattern pattern)
throws UnsupportedOperationException,
UnsupportedRequestException,
Exception
pattern - the pattern
UnsupportedOperationException - if the data source does not support this operation
UnsupportedRequestException - if the data source does not support this request
Exception - if the operation fails for an unexpected error
org.gcube.data.trees.data.Node getNode(String... path)
throws UnsupportedOperationException,
UnknownPathException,
UnsupportedRequestException,
Exception
path - the identifiers
UnknownPathException - if the path does not lead to a node
UnsupportedOperationException - if the data source does not support this operation
UnsupportedRequestException - if the data source does not support this request
Exception - if the operation fails for any other error
org.gcube.data.streams.Stream<org.gcube.data.trees.data.Node> getNodes(org.gcube.data.streams.Stream<Path> pathStream)
throws UnsupportedOperationException,
Exception
pathStream - a stream of paths to the nodes
UnsupportedOperationException - if the data source does not support this operation
UnsupportedRequestException - if the data source does not support this request
Exception - if the operation fails for an unexpected error
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||