More exception documentation.
This commit is contained in:
parent
25bef45181
commit
2ee354c7a3
|
@ -39,8 +39,15 @@ using std::thread;
|
|||
/*!
|
||||
* @brief Interact with an account using the Mastodon API.
|
||||
*
|
||||
* @throw std::runtime_error No hashtag or list ID given.
|
||||
* @throw std::logic_error Unhandled stream type. (Should never happen)
|
||||
* @throw std::runtime_error No hashtag or list ID given.
|
||||
* @throw std::logic_error Unhandled stream type. (Should never happen)
|
||||
* @throw std::runtime_error Directory not found.
|
||||
* @throw std::filesystem::filesystem_error Could not create directory.
|
||||
* @throw std::ifstream::failure Could not read from file.
|
||||
* @throw nlohmann::detail::parse_error Could not parse file.
|
||||
* @throw nlohmann::detail::type_error Setting not found / Wrong type.
|
||||
* @throw mastodonpp::CURLException libcurl error from
|
||||
* [mastodonpp](https://doc.schlomp.space/mastodonpp/).
|
||||
*
|
||||
* @since 0.1.0
|
||||
*
|
||||
|
@ -70,6 +77,14 @@ public:
|
|||
*
|
||||
* For possible exceptions see Directories and Config.
|
||||
*
|
||||
* @throw std::runtime_error Directory not found.
|
||||
* @throw std::filesystem::filesystem_error Could not create directory.
|
||||
* @throw std::ifstream::failure Could not read from file.
|
||||
* @throw nlohmann::detail::parse_error Could not parse file.
|
||||
* @throw nlohmann::detail::type_error Setting not found / Wrong type.
|
||||
* @throw mastodonpp::CURLException libcurl error from
|
||||
* [mastodonpp](https://doc.schlomp.space/mastodonpp/).
|
||||
*
|
||||
* @since 0.1.0
|
||||
*/
|
||||
MastodonAPI(string_view application_name, string_view account_name,
|
||||
|
@ -97,8 +112,10 @@ public:
|
|||
* @param type What to stream.
|
||||
* @param id The hashtag or list id.
|
||||
*
|
||||
* @throw std::runtime_error hashtag or list ID given.
|
||||
* @throw std::logic_error Unhandled stream type. (Should never happen)
|
||||
* @throw std::runtime_error hashtag or list ID given.
|
||||
* @throw std::logic_error Unhandled stream type. (Should never happen)
|
||||
* @throw mastodonpp::CURLException libcurl error from [mastodonpp]
|
||||
* (https://doc.schlomp.space/mastodonpp/).
|
||||
*
|
||||
* @since 0.1.0
|
||||
*/
|
||||
|
|
|
@ -40,10 +40,12 @@ using std::string_view;
|
|||
/*!
|
||||
* @brief Read and write the configuration.
|
||||
*
|
||||
* @throw std::ifstream::failure Could not read from file.
|
||||
* @throw std::ofstream::failure Could not write to file.
|
||||
* @throw nlohmann::detail::parse_error Could not parse file.
|
||||
* @throw nlohmann::detail::type_error Setting not found / Wrong type.
|
||||
* @throw std::runtime_error Directory not found.
|
||||
* @throw std::filesystem::filesystem_error Could not create directory.
|
||||
* @throw std::ifstream::failure Could not read from file.
|
||||
* @throw std::ofstream::failure Could not write to file.
|
||||
* @throw nlohmann::detail::parse_error Could not parse file.
|
||||
* @throw nlohmann::detail::type_error Setting not found / Wrong type.
|
||||
*
|
||||
* @since 0.1.0
|
||||
*
|
||||
|
@ -58,6 +60,9 @@ public:
|
|||
* @param application_name The name of your application.
|
||||
* @param filename The filename to open.
|
||||
*
|
||||
* @throw std::runtime_error Directory not found.
|
||||
* @throw std::filesystem::filesystem_error Could not create directory.
|
||||
*
|
||||
* @since 0.1.0
|
||||
*/
|
||||
explicit Config(const string_view application_name,
|
||||
|
|
Reference in New Issue