| Package | Description |
|---|---|
| ai.grakn | |
| ai.grakn.concept | |
| ai.grakn.graph.internal | |
| ai.grakn.graql.internal.reasoner | |
| ai.grakn.migration.owl |
| Modifier and Type | Method and Description |
|---|---|
RelationType |
GraknAdmin.getMetaRelationType()
Get the root of all Relation Types.
|
RelationType |
GraknGraph.getRelationType(String name)
Get the Relation Type with the name provided, if it exists.
|
RelationType |
GraknGraph.putRelationType(String name)
Create a Relation Type, or return a pre-existing Relation Type, with the specified name.
|
| Modifier and Type | Method and Description |
|---|---|
Relation |
GraknGraph.getRelation(RelationType relationType,
Map<RoleType,Instance> roleMap)
Get a collection of Relations that match the specified Relation Type and role map, if it exists.
|
| Modifier and Type | Method and Description |
|---|---|
RelationType |
Concept.asRelationType()
Return as a Relation Type if the concept is a Relation Type.
|
RelationType |
RelationType.deleteHasRole(RoleType roleType)
Delete a RoleType from this RelationType
|
RelationType |
RelationType.deletePlaysRole(RoleType roleType)
Removes the RoleType to prevent instances of this RelationType from playing it.
|
RelationType |
Type.hasResource(ResourceType resourceType)
Creates a RelationType which allows this type and a resource type to be linked.
|
RelationType |
RelationType.hasRole(RoleType roleType)
Sets a new RoleType for this RelationType.
|
RelationType |
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.
|
RelationType |
RelationType.playsRole(RoleType roleType)
Sets the RoleType which instances of this RelationType may play.
|
RelationType |
RelationType.setAbstract(Boolean isAbstract)
Sets the RelationType to be abstract - which prevents it from having any instances.
|
RelationType |
RelationType.superType()
Returns the supertype of this RelationType.
|
RelationType |
RelationType.superType(RelationType type)
Sets the supertype of the RelationType to be the EntityType specified.
|
RelationType |
Relation.type()
Retrieve the associated Relation Type for this Relation.
|
| Modifier and Type | Method and Description |
|---|---|
Collection<RelationType> |
RoleType.relationTypes()
Returns the RelationTypes that this RoleType takes part in.
|
Collection<RelationType> |
RelationType.subTypes()
Returns a collection of subtypes of this RelationType.
|
| Modifier and Type | Method and Description |
|---|---|
RelationType |
RelationType.superType(RelationType type)
Sets the supertype of the RelationType to be the EntityType specified.
|
| Modifier and Type | Method and Description |
|---|---|
RelationType |
AbstractGraknGraph.getMetaRelationType() |
RelationType |
AbstractGraknGraph.getRelationType(String name) |
RelationType |
AbstractGraknGraph.putRelationType(String name) |
| Modifier and Type | Method and Description |
|---|---|
Relation |
AbstractGraknGraph.getRelation(RelationType relationType,
Map<RoleType,Instance> roleMap) |
| Modifier and Type | Field and Description |
|---|---|
static java.util.function.Function<RoleType,Set<RelationType>> |
Utility.roleToRelationTypes |
static java.util.function.Function<Type,Set<RelationType>> |
Utility.typeToRelationTypes |
| Modifier and Type | Method and Description |
|---|---|
static <T extends Type> |
Utility.getCompatibleRelationTypes(Set<T> types,
java.util.function.Function<T,Set<RelationType>> typeMapper) |
| Modifier and Type | Method and Description |
|---|---|
static Rule |
Utility.createPropertyChainRule(RelationType relation,
String fromRoleName,
String toRoleName,
LinkedHashMap<RelationType,javafx.util.Pair<String,String>> chain,
GraknGraph graph)
creates rule R(fromRole: x, toRole: xm) :- R1(fromRole: x, ...), , R2, ...
|
static Rule |
Utility.createReflexiveRule(RelationType relType,
GraknGraph graph)
create reflexive rule R(from: X, to: X) :- R(from: X,to: Y)
|
static Rule |
Utility.createSubPropertyRule(RelationType parent,
RelationType child,
Map<String,String> roleMappings,
GraknGraph graph)
creates rule parent :- child
|
static Rule |
Utility.createTransitiveRule(RelationType relType,
String fromRoleName,
String toRoleName,
GraknGraph graph)
create transitive rule R(from: X, to: Y) :- R(from: X,to: Z), R(from: Z, to: Y)
|
| Modifier and Type | Method and Description |
|---|---|
static Rule |
Utility.createPropertyChainRule(RelationType relation,
String fromRoleName,
String toRoleName,
LinkedHashMap<RelationType,javafx.util.Pair<String,String>> chain,
GraknGraph graph)
creates rule R(fromRole: x, toRole: xm) :- R1(fromRole: x, ...), , R2, ...
|
static <T extends Type> |
Utility.getCompatibleRelationTypes(Set<T> types,
java.util.function.Function<T,Set<RelationType>> typeMapper) |
| Modifier and Type | Method and Description |
|---|---|
RelationType |
OWLMigrator.relation(org.semanticweb.owlapi.model.OWLAnnotationProperty property) |
RelationType |
OWLMigrator.relation(org.semanticweb.owlapi.model.OWLDataProperty property) |
RelationType |
OWLMigrator.relation(org.semanticweb.owlapi.model.OWLObjectProperty property) |
| Modifier and Type | Method and Description |
|---|---|
RoleType |
OWLMigrator.objectRole(RelationType relType) |
RoleType |
OWLMigrator.subjectRole(RelationType relType) |
Copyright © 2017 Grakn Labs Ltd. All rights reserved.