-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementation feature list: InQueryCall, Unwind, Merge, YieldField, …
…Multi-Match, With, Aggregate, Expression, Exists, cypher::FieldData of type map and List of run-through tests includes TestMultiMatch,Testparameter, TestWith, TestUnwind, TestAdd, TestDelete, TestMerge, TestCreatYago, TestAggregate, TestTopn, TestLdbcSnb, TestOpt, TestCreateLabel, TestEdgeIdQuery (#561) * add cypher test compare result * implement query * implement match query * implement standalone call and create * cpplint * cpplint * cpplint * fix double format * update * update * implement set * implement gql set * fix test case * move dml * cpplint * cpplint * add create delete set * implement unwind * fix bug * implement count(*) * implement expression * multi match init * fix bug * fix bug * fix bug * fix bug * implement inquery call * fix bug * fix bug * implement merge * implement merge * fix bug in merge clause * fix bug * fix bug * cpplint * cpplint * comments * comments * cpplint --------- Co-authored-by: Shipeng Qi <[email protected]> Co-authored-by: kehuang <[email protected]> Co-authored-by: lipanpan03 <[email protected]>
- Loading branch information
1 parent
c356598
commit 6e5585d
Showing
72 changed files
with
3,152 additions
and
1,285 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
deps/geax-front-end/include/geax-front-end/ast/stmt/InQueryProcedureCall.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
/** | ||
* Copyright 2023 AntGroup CO., Ltd. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* | ||
*/ | ||
|
||
#ifndef GEAXFRONTEND_AST_STMT_INQUERYPROCEDURECALL_H_ | ||
#define GEAXFRONTEND_AST_STMT_INQUERYPROCEDURECALL_H_ | ||
|
||
#include "geax-front-end/ast/stmt/ProcedureCall.h" | ||
#include "geax-front-end/ast/expr/Param.h" | ||
#include "geax-front-end/ast/expr/Expr.h" | ||
#include "geax-front-end/ast/clause/YieldField.h" | ||
|
||
namespace geax { | ||
namespace frontend { | ||
|
||
class InQueryProcedureCall : public ProcedureCall { | ||
public: | ||
InQueryProcedureCall() : ProcedureCall(AstNodeType::kInQueryProcedureCall) {} | ||
~InQueryProcedureCall() = default; | ||
|
||
void setName(StringParam&& name) { name_ = std::move(name); } | ||
const StringParam name() const { return name_; } | ||
|
||
void appendArg(Expr* arg) { args_.emplace_back(arg); } | ||
void setArgs(std::vector<Expr*>&& args) { args_ = std::move(args); } | ||
const std::vector<Expr*>& args() const { return args_; } | ||
|
||
void setYield(YieldField* yield) { yield_ = yield; } | ||
const std::optional<YieldField*>& yield() const { return yield_; } | ||
|
||
std::any accept(AstNodeVisitor& visitor) override { return visitor.visit(this); } | ||
|
||
private: | ||
StringParam name_; | ||
std::vector<Expr*> args_; | ||
std::optional<YieldField*> yield_; | ||
}; // class NamedProcedureCall | ||
|
||
} // namespace frontend | ||
} // namespace geax | ||
|
||
#endif // GEAXFRONTEND_AST_STMT_INQUERYPROCEDURECALL_H_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
49 changes: 49 additions & 0 deletions
49
deps/geax-front-end/include/geax-front-end/ast/stmt/UnwindStatement.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
/** | ||
* Copyright 2023 AntGroup CO., Ltd. | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* | ||
*/ | ||
|
||
#ifndef GEAXFRONTEND_AST_STMT_UnwindStatement_H_ | ||
#define GEAXFRONTEND_AST_STMT_UnwindStatement_H_ | ||
|
||
#include <string> | ||
#include "geax-front-end/ast/expr/Expr.h" | ||
#include "geax-front-end/ast/stmt/SimpleQueryStatement.h" | ||
|
||
namespace geax { | ||
namespace frontend { | ||
|
||
class UnwindStatement : public SimpleQueryStatement { | ||
public: | ||
explicit UnwindStatement() | ||
: SimpleQueryStatement(AstNodeType::kUnwindStatement) {} | ||
~UnwindStatement() = default; | ||
|
||
void setVariable(std::string&& v) {variable_ = std::move(v);} | ||
|
||
const std::string& variable() {return variable_;} | ||
|
||
void setList(Expr* expr) {list_ = expr;} | ||
|
||
Expr* list() const { return list_; } | ||
|
||
std::any accept(AstNodeVisitor& visitor) override { return visitor.visit(this); } | ||
private: | ||
std::string variable_; | ||
Expr* list_; | ||
}; // class SchemaRef | ||
|
||
} // namespace frontend | ||
} // namespace geax | ||
|
||
#endif // GEAXFRONTEND_AST_STMT_UnwindStatement_H_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.