6#ifndef BITCOIN_NODE_WARNINGS_H
7#define BITCOIN_NODE_WARNINGS_H
Manages warning messages within a node.
std::map< warning_type, bilingual_str > m_warnings GUARDED_BY(m_mutex)
std::variant< kernel::Warning, node::Warning > warning_type
Warnings(const Warnings &)=delete
A warnings instance should always be passed by reference, never copied.
bool Unset(warning_type id) EXCLUSIVE_LOCKS_REQUIRED(!m_mutex)
Unset a warning message.
Warnings & operator=(const Warnings &)=delete
bool Set(warning_type id, bilingual_str message) EXCLUSIVE_LOCKS_REQUIRED(!m_mutex)
Set a warning message.
std::vector< bilingual_str > GetMessages() const EXCLUSIVE_LOCKS_REQUIRED(!m_mutex)
Return potential problems detected by the node, sorted by the warning_type id.
UniValue GetWarningsForRpc(const Warnings &warnings, bool use_deprecated)
RPC helper function that wraps warnings.GetMessages().
#define EXCLUSIVE_LOCKS_REQUIRED(...)