Documentation
¶
Overview ¶
Package cypher generates Neo4j Cypher statements from graph data.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EdgeToCreate ¶
EdgeToCreate generates a CREATE statement for a single edge.
func EscapeString ¶
EscapeString escapes a string for use in Cypher queries.
func NodeToCreate ¶
NodeToCreate generates a CREATE statement for a single node.
func ToNeoLabel ¶
ToNeoLabel converts a graphize node type to a Neo4j label. Example: "function" -> "Function", "method_call" -> "MethodCall"
func ToNeoRelType ¶
ToNeoRelType converts a graphize edge type to a Neo4j relationship type. Neo4j relationship types are typically UPPERCASE.
Types ¶
type Generator ¶
type Generator struct {
// IncludeHeader adds usage comments at the top of the output.
IncludeHeader bool
// IncludeConstraint adds a UNIQUE constraint statement.
IncludeConstraint bool
}
Generator creates Neo4j Cypher CREATE statements from graph nodes and edges.
func NewGenerator ¶
func NewGenerator() *Generator
NewGenerator creates a Generator with default settings.
Click to show internal directories.
Click to hide internal directories.