The Battle for Wesnoth  1.15.12+dev
Public Member Functions | Public Attributes | List of all members
schema_validation::schema_validator::message_info Struct Reference

Messages are cached. More...

#include <schema_validator.hpp>

Public Member Functions

 message_info (message_type t, const std::string &file, int line=0, int n=0, const std::string &tag="", const std::string &key="", const std::string &value="")

Public Attributes

message_type type
std::string file
int line
int n
std::string tag
std::string key
std::string value

Detailed Description

Messages are cached.

The reason is next: in file where [tag]...[/tag][+tag]...[/tag] config object will be validated each [/tag]. So message can be as wrong (when [+tag] section contains missed elements) as duplicated.

Messages are mapped by config*. That ensures uniqueness. Also message-maps are organized in stack to avoid memory leaks.

Definition at line 92 of file schema_validator.hpp.

Constructor & Destructor Documentation

◆ message_info()

schema_validation::schema_validator::message_info::message_info ( message_type  t,
const std::string &  file,
int  line = 0,
int  n = 0,
const std::string &  tag = "",
const std::string &  key = "",
const std::string &  value = "" 

Definition at line 102 of file schema_validator.hpp.

Member Data Documentation

◆ file

std::string schema_validation::schema_validator::message_info::file

◆ key

std::string schema_validation::schema_validator::message_info::key

◆ line

int schema_validation::schema_validator::message_info::line

◆ n

int schema_validation::schema_validator::message_info::n

Definition at line 97 of file schema_validator.hpp.

Referenced by schema_validation::schema_validator::print().

◆ tag

std::string schema_validation::schema_validator::message_info::tag

◆ type

message_type schema_validation::schema_validator::message_info::type

◆ value

std::string schema_validation::schema_validator::message_info::value

The documentation for this struct was generated from the following file: