orchestrate-0.2.0.2: An API client for http://orchestrate.io/.

Safe HaskellNone
LanguageHaskell2010

Database.Orchestrate.Graph

Description

This module implements the Graph API.

Synopsis

Documentation

getRel Source

Arguments

:: (OrchestrateData a, FromJSON b) 
=> a

The originating node.

-> RelKind

The first edge to traverse.

-> [RelKind]

Any additional edges to traverse.

-> OrchestrateIO (RelList a b)

A list of nodes originating from a.

This retrieves a list of target nodes from edges originating from a. For more information see the API documentation.

If the third parameter is not empty, it represents additional edges that will be traversed to get to the target.

For example:

getRel data "friend" ["last_name"]

createRel Source

Arguments

:: (OrchestrateData a, OrchestrateData b) 
=> a

The originating node.

-> RelKind

The label for the edge.

-> b

The target, destination node.

-> OrchestrateIO () 

Creates a relationship (an edge) between two nodes. The edge has a RelKind type. See the API documentation for more information.

For example:

createRel start "parent" child

deleteRel Source

Arguments

:: (OrchestrateData a, OrchestrateData b) 
=> a

The originating node.

-> RelKind

The label for the edge.

-> b

The target, destination node.

-> OrchestrateIO () 

This removes a relationship (an edge) between two nodes.

For example:

deleteRel start "parent" child