AnCH Framework 0.2
Another C++ Hack: C++23 utility libraries
Loading...
Searching...
No Matches
fieldsBuilder.hpp
1/*
2 ANCH Framework: ANother C++ Hack is a C++ framework based on C++23 standard
3 Copyright (C) 2012 Vincent Lachenal
4
5 This file is part of ANCH Framework.
6
7 ANCH Framework is free software: you can redistribute it and/or modify
8 it under the terms of the GNU Lesser General Public License as published by
9 the Free Software Foundation, either version 3 of the License, or
10 (at your option) any later version.
11
12 ANCH Framework is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU Lesser General Public License for more details.
16
17 You should have received a copy of the GNU Lesser General Public License
18 along with ANCH Framework. If not, see <https://www.gnu.org/licenses/>.
19*/
20#pragma once
21
22#include "anch-sql-export.hpp"
23
24#include <string>
25
26#include "sql/builder/selectBuilderPart.hpp"
27#include "sql/builder/fromBuilder.hpp"
28
29
30namespace anch::sql {
31
32 class SelectBuilder;
33
44 class ANCH_SQL_EXPORT FieldsBuilder: public SelectBuilderPart {
45 friend class anch::sql::SelectBuilder;
46
47 // Constructors +
48 private:
52 FieldsBuilder() = delete;
53
60 FieldsBuilder(anch::sql::SelectBuilder& select, const std::string& column);
61 // Constructors -
62
63 // Destructor +
64 public:
68 virtual ~FieldsBuilder();
69 // Destructor -
70
71 // SQL commands +
72 public:
80 FieldsBuilder& field(const std::string& column);
81
89 FieldsBuilder& as(const std::string& alias);
90
96 FieldsBuilder& asc();
97
103 FieldsBuilder& desc();
104
112 FromBuilder from(const std::string& table);
113
114 // \todo from
115 // SQL commands -
116
117 };
118
119} // anch::sql
FromBuilder from(const std::string &table)
FieldsBuilder & desc()
FieldsBuilder & as(const std::string &alias)
FieldsBuilder & field(const std::string &column)
FieldsBuilder & asc()
Definition fromBuilder.hpp:42
Dynamic SQL select request builder.
Definition selectBuilder.hpp:48
SQL namespace.
Definition clauses.hpp:28
SelectBuilder select()