LeviLamina
Loading...
Searching...
No Matches
TextObjectParser.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated forward declare list
6// clang-format off
8namespace Json { class Value; }
9// clang-format on
10
12public:
13 // TextObjectParser inner types declare
14 // clang-format off
15 struct ErrorLocalization;
16 struct ServerData;
17 // clang-format on
18
19 // TextObjectParser inner types define
20 struct ServerData {
21 public:
22 // member variables
23 // NOLINTBEGIN
27 // NOLINTEND
28
29 public:
30 // prevent constructor by default
31 ServerData& operator=(ServerData const&);
32 ServerData(ServerData const&);
33 ServerData();
34 };
35
37 public:
38 // member variables
39 // NOLINTBEGIN
42 // NOLINTEND
43
44 public:
45 // prevent constructor by default
46 ErrorLocalization& operator=(ErrorLocalization const&);
49
50 public:
51 // member functions
52 // NOLINTBEGIN
54 // NOLINTEND
55
56 public:
57 // destructor thunk
58 // NOLINTBEGIN
59 MCNAPI void $dtor();
60 // NOLINTEND
61 };
62
63public:
64 // static functions
65 // NOLINTBEGIN
66 MCNAPI static bool _getObjectsFromTextObject(
67 ::Json::Value const& root,
68 ::TextObjectRoot& parsedObject,
71 );
72
73 MCNAPI static bool _parseScoreTextObject(
74 ::TextObjectRoot& parentTextObject,
75 ::Json::Value const& scoreObject,
78 );
79
80 MCNAPI static bool _parseSelectorTextObject(
81 ::TextObjectRoot& parentTextObject,
82 ::std::string selectorString,
85 );
86
87 MCNAPI static bool _textObjectFromJson(
88 ::Json::Value const& root,
89 ::TextObjectRoot& parsedObject,
92 );
93
94 MCNAPI static bool
95 textObjectFromJson(::Json::Value const& root, ::TextObjectRoot& parsedObject, ::std::string& errorMsg);
96
97 MCNAPI static bool textObjectFromJsonString(
98 ::std::string const& jsonAsString,
99 ::TextObjectRoot& parsedObject,
100 ::std::string& errorMsg
101 );
102 // NOLINTEND
103
104public:
105 // static variables
106 // NOLINTBEGIN
107 MCNAPI static ::std::string const& RAW_TEXT_ERROR_NOT_ARRAY();
108
109 MCNAPI static ::std::string const& RAW_TEXT_ERROR_NOT_OBJECT();
110
111 MCNAPI static ::std::string const& RAW_TEXT_ERROR_NO_DATA();
112
113 MCNAPI static ::std::string const& RAW_TEXT_ERROR_PARSE_FAILED();
114
115 MCNAPI static ::std::string const& RAW_TEXT_ERROR_SCORE_NAME_NOT_STRING();
116
117 MCNAPI static ::std::string const& RAW_TEXT_ERROR_SCORE_NOT_OBJECT();
118
119 MCNAPI static ::std::string const& RAW_TEXT_ERROR_SCORE_OBJECTIVE_NOT_STRING();
120
121 MCNAPI static ::std::string const& RAW_TEXT_ERROR_SELECTOR_NOT_STRING();
122
123 MCNAPI static ::std::string const& RAW_TEXT_ERROR_TEXT_NOT_STRING();
124
125 MCNAPI static ::std::string const& RAW_TEXT_ERROR_TRANSLATE_NOT_STRING();
126
127 MCNAPI static ::std::string const& RAW_TEXT_ERROR_WITH_NOT_ARRAY_OR_RAW_TEXT();
128 // NOLINTEND
129};
Definition Value.h:16
Definition TextObjectParser.h:11
static MCAPI ::std::string const & RAW_TEXT_ERROR_NOT_OBJECT()
static MCAPI ::std::string const & RAW_TEXT_ERROR_SCORE_NAME_NOT_STRING()
static MCAPI ::std::string const & RAW_TEXT_ERROR_NOT_ARRAY()
static MCAPI bool _textObjectFromJson(::Json::Value const &root, ::TextObjectRoot &parsedObject, ::TextObjectParser::ServerData *serverData, ::TextObjectParser::ErrorLocalization &errorLocalization)
static MCAPI bool _parseScoreTextObject(::TextObjectRoot &parentTextObject, ::Json::Value const &scoreObject, ::TextObjectParser::ServerData *serverData, ::TextObjectParser::ErrorLocalization &errorLocalization)
static MCAPI ::std::string const & RAW_TEXT_ERROR_SCORE_OBJECTIVE_NOT_STRING()
static MCAPI bool textObjectFromJsonString(::std::string const &jsonAsString, ::TextObjectRoot &parsedObject, ::std::string &errorMsg)
static MCAPI bool _parseSelectorTextObject(::TextObjectRoot &parentTextObject, ::std::string selectorString, ::TextObjectParser::ServerData *serverData, ::TextObjectParser::ErrorLocalization &errorLocalization)
static MCAPI ::std::string const & RAW_TEXT_ERROR_WITH_NOT_ARRAY_OR_RAW_TEXT()
static MCAPI bool _getObjectsFromTextObject(::Json::Value const &root, ::TextObjectRoot &parsedObject, ::TextObjectParser::ServerData *serverData, ::TextObjectParser::ErrorLocalization &errorLocalization)
static MCAPI ::std::string const & RAW_TEXT_ERROR_SELECTOR_NOT_STRING()
static MCAPI ::std::string const & RAW_TEXT_ERROR_TEXT_NOT_STRING()
static MCAPI ::std::string const & RAW_TEXT_ERROR_TRANSLATE_NOT_STRING()
static MCAPI bool textObjectFromJson(::Json::Value const &root, ::TextObjectRoot &parsedObject, ::std::string &errorMsg)
static MCAPI ::std::string const & RAW_TEXT_ERROR_PARSE_FAILED()
static MCAPI ::std::string const & RAW_TEXT_ERROR_NO_DATA()
static MCAPI ::std::string const & RAW_TEXT_ERROR_SCORE_NOT_OBJECT()
Definition TextObjectRoot.h:14
Definition TextObjectParser.h:36
Definition TextObjectParser.h:20
Definition Alias.h:14