libcluon
0.0.148
MessageParser.hpp
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2017-2018 Christian Berger
3
*
4
* This Source Code Form is subject to the terms of the Mozilla Public
5
* License, v. 2.0. If a copy of the MPL was not distributed with this
6
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
7
*/
8
9
#ifndef CLUON_MESSAGEPARSER_HPP
10
#define CLUON_MESSAGEPARSER_HPP
11
12
#include "
cluon/MetaMessage.hpp
"
13
#include "
cluon/cluon.hpp
"
14
15
#include <cstdint>
16
#include <string>
17
#include <utility>
18
#include <vector>
19
20
namespace
cluon
{
54
class
LIBCLUON_API
MessageParser
{
55
public
:
56
enum
MessageParserErrorCodes
: uint8_t { NO_MESSAGEPARSER_ERROR = 0, SYNTAX_ERROR = 1, DUPLICATE_IDENTIFIERS = 2 };
57
58
private
:
59
MessageParser
(
const
MessageParser
&) =
delete
;
60
MessageParser
(
MessageParser
&&) =
delete
;
61
MessageParser
&operator=(
const
MessageParser
&) =
delete
;
62
MessageParser
&operator=(
MessageParser
&&) =
delete
;
63
64
public
:
65
MessageParser
() =
default
;
66
76
std::pair<std::vector<MetaMessage>,
MessageParserErrorCodes
> parse(
const
std::string &input);
77
};
78
}
// namespace cluon
79
80
#endif
cluon
Definition:
cluon.hpp:65
LIBCLUON_API
#define LIBCLUON_API
Definition:
cluon.hpp:56
cluon::MessageParser
Definition:
MessageParser.hpp:54
MetaMessage.hpp
cluon.hpp
cluon::MessageParser::MessageParserErrorCodes
MessageParserErrorCodes
Definition:
MessageParser.hpp:56
libcluon
include
cluon
MessageParser.hpp
Generated on Fri Mar 22 2024 10:44:38 for libcluon by
1.8.13