SNode.C
Loading...
Searching...
No Matches
MariaDBClientSyncAPI.cpp
Go to the documentation of this file.
1
/*
2
* SNode.C - a slim toolkit for network communication
3
* Copyright (C) Volker Christian <me@vchrist.at>
4
* 2020, 2021, 2022, 2023, 2024, 2025
5
* 2021, 2022 Daniel Flockert
6
*
7
* This program is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU Lesser General Public License as published
9
* by the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
*
12
* This program 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 this program. If not, see <http://www.gnu.org/licenses/>.
19
*/
20
21
#
include
"database/mariadb/MariaDBClientSyncAPI.h"
22
23
#
include
"database/mariadb/commands/sync/MariaDBAffectedRowsCommand.h"
24
#
include
"database/mariadb/commands/sync/MariaDBFieldCountCommand.h"
25
26
#
ifndef
DOXYGEN_SHOULD_SKIP_THIS
27
28
#
endif
/* DOXYGEN_SHOULD_SKIP_THIS */
29
30
namespace
database::
mariadb
{
31
32
MariaDBClientSyncAPI
::~
MariaDBClientSyncAPI
() {
33
}
34
35
void
MariaDBClientSyncAPI
::
affectedRows
(
const
std::function<
void
(
int
)>& onAffectedRows,
36
const
std::function<
void
(
const
std::string&,
unsigned
int
)>& onError) {
37
execute_sync(
new
database::mariadb::commands::sync::MariaDBAffectedRowsCommand(onAffectedRows, onError));
38
}
39
40
void
MariaDBClientSyncAPI
::
fieldCount
(
const
std::function<
void
(
unsigned
int
)>& onFieldCount,
41
const
std::function<
void
(
const
std::string&,
unsigned
int
)>& onError) {
42
execute_sync
(
new
database::
mariadb
::commands::
sync
::
MariaDBFieldCountCommand
(onFieldCount, onError));
43
}
44
45
}
// namespace database::mariadb
database::mariadb::MariaDBClientSyncAPI
Definition
MariaDBClientSyncAPI.h:37
database::mariadb::MariaDBClientSyncAPI::fieldCount
void fieldCount(const std::function< void(unsigned int)> &onFieldCount, const std::function< void(const std::string &, unsigned int)> &onError)
Definition
MariaDBClientSyncAPI.cpp:40
database::mariadb::MariaDBClientSyncAPI::~MariaDBClientSyncAPI
virtual ~MariaDBClientSyncAPI()
Definition
MariaDBClientSyncAPI.cpp:32
database::mariadb::MariaDBClientSyncAPI::affectedRows
void affectedRows(const std::function< void(int)> &onAffectedRows, const std::function< void(const std::string &, unsigned int)> &onErro)
Definition
MariaDBClientSyncAPI.cpp:35
database::mariadb::MariaDBClientSyncAPI::execute_sync
virtual void execute_sync(MariaDBCommandSync *mariaDBCommand)=0
database::mariadb::commands::sync::MariaDBFieldCountCommand
Definition
MariaDBFieldCountCommand.h:32
database::mariadb::commands::sync
Definition
MariaDBAffectedRowsCommand.cpp:27
database
Definition
MariaDBClient.h:39
database
mariadb
MariaDBClientSyncAPI.cpp
Generated on Mon Feb 10 2025 20:20:58 for SNode.C by
1.11.0