neo4j

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 13, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Overview

Package neo4j provides the model for Neo4j

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Driver

type Driver struct {
	// contains filtered or unexported fields
}

Driver for neo4j

func (Driver) DiscardQuery

func (d Driver) DiscardQuery(res dbms.QueryResult, seed *seed.Seed) bool

DiscardQuery returns true with probability 1/3 or if the query produced a non-nil error, else it returns false. Thereby causing queries to have an expected amount of 4 statements if they don't produce an error.

func (Driver) GetQueryResultType

func (d Driver) GetQueryResultType(res dbms.QueryResult, errorMessageRegex *dbms.ErrorMessageRegex) dbms.QueryResultType

GetQueryResultType evaluates the produced result and returns the type the result indicates.

func (Driver) GetSchema

func (d Driver) GetSchema(opts dbms.DBOptions) (*schema.Schema, error)

GetSchema returns the database's current schema

func (*Driver) Init

func (d *Driver) Init(opts dbms.DBOptions) error

Init the DB driver

func (Driver) IsEqualResult

func (d Driver) IsEqualResult(a, b dbms.QueryResult) bool

IsEqualResult returns true if the two passed query results hold the same information, else false.

func (Driver) IsMatchingRows

func (d Driver) IsMatchingRows(first, second any) bool

IsMatchingRows Compares the string representations of two neo4j result rows. It returns true if they match, else false.

func (*Driver) Reset

func (d *Driver) Reset(opts dbms.DBOptions) error

Reset the database

func (Driver) RunQuery

func (d Driver) RunQuery(opts dbms.DBOptions, query string) dbms.QueryResult

RunQuery runs the query against the Neo4j DB and returns its result.

func (Driver) VerifyConnectivity

func (d Driver) VerifyConnectivity(dbms.DBOptions) (bool, error)

VerifyConnectivity checks whether the DB is still reachable and hasn't crashed.

type Implementation

type Implementation struct{}

Implementation for Neo4j

func (Implementation) GetDropIns

func (Implementation) GetDropIns() translator.DropIns

GetDropIns returns the clause drop-ins for the Neo4j implementation

func (Implementation) GetOpenCypherConfig

func (Implementation) GetOpenCypherConfig() config.Config

GetOpenCypherConfig returns the generation config for the Neo4j implementation

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL