public ICypherExecuteable Delete <TOut>(Expression <Func <TIn, TOut> > deleteClause) { var query = new CypherQueryDefinition <TIn, TOut> { StartClause = _startDef, WherePredicate = _wherePredicate, DeleteClause = deleteClause, CreateRelationpClause = _createClause }; foreach (var m in _matchClauses ?? Enumerable.Empty <Expression <Func <IMatchQueryContext <TIn>, IDefineCypherRelationship> > >()) { query.AddMatchClause(m); } foreach (var m in _optionalMatchClauses ?? Enumerable.Empty <Expression <Func <IMatchQueryContext <TIn>, IDefineCypherRelationship> > >()) { query.AddOptionalMatchClause(m); } foreach (var m in _setters ?? Enumerable.Empty <Expression <Func <IUpdateQueryContext <TIn>, ISetResult> > >()) { query.AddSetClause(m); } return(new CypherQueryExecute <TOut>(_clientFactory, query)); }
private CypherQueryDefinition <TIn, TOut> BuildCypherQueryDefinition <TOut>() { var query = new CypherQueryDefinition <TIn, TOut> { StartClause = _startDef, WherePredicate = _wherePredicate, CreateRelationpClause = _createClause }; foreach (var m in _matchClauses ?? Enumerable.Empty <Expression <Func <IMatchQueryContext <TIn>, IDefineCypherRelationship> > >()) { query.AddMatchClause(m); } foreach (var m in _optionalMatchClauses ?? Enumerable.Empty <Expression <Func <IMatchQueryContext <TIn>, IDefineCypherRelationship> > >()) { query.AddOptionalMatchClause(m); } foreach (var m in _setters ?? Enumerable.Empty <Expression <Func <IUpdateQueryContext <TIn>, ISetResult> > >()) { query.AddSetClause(m); } return(query); }