SWC-DB
v0.5.12 C++ documentations
SWC-DB© (Super Wide Column Database) - High Performance Scalable Database (https://github.com/kashirin-alex/swc-db)
CellValueSerialFieldUpdate.cc
Go to the documentation of this file.
1
/*
2
* SWC-DB© Copyright since 2019 Alex Kashirin <kashirin.alex@gmail.com>
3
* License details at <https://github.com/kashirin-alex/swc-db/#license>
4
*/
5
6
7
#include "
swcdb/db/Cells/CellValueSerialFieldUpdate.h
"
8
9
10
namespace
SWC
{
namespace
DB {
namespace
Cell {
11
namespace
Serial {
namespace
Value {
12
13
14
15
std::ostream&
FieldUpdate::print
(std::ostream& out)
const
{
16
if
(
is_no_add_field
())
17
out <<
"CTRL_NO_ADD_FIELD "
;
18
if
(
is_delete_field
())
19
out <<
"CTRL_DELETE_FIELD "
;
20
if
(
is_value_set
())
21
out <<
"CTRL_VALUE_SET "
;
22
if
(
is_value_del
())
23
out <<
"CTRL_VALUE_DEL "
;
24
return
out;
25
}
26
27
std::ostream&
FieldUpdate_MATH::print
(std::ostream& out)
const
{
28
FieldUpdate::print
(out);
29
switch
(
op
) {
30
case
OP::EQUAL:
31
return
out <<
"EQUAL"
;
32
case
OP::PLUS:
33
return
out <<
"PLUS"
;
34
case
OP::MULTIPLY:
35
return
out <<
"MULTIPLY"
;
36
case
OP::DIVIDE:
37
return
out <<
"DIVIDE"
;
38
default
:
39
return
out <<
"UNKNOWN"
;
40
}
41
}
42
43
std::ostream&
FieldUpdate_LIST::print
(std::ostream& out)
const
{
44
FieldUpdate::print
(out);
45
switch
(
op
) {
46
case
OP::REPLACE:
47
return
out <<
"REPLACE"
;
48
case
OP::APPEND:
49
return
out <<
"APPEND"
;
50
case
OP::PREPEND:
51
return
out <<
"PREPEND"
;
52
case
OP::INSERT
:
53
return
out <<
"INSERT:"
<<
pos
;
54
case
OP::OVERWRITE:
55
return
out <<
"OVERWRITE:"
<<
pos
;
56
case
OP::ERASE:
57
return
out <<
"ERASE:"
<<
pos
;
58
case
OP::BY_UNIQUE:
59
return
out <<
"BY_UNIQUE"
;
60
case
OP::BY_COND:
61
return
out <<
"BY_COND"
;
62
case
OP::BY_INDEX:
63
return
out <<
"BY_INDEX"
;
64
default
:
65
return
out <<
"UNKNOWN"
;
66
}
67
}
68
69
70
71
}}}}}
SWC::DB::Cell::Serial::Value::FieldUpdate::is_value_set
SWC_CAN_INLINE bool is_value_set() const noexcept
Definition:
CellValueSerialFieldUpdate.h:97
CellValueSerialFieldUpdate.h
SWC::DB::Cell::Serial::Value::FieldUpdate_LIST::op
OP op
Definition:
CellValueSerialFieldUpdate.h:488
SWC::DB::Cell::Serial::Value::FieldUpdate::is_no_add_field
SWC_CAN_INLINE bool is_no_add_field() const noexcept
Definition:
CellValueSerialFieldUpdate.h:81
SWC::DB::Cell::Serial::Value::FieldUpdate::is_delete_field
SWC_CAN_INLINE bool is_delete_field() const noexcept
Definition:
CellValueSerialFieldUpdate.h:89
SWC::DB::Cell::Serial::Value::FieldUpdate_LIST::pos
uint24_t pos
Definition:
CellValueSerialFieldUpdate.h:489
SWC
The SWC-DB C++ namespace 'SWC'.
Definition:
main.cc:12
SWC::DB::Cell::Serial::Value::FieldUpdate_LIST::print
virtual std::ostream & print(std::ostream &out) const override
Definition:
CellValueSerialFieldUpdate.cc:43
SWC::DB::Cells::INSERT
@ INSERT
Definition:
Cell.h:62
SWC::DB::Cell::Serial::Value::FieldUpdate::print
virtual std::ostream & print(std::ostream &out) const
Definition:
CellValueSerialFieldUpdate.cc:15
SWC::DB::Cell::Serial::Value::FieldUpdate_MATH::print
virtual std::ostream & print(std::ostream &out) const override
Definition:
CellValueSerialFieldUpdate.cc:27
SWC::DB::Cell::Serial::Value::FieldUpdate_MATH::op
OP op
Definition:
CellValueSerialFieldUpdate.h:239
SWC::DB::Cell::Serial::Value::FieldUpdate::is_value_del
SWC_CAN_INLINE bool is_value_del() const noexcept
Definition:
CellValueSerialFieldUpdate.h:105
lib
swcdb
db
Cells
CellValueSerialFieldUpdate.cc
Generated on Sat Jun 3 2023 18:00:08 for SWC-DB by
1.8.20