public interface GraknAdmin
GraknGraph.| Modifier and Type | Method and Description |
|---|---|
<T extends Concept> |
buildConcept(org.apache.tinkerpop.gremlin.structure.Vertex vertex) |
void |
closeSession()
Closes the root session this graph stems from.
|
Optional<String> |
commitNoLogs()
Commits to the graph without submitting any commit logs.
|
LabelId |
convertToId(Label label)
Converts a Type Label into a type Id for this specific graph.
|
void |
delete()
Immediately closes the session and deletes the graph.
|
boolean |
duplicateResourcesExist(String index,
Set<ConceptId> resourceVertexIds)
Check if there are duplicate resources in the provided set of vertex IDs
|
boolean |
fixDuplicateResources(String index,
Set<ConceptId> resourceVertexIds)
Merges the provided duplicate resources
|
<T extends Concept> |
getConcept(Schema.VertexProperty key,
Object value) |
OntologyConcept |
getMetaConcept()
Get the root of all Types.
|
EntityType |
getMetaEntityType()
Get the root of all the Entity Types.
|
RelationType |
getMetaRelationType()
Get the root of all Relation Types.
|
ResourceType |
getMetaResourceType()
Get the root of all the Resource Types.
|
Role |
getMetaRoleType()
Get the root of all the Role Types.
|
RuleType |
getMetaRuleConstraint()
Get the root of all constraint rules.
|
RuleType |
getMetaRuleInference()
Get the root of all inference rules.
|
RuleType |
getMetaRuleType()
Get the root of all Rule Types;
|
org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal<org.apache.tinkerpop.gremlin.structure.Vertex,org.apache.tinkerpop.gremlin.structure.Vertex> |
getTinkerTraversal()
Utility function to get a read-only Tinkerpop traversal.
|
boolean |
isBatchGraph()
A flag to check if batch loading is enabled and consistency checks are switched off
|
void |
shard(ConceptId conceptId)
Creates a new shard for the concept
|
void |
updateConceptCounts(Map<ConceptId,Long> conceptCounts)
Updates the counts of all the types
|
@CheckReturnValue <T extends Concept> T buildConcept(org.apache.tinkerpop.gremlin.structure.Vertex vertex)
T - The type of the concept being builtvertex - A vertex which contains properties necessary to build a concept from.@CheckReturnValue org.apache.tinkerpop.gremlin.process.traversal.dsl.graph.GraphTraversal<org.apache.tinkerpop.gremlin.structure.Vertex,org.apache.tinkerpop.gremlin.structure.Vertex> getTinkerTraversal()
@CheckReturnValue boolean isBatchGraph()
@CheckReturnValue OntologyConcept getMetaConcept()
@CheckReturnValue RelationType getMetaRelationType()
@CheckReturnValue Role getMetaRoleType()
@CheckReturnValue ResourceType getMetaResourceType()
@CheckReturnValue EntityType getMetaEntityType()
@CheckReturnValue RuleType getMetaRuleType()
@CheckReturnValue RuleType getMetaRuleInference()
@CheckReturnValue RuleType getMetaRuleConstraint()
@CheckReturnValue LabelId convertToId(Label label)
label - The label to be converted to the idOptional<String> commitNoLogs() throws InvalidGraphException
InvalidGraphException - when the graph does not conform to the object conceptboolean duplicateResourcesExist(String index, Set<ConceptId> resourceVertexIds)
index - index of the resource to find duplicates ofresourceVertexIds - vertex Ids containing potential duplicatesboolean fixDuplicateResources(String index, Set<ConceptId> resourceVertexIds)
resourceVertexIds - The resource vertex ids which need to be merged.void updateConceptCounts(Map<ConceptId,Long> conceptCounts)
conceptCounts - The concepts and the changes to put on their countsvoid shard(ConceptId conceptId)
conceptId - the id of the concept to shard@CheckReturnValue <T extends Concept> T getConcept(Schema.VertexProperty key, Object value)
key - The concept property tp search by.value - The value of the conceptvoid closeSession()
void delete()
Copyright © 2017 Grakn Labs Ltd. All rights reserved.