Go to the documentation of this file.
9 #ifndef EAGINE_SERIALIZE_TYPE_SUDOKU_HPP
10 #define EAGINE_SERIALIZE_TYPE_SUDOKU_HPP
12 #include "../../sudoku.hpp"
13 #include "../data_buffer.hpp"
14 #include "../read.hpp"
15 #include "../write.hpp"
19 template <
identifier_t S
id,
unsigned S,
bool T,
typename Selector>
20 struct get_serialize_buffer_size<Sid, basic_sudoku_board<S, T>, Selector>
21 : get_serialize_buffer_size<
23 typename basic_sudoku_board<S, T>::blocks_type,
26 template <
unsigned S,
bool T>
27 struct serializer<basic_sudoku_board<S, T>>
28 : common_serializer<basic_sudoku_board<S, T>> {
29 template <
typename Backend>
30 auto write(
const basic_sudoku_board<S, T>& value, Backend& backend)
const {
31 return _serializer.write(value._blocks, backend);
35 serializer<typename basic_sudoku_board<S, T>::blocks_type> _serializer{};
38 template <
unsigned S,
bool T>
39 struct deserializer<basic_sudoku_board<S, T>>
40 : common_deserializer<basic_sudoku_board<S, T>> {
41 template <
typename Backend>
42 auto read(basic_sudoku_board<S, T>& value, Backend& backend)
const {
43 const auto errors{_deserializer.read(value._blocks, backend)};
48 deserializer<typename basic_sudoku_board<S, T>::blocks_type> _deserializer{};
Common code is placed in this namespace.
Definition: eagine.hpp:21