Bolt.Sips v0.2.1 Bolt.Sips.Response

Support for transforming a Bolt response to a list of Bolt.Sips.Types or arbitrary values.

For example, a simple Cypher query like this:

RETURN [10,11,21] AS arr

will return: %{"arr" => [10,11,21]}, while a more complex one, say:

MATCH p=({name:'Alice'})-[r:KNOWS]->({name:'Bob'}) RETURN r

will return the following list:

[%{"r" => %Bolt.Sips.Types.Relationship{end: 647, id: 495,
 properties: %{}, start: 646, type: "KNOWS"}}]

Please check the Bolt.Sips.Types module for the structures supporting the Neo4j entities.

Briefly, the entities implemented so far are:

  • Node
  • Relationship
  • UnboundRelationship
  • Path

Note: the Path has also functionality for “drawing” a graph, from a given node-relationship path

Summary

Functions

transform a raw Bolt response to a list of Responses

Types

t()
t() :: Bolt.Sips.Response

Functions

transform(raw, stats \\ :no)

transform a raw Bolt response to a list of Responses

todo: is this the best place for hooking in the stats, if any?