Package org.aksw.jenax.graphql.json.api
Interface GraphQlDataProvider
- All Known Implementing Classes:
GraphQlDataProviderBase,GraphQlDataProviderMaterialize,GraphQlDataProviderOverRdf,GraphQlDataProviderWrapperBase
public interface GraphQlDataProvider
-
Method Summary
Modifier and TypeMethodDescriptioncom.google.gson.JsonObjectMetadata for this stream.getName()The name of the provider.booleanisSingle()Whether this provider is expected to yield at most 1 result.Stream<com.google.gson.JsonElement>A stream over the resulting items.voidwrite(com.google.gson.stream.JsonWriter writer, com.google.gson.Gson gson) Write the data of this provider to the given json writer
-
Method Details
-
getName
String getName()The name of the provider. Usable as a key in the JSON result. -
getMetadata
com.google.gson.JsonObject getMetadata()Metadata for this stream. -
openStream
Stream<com.google.gson.JsonElement> openStream()A stream over the resulting items. -
isSingle
boolean isSingle()Whether this provider is expected to yield at most 1 result. The client can use this information to e.g. omit starting an array in the output. However, the data provider does not necessarily know whether this information is truthful. If a violation is encountered during runtime then an exception will be raised. -
write
Write the data of this provider to the given json writer- Throws:
IOException
-