| Package | Description |
|---|---|
| ai.grakn |
A core package for connecting to a Grakn knowledge graph.
|
| ai.grakn.concept |
Provides the meta-ontology interfaces and definitions.
|
| ai.grakn.exception |
Grakn exception definitions.
|
| ai.grakn.factory |
Provides graph accessors for different backends.
|
| Modifier and Type | Method and Description |
|---|---|
void |
GraknSession.close()
Closes the main connection to the graph.
|
| Modifier and Type | Method and Description |
|---|---|
void |
Concept.delete()
Delete the Concept.
|
Type |
Type.key(ResourceType resourceType)
Creates a RelationType which allows this type and a resource type to be linked in a strictly one-to-one mapping.
|
Type |
Type.plays(Role role) |
Type |
Type.resource(ResourceType resourceType)
Creates a RelationType which allows this type and a resource type to be linked.
|
Type |
Type.setAbstract(Boolean isAbstract)
Sets the Entity Type to be abstract - which prevents it from having any instances.
|
| Modifier and Type | Class and Description |
|---|---|
class |
PropertyNotUniqueException
Unique Concept Property Violation
|
| Modifier and Type | Method and Description |
|---|---|
static GraphOperationException |
GraphOperationException.addingInstancesToAbstractType(Type type)
Throw when trying to add instances to an abstract Type
|
static GraphOperationException |
GraphOperationException.closingGraphFailed(GraknGraph graph,
Exception e)
Thrown when the graph can not be closed due to an unknown reason.
|
static GraphOperationException |
GraphOperationException.duplicateHas(Type type,
ResourceType resourceType)
|
static GraphOperationException |
GraphOperationException.hasNotAllowed(Thing thing,
Resource resource,
String hasType)
Thrown when an
thing is not allowed to have resource of the type hasType. |
static GraphOperationException |
GraphOperationException.immutableProperty(Object oldValue,
Object newValue,
Schema.VertexProperty vertexProperty)
Thrown when attempting to mutate a property which is immutable
|
static GraphOperationException |
GraphOperationException.invalidCasting(Object concept,
Class type)
Thrown when casting concepts incorrectly.
|
static GraphOperationException |
GraphOperationException.invalidDirection(org.apache.tinkerpop.gremlin.structure.Direction direction)
Thrown when attempting to traverse an edge in an invalid direction
|
static GraphOperationException |
GraphOperationException.invalidGraphConfig(String pathToFile)
Thrown when attempting to read a config file which cannot be accessed
|
static GraphOperationException |
GraphOperationException.invalidPlays(Role role)
Thrown when a
Type cannot play a specific role type. |
static GraphOperationException |
GraphOperationException.invalidResourceValue(Object object,
ResourceType.DataType dataType)
Thrown when creating a resource whose value
object does not match it's resource's dataType. |
static GraphOperationException |
GraphOperationException.loopCreated(OntologyConcept type,
OntologyConcept superElement)
Thrown when setting
superType as the super type of type and a loop is created |
static GraphOperationException |
GraphOperationException.metaTypeImmutable(Label metaLabel)
Thrown when attempting to mutate a
Schema.MetaSchema |
static GraphOperationException |
GraphOperationException.noType(Thing thing)
Thrown when an thing does not have a type
|
static GraphOperationException |
GraphOperationException.nullKeyspace()
Thrown when trying to make the keysoace null
|
static GraphOperationException |
GraphOperationException.ontologyMutation()
Thrown when attempting to mutate the ontology while the transaction is in batch mode
|
static GraphOperationException |
GraphOperationException.regexFailure(Resource resource,
String value,
String regex)
Thrown when trying to set a
value on the resource which does not conform to it's regex |
static GraphOperationException |
GraphOperationException.reservedLabel(Label label)
Thrown when trying to create something using a label reserved by the system
|
static GraphOperationException |
GraphOperationException.settingNullProperty(Schema.VertexProperty property)
Thrown when attempting to set a property to null
|
static GraphOperationException |
GraphOperationException.transactionClosed(GraknGraph graph,
String reason)
Thrown when attempting to use the graph when the transaction is closed
|
static GraphOperationException |
GraphOperationException.transactionInvalid(Object tx)
Thrown when attempting to open an invalid type of transaction
|
static GraphOperationException |
GraphOperationException.transactionOpen(GraknGraph graph)
Thrown when attempting to open a transaction which is already open
|
static GraphOperationException |
GraphOperationException.transactionReadOnly(GraknGraph graph)
Thrown when attempting to mutate a read only transaction
|
static GraphOperationException |
GraphOperationException.typeCannotBeDeleted(Label label)
Thrown when a
Type has incoming edges and therefore cannot be deleted |
static GraphOperationException |
GraphOperationException.unsupportedDataType(Object value)
Thrown when using an unsupported datatype with resources
|
static GraphOperationException |
GraphOperationException.versionMistmatch(Resource versionResource)
Thrown when using incompatible versions of Grakn
|
| Modifier and Type | Method and Description |
|---|---|
void |
GraknSessionImpl.close() |
Copyright © 2017 Grakn Labs Ltd. All rights reserved.