The Battle for Wesnoth  1.15.1+dev
Public Member Functions | Public Attributes | List of all members
invalid_pbl_exception Struct Reference

Exception thrown when the WML parser fails to read a .pbl file. More...

#include <manager.hpp>

Inheritance diagram for invalid_pbl_exception:
Inheritance graph

Public Member Functions

 invalid_pbl_exception (const std::string &pbl_path, const std::string &msg)
 Constructor. More...
 
virtual ~invalid_pbl_exception () noexcept
 Destructor. More...
 
virtual const char * what () const noexcept
 Returns a pointer to the (constant) error description. More...
 

Public Attributes

const std::string path
 Path to the faulty .pbl file. More...
 
const std::string message
 Error message to display. More...
 

Detailed Description

Exception thrown when the WML parser fails to read a .pbl file.

Definition at line 30 of file manager.hpp.

Constructor & Destructor Documentation

◆ invalid_pbl_exception()

invalid_pbl_exception::invalid_pbl_exception ( const std::string &  pbl_path,
const std::string &  msg 
)
inline

Constructor.

Parameters
pbl_pathPath to the faulty .pbl file.
msgAn error message to display.

Definition at line 38 of file manager.hpp.

◆ ~invalid_pbl_exception()

virtual invalid_pbl_exception::~invalid_pbl_exception ( )
inlinevirtualnoexcept

Destructor.

Virtual to allow for subclassing.

Definition at line 51 of file manager.hpp.

Member Function Documentation

◆ what()

virtual const char* invalid_pbl_exception::what ( ) const
inlinevirtualnoexcept

Returns a pointer to the (constant) error description.

Returns
A pointer to a const char*. The underlying memory is in posession of the Exception object. Callers must not attempt to free the memory.

Definition at line 58 of file manager.hpp.

References archive_addon(), available_addons(), get_addon_install_info(), get_addon_pbl_info(), get_addon_version_info(), have_addon_in_vcs_tree(), have_addon_install_info(), have_addon_pbl_info(), installed_addons(), is_addon_installed(), refresh_addon_version_info_cache(), remove_local_addon(), set_addon_pbl_info(), and unarchive_addon().

Member Data Documentation

◆ message

const std::string invalid_pbl_exception::message

Error message to display.

Definition at line 46 of file manager.hpp.

Referenced by ad_hoc_addon_fetch_session(), and game_config_manager::load_addons_cfg().

◆ path

const std::string invalid_pbl_exception::path

Path to the faulty .pbl file.

Definition at line 43 of file manager.hpp.

Referenced by ad_hoc_addon_fetch_session().


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