载入中...
搜索中...
未找到
eve::database::Query类 参考
Composable filtered/sorted/paged query shared by C++ and scripts. 更多...
#include <Database.h>
Public 成员函数 | |
| Query (Connection *connection, std::string table) | |
| Queries Query. | |
| Query * | where (const std::string &column, const std::string &op, Value value) |
| Where. | |
| Query * | whereJson (const std::string &column, const std::string &op, const std::string &valueJson) |
| Where json. | |
| Query * | orderBy (const std::string &column, bool ascending=true) |
| Order by. | |
| Query * | limit (int count) |
| Limit. | |
| Query * | offset (int count) |
| Offset. | |
| std::vector< Row > | all () |
| All. | |
| std::string | allJson () |
| All json. | |
| std::string | firstJson () |
| First json. | |
| int | count () |
| Returns the number of count. | |
详细描述
Composable filtered/sorted/paged query shared by C++ and scripts.
在文件 Database.h 第 148 行定义.
构造及析构函数说明
◆ Query()
| eve::database::Query::Query | ( | Connection * | connection, |
| std::string | table | ||
| ) |
Queries Query.
在文件 Database.cpp 第 175 行定义.
成员函数说明
◆ all()
| std::vector< Row > eve::database::Query::all | ( | ) |
◆ allJson()
| std::string eve::database::Query::allJson | ( | ) |
◆ count()
| int eve::database::Query::count | ( | ) |
Returns the number of count.
在文件 Database.cpp 第 228 行定义.
引用了 number, eve::database::Connection::query(), rows, text , 以及 value.
◆ firstJson()
| std::string eve::database::Query::firstJson | ( | ) |
◆ limit()
| Query * eve::database::Query::limit | ( | int | count | ) |
◆ offset()
| Query * eve::database::Query::offset | ( | int | count | ) |
◆ orderBy()
| Query * eve::database::Query::orderBy | ( | const std::string & | column, |
| bool | ascending = true |
||
| ) |
◆ where()
◆ whereJson()
| Query * eve::database::Query::whereJson | ( | const std::string & | column, |
| const std::string & | op, | ||
| const std::string & | valueJson | ||
| ) |
该类的文档由以下文件生成:
- src/modules/database/Database.h
- src/modules/database/Database.cpp