graql-0.1.1: Execute Graql queries on a Grakn graph

Safe HaskellNone
LanguageHaskell2010

Graql

Synopsis

Documentation

data MatchQuery Source #

A Graql match query that finds a pattern in the graph

data Var Source #

A variable name wildcard that will represent a concept in the results

Instances

data Name Source #

A name of something in the graph

match :: IsPattern a => [a] -> MatchQuery Source #

Create a match query by providing a list of patterns

select :: [Var] -> MatchQuery -> MatchQuery Source #

Select variables from a match query, intended to be used infix

distinct :: MatchQuery -> MatchQuery Source #

Retrieve only distinct results from a match query

limit :: Integer -> MatchQuery -> MatchQuery Source #

Limit a match query, intended to be used infix

var :: Text -> Var Source #

Create a variable

name :: Text -> Name Source #

Create a name of something in the graph

isa :: (IsPattern p, IsVarOrName a) => p -> a -> Pattern Source #

Specify a property has a particular type

(-:) :: (IsPattern p, IsVarOrName a) => p -> a -> Pattern Source #

Specify a property has a particular type

(.:) :: IsVarOrName a => a -> Var -> RolePlayer Source #

A casting in a relation between a role type and a role player

rp :: Var -> RolePlayer Source #

A casting in a relation without a role type

(<:) :: (IsPattern p, IsRolePlayer a) => p -> [a] -> Pattern Source #

Specify a property is a relation between other variables

rel :: IsRolePlayer a => [a] -> Pattern Source #

Shorthand to define a relation

has :: (IsPattern p, IsResource a) => p -> Name -> a -> Pattern Source #

Specify a property has a resource

hasText :: IsPattern p => p -> Name -> Text -> Pattern Source #

Specify a property has a resource

var_ :: Pattern Source #

Create an anonymous variable