Orcus
config.hpp
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 */
7
8#ifndef INCLUDED_ORCUS_CONFIG_HPP
9#define INCLUDED_ORCUS_CONFIG_HPP
10
11#include "orcus/env.hpp"
12#include "orcus/types.hpp"
13
14#include <string>
15
16namespace orcus {
17
18struct ORCUS_DLLPUBLIC config
19{
20 format_t input_format;
21
27 {
30
36 };
37
41 uint16_t debug;
42
49
50 union
51 {
52 csv_config csv;
53
54 // TODO : add config for other formats as needed.
55 };
56
57 config(format_t input_format);
58};
59
60struct ORCUS_DLLPUBLIC json_config
61{
67 std::string input_path;
68
73 std::string output_path;
74
78 dump_format_t output_format;
79
87
92
104
105 json_config();
106 ~json_config();
107};
108
109struct ORCUS_DLLPUBLIC yaml_config
110{
111 enum class output_format_type { none, yaml, json };
112
113 std::string input_path;
114 std::string output_path;
115
116 output_format_type output_format;
117
118 yaml_config();
119 ~yaml_config();
120};
121
122}
123
124#endif
125
126/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Definition: config.hpp:27
bool split_to_multiple_sheets
Definition: config.hpp:35
size_t header_row_size
Definition: config.hpp:29
Definition: config.hpp:19
uint16_t debug
Definition: config.hpp:41
bool structure_check
Definition: config.hpp:48
Definition: config.hpp:61
std::string output_path
Definition: config.hpp:73
bool persistent_string_values
Definition: config.hpp:103
bool resolve_references
Definition: config.hpp:91
dump_format_t output_format
Definition: config.hpp:78
bool preserve_object_order
Definition: config.hpp:86
std::string input_path
Definition: config.hpp:67
Definition: config.hpp:110