Package com.complexible.stardog.graphql
Interface GraphQLSchemaManager
-
public interface GraphQLSchemaManager
Interface for the storage and retrieval of GraphQL schemas.
- Since:
- 5.1
- Version:
- 5.1
- Author:
- Evren Sirin
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DEFAULT_SCHEMA
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addSchema(java.lang.String name, graphql.schema.GraphQLSchema schema)
Adds a new GraphQLSchema to this databasevoid
clearSchemas()
Clears all schemasgraphql.schema.GraphQLSchema
getSchema(java.lang.String name)
Returns the schema with the given namejava.lang.Iterable<java.lang.String>
getSchemas()
Returns all the GraphQL schemas associated with this databasevoid
removeSchema(java.lang.String name)
Removes the specified schemavoid
updateSchema(java.lang.String name, graphql.schema.GraphQLSchema schema)
Updates an existing GraphQLSchema in the database, or adds the schema if an existing schema is not found.
-
-
-
Field Detail
-
DEFAULT_SCHEMA
static final java.lang.String DEFAULT_SCHEMA
- See Also:
- Constant Field Values
-
-
Method Detail
-
getSchema
graphql.schema.GraphQLSchema getSchema(java.lang.String name) throws StardogException
Returns the schema with the given name- Parameters:
name
- name of the schema- Returns:
- GraphQL schema
- Throws:
StardogException
-
getSchemas
java.lang.Iterable<java.lang.String> getSchemas() throws StardogException
Returns all the GraphQL schemas associated with this database- Returns:
- the schemas associated with this database
- Throws:
StardogException
- if there was an error getting the constraints
-
addSchema
void addSchema(java.lang.String name, graphql.schema.GraphQLSchema schema) throws StardogException
Adds a new GraphQLSchema to this database- Parameters:
name
- name of the schema to addschema
-- Throws:
StardogException
-
updateSchema
void updateSchema(java.lang.String name, graphql.schema.GraphQLSchema schema) throws StardogException
Updates an existing GraphQLSchema in the database, or adds the schema if an existing schema is not found.- Parameters:
name
- name of the schema to updateschema
- the next version of the schema- Throws:
StardogException
-
removeSchema
void removeSchema(java.lang.String name) throws StardogException
Removes the specified schema- Parameters:
name
- the name of the schema to remove- Throws:
StardogException
- if there was an error while removing
-
clearSchemas
void clearSchemas() throws StardogException
Clears all schemas- Throws:
StardogException
- if there was an error while clearing the schemas
-
-