summaryrefslogtreecommitdiffstats
path: root/Source/cmCMakePresetsErrors.h
blob: b755c2567544784e8b6a248dbfbec40d83c73937 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
/* Distributed under the OSI-approved BSD 3-Clause License.  See accompanying
   file Copyright.txt or https://cmake.org/licensing for details.  */
#pragma once

#include "cmConfigure.h" // IWYU pragma: keep

#include <string>

#include <cm3p/json/value.h>

#include "cmJSONHelpers.h"

class cmJSONState;

namespace cmCMakePresetsErrors {
const Json::Value* getPreset(cmJSONState* state);

std::string getPresetName(cmJSONState* state);

std::string getVariableName(cmJSONState* state);

void FILE_NOT_FOUND(const std::string& filename, cmJSONState* state);

void INVALID_ROOT(const Json::Value* value, cmJSONState* state);

void NO_VERSION(const Json::Value* value, cmJSONState* state);

void INVALID_VERSION(const Json::Value* value, cmJSONState* state);

void UNRECOGNIZED_VERSION(const Json::Value* value, cmJSONState* state);

void INVALID_PRESETS(const Json::Value* value, cmJSONState* state);

void INVALID_PRESET(const Json::Value* value, cmJSONState* state);

void INVALID_PRESET_NAMED(const std::string& presetName, cmJSONState* state);

void INVALID_VARIABLE(const Json::Value* value, cmJSONState* state);

void DUPLICATE_PRESETS(const std::string& presetName, cmJSONState* state);

void CYCLIC_PRESET_INHERITANCE(const std::string& presetName,
                               cmJSONState* state);

void INHERITED_PRESET_UNREACHABLE_FROM_FILE(const std::string& presetName,
                                            cmJSONState* state);

void CONFIGURE_PRESET_UNREACHABLE_FROM_FILE(const std::string& presetName,
                                            cmJSONState* state);

void INVALID_MACRO_EXPANSION(const std::string& presetName,
                             cmJSONState* state);

void BUILD_TEST_PRESETS_UNSUPPORTED(const Json::Value*, cmJSONState* state);

void PACKAGE_PRESETS_UNSUPPORTED(const Json::Value*, cmJSONState* state);

void WORKFLOW_PRESETS_UNSUPPORTED(const Json::Value*, cmJSONState* state);

void INCLUDE_UNSUPPORTED(const Json::Value*, cmJSONState* state);

void INVALID_INCLUDE(const Json::Value* value, cmJSONState* state);

void INVALID_CONFIGURE_PRESET(const std::string& presetName,
                              cmJSONState* state);

void INSTALL_PREFIX_UNSUPPORTED(const Json::Value* value, cmJSONState* state);

void CONDITION_UNSUPPORTED(cmJSONState* state);

void TOOLCHAIN_FILE_UNSUPPORTED(cmJSONState* state);

void CYCLIC_INCLUDE(const std::string& file, cmJSONState* state);

void TEST_OUTPUT_TRUNCATION_UNSUPPORTED(cmJSONState* state);

void INVALID_WORKFLOW_STEPS(const std::string& workflowStep,
                            cmJSONState* state);

void NO_WORKFLOW_STEPS(const std::string& presetName, cmJSONState* state);

void FIRST_WORKFLOW_STEP_NOT_CONFIGURE(const std::string& stepName,
                                       cmJSONState* state);

void CONFIGURE_WORKFLOW_STEP_NOT_FIRST(const std::string& stepName,
                                       cmJSONState* state);

void WORKFLOW_STEP_UNREACHABLE_FROM_FILE(const std::string& workflowStep,
                                         cmJSONState* state);

void CTEST_JUNIT_UNSUPPORTED(cmJSONState* state);

void TRACE_UNSUPPORTED(cmJSONState* state);

JsonErrors::ErrorGenerator UNRECOGNIZED_CMAKE_VERSION(
  const std::string& version, int current, int required);

void INVALID_PRESET_NAME(const Json::Value* value, cmJSONState* state);

void INVALID_CONDITION(const Json::Value* value, cmJSONState* state);

JsonErrors::ErrorGenerator INVALID_CONDITION_OBJECT(
  JsonErrors::ObjectError errorType, const Json::Value::Members& extraFields);

JsonErrors::ErrorGenerator INVALID_VARIABLE_OBJECT(
  JsonErrors::ObjectError errorType, const Json::Value::Members& extraFields);

JsonErrors::ErrorGenerator INVALID_PRESET_OBJECT(
  JsonErrors::ObjectError errorType, const Json::Value::Members& extraFields);

JsonErrors::ErrorGenerator INVALID_ROOT_OBJECT(
  JsonErrors::ObjectError errorType, const Json::Value::Members& extraFields);

void PRESET_MISSING_FIELD(const std::string& presetName,
                          const std::string& missingField, cmJSONState* state);

void SCHEMA_UNSUPPORTED(cmJSONState* state);
}