forked from qt-creator/qt-creator
Sqlite: Improve SqliteStatement
There are now only value and values methods. value returns an optional and values are returning a vector. The result value count has now be specified instead of the result value list. Change-Id: I17a0741d5e838b4bf4b9486825c870ada1722584 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
@@ -39,24 +39,25 @@ class SourceLocations
|
||||
public:
|
||||
struct Location
|
||||
{
|
||||
qint64 sourceId;
|
||||
qint64 line;
|
||||
qint64 column;
|
||||
Location(qint64 sourceId, qint64 line, qint64 column)
|
||||
: sourceId(sourceId), line(line), column(column)
|
||||
{}
|
||||
|
||||
qint64 sourceId;
|
||||
qint64 line;
|
||||
qint64 column;
|
||||
};
|
||||
|
||||
struct Source
|
||||
{
|
||||
Source(qint64 sourceId, Utils::PathString &&sourcePath)
|
||||
: sourceId(sourceId), sourcePath(std::move(sourcePath))
|
||||
{}
|
||||
|
||||
qint64 sourceId;
|
||||
Utils::PathString sourcePath;
|
||||
};
|
||||
|
||||
enum LocationGetter
|
||||
{
|
||||
SourceId = 0,
|
||||
Line,
|
||||
Column
|
||||
};
|
||||
|
||||
std::vector<Location> locations;
|
||||
std::unordered_map<qint64, Utils::PathString> sources;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user