blob: 86ffdd0fe7535b41977e6f58a2fb6db2a90fd645 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include "configformatter.h"
namespace config {
/**
* Formatter capable of encoding and decoding config as json.
*/
class JsonConfigFormatter : public ConfigFormatter {
public:
JsonConfigFormatter(bool compact = false);
// Inherits ConfigFormatter
void encode(ConfigDataBuffer & buffer) const override;
// Inherits ConfigFormatter
size_t decode(ConfigDataBuffer & buffer) const override;
private:
const bool _compact;
};
} // namespace config
|