Documentation ¶
Index ¶
- Constants
- func AddNode(identifier string, node []byte, database ...string) (int64, error)
- func AddNodes(identifiers []string, nodes [][]byte, database ...string) (int64, error)
- func BulkConnectNodes(sources []string, targets []string, database ...string) (int64, error)
- func BulkConnectNodesWithProperties(sources []string, targets []string, properties []string, database ...string) (int64, error)
- func ConnectNodes(sourceId string, targetId string, database ...string) (int64, error)
- func ConnectNodesWithProperties(sourceId string, targetId string, properties []byte, database ...string) (int64, error)
- func FindNode(identifier string, database ...string) (string, error)
- func FindNodes(properties map[string]string, startsWith bool, contains bool, ...) ([]string, error)
- func Initialize(database ...string)
- func RemoveNodes(identifiers []string, database ...string) bool
- func TraverseFrom(source string, traversal string, database ...string) ([]string, error)
- func TraverseFromTo(source string, target string, traversal string, database ...string) ([]string, error)
- func UpdateNodeBody(identifier string, body string, database ...string) error
- func UpsertNode(identifier string, body string, database ...string) error
- func Visualize(path []string, database ...string) string
- func VisualizeBodies(path []GraphData, database ...string) string
- type EdgeData
- type EdgeSet
- type GraphData
- type NodeData
Constants ¶
View Source
const ( DeleteEdge = `DELETE FROM edges WHERE source = ? OR target = ? ` DeleteNode = `DELETE FROM nodes WHERE id = ? ` InsertEdge = `INSERT INTO edges VALUES(?, ?, json(?)) ` InsertNode = `INSERT INTO nodes VALUES(json(?)) ` Schema = `` /* 495-byte string literal not displayed */ SearchEdgesInbound = `SELECT * FROM edges WHERE source = ? ` SearchEdgesOutbound = `SELECT * FROM edges WHERE target = ? ` SearchEdges = `SELECT * FROM edges WHERE source = ? UNION SELECT * FROM edges WHERE target = ? ` SearchNodeById = `SELECT body FROM nodes WHERE id = ? ` SearchNode = `SELECT body FROM nodes WHERE ` TraverseInbound = `` /* 135-byte string literal not displayed */ TraverseOutbound = `` /* 135-byte string literal not displayed */ Traverse = `` /* 199-byte string literal not displayed */ TraverseWithBodiesInbound = `` /* 245-byte string literal not displayed */ TraverseWithBodiesOutbound = `` /* 245-byte string literal not displayed */ TraverseWithBodies = `` /* 326-byte string literal not displayed */ UpdateNode = `UPDATE nodes SET body = json(?) WHERE id = ? ` )
View Source
const ( SQLITE = "sqlite3" WITH_FOREIGN_KEY_PRAGMA = "%s?_foreign_keys=true" ID_CONSTRAINT = "NOT NULL constraint failed: nodes.id" UNIQUE_ID_CONSTRAINT = "UNIQUE constraint failed: nodes.id" NO_ROWS_FOUND = "sql: no rows in result set" )
Variables ¶
This section is empty.
Functions ¶
func BulkConnectNodes ¶
func ConnectNodes ¶
func Initialize ¶
func Initialize(database ...string)
func RemoveNodes ¶
func TraverseFrom ¶
func TraverseFromTo ¶
func VisualizeBodies ¶
Types ¶
type EdgeSet ¶
type EdgeSet struct {
// contains filtered or unexported fields
}
func NewEdgeSet ¶
func NewEdgeSet() *EdgeSet
type GraphData ¶
func TraverseWithBodiesFrom ¶
Click to show internal directories.
Click to hide internal directories.