cypher-engine
Version:
Cypher Engine to generate Cypher queries
64 lines (63 loc) • 2.63 kB
TypeScript
import { ICypherFunction } from '../interfaces/ICypherFunction';
import { SetProperty } from '../models/SetProperty';
import { RelationshipDirection } from '../models/RelationshipDirection';
import { Property } from '../models/Property';
import { PathRange } from '../models/PathRange';
export declare class CypherEngine {
private readonly _cypher;
private readonly _nodes;
constructor();
get cypher(): string;
match(): CypherEngine;
optionalMatch(): CypherEngine;
conditional(ifStatement: boolean | undefined, query: string, elseQuery: string): CypherEngine;
conditionalFunc(ifStatement: boolean | undefined, query: ICypherFunction, elseQuery: ICypherFunction): CypherEngine;
merge(): CypherEngine;
create(): CypherEngine;
node(labels: string[], variableName?: string, ...properties: Property[]): CypherEngine;
declaredNode(variableName: string, ...additionalLabels: string[]): CypherEngine;
variable(variableName: string, property?: string): CypherEngine;
relates(direction: RelationshipDirection, types?: string[], variableName?: string, range?: PathRange, ...properties: Property[]): CypherEngine;
delete(variableName: string, ...furtherNames: string[]): CypherEngine;
where(): CypherEngine;
detach(): CypherEngine;
unwind(): CypherEngine;
with(...variableNames: string[]): CypherEngine;
exists(variableName: string, property: string): CypherEngine;
value(value: string | number | string[] | number[]): CypherEngine;
set(...properties: SetProperty[]): CypherEngine;
onCreate(): CypherEngine;
onMatch(): CypherEngine;
and(): CypherEngine;
or(): CypherEngine;
is(): CypherEngine;
call(apoc: string): CypherEngine;
callQuery(engine: CypherEngine): CypherEngine;
in(): CypherEngine;
null(): CypherEngine;
not(): CypherEngine;
equals(): CypherEngine;
greaterThan(): CypherEngine;
lessThan(): CypherEngine;
startsWith(): CypherEngine;
endsWith(): CypherEngine;
contains(): CypherEngine;
regularExpression(): CypherEngine;
returns(...variableNames: string[]): CypherEngine;
limit(limit: number | string): CypherEngine;
skip(skip: number | string): CypherEngine;
toString(): string;
private nodeString;
private variableString;
private propertySetter;
private propertyFilter;
orderBy(variableNames: string[], sorts?: {
prop: string;
asc: boolean;
}[], includePhrase?: boolean): this;
case(): CypherEngine;
when(): CypherEngine;
then(): CypherEngine;
remove(): CypherEngine;
else(): CypherEngine;
}