libzypp: zypp/PluginScriptException.h Source File

libzypp 17.38.6

PluginScriptException.h
Go to the documentation of this file.
1/*---------------------------------------------------------------------\
2| ____ _ __ __ ___ |
3| |__ / \ / / . \ . \ |
4| / / \ V /| _/ _/ |
5| / /__ | | | | | | |
6| /_____||_| |_| |_| |
7| |
8\---------------------------------------------------------------------*/
12#ifndef ZYPP_PLUGINSCRIPTEXCEPTION_H
13#define ZYPP_PLUGINSCRIPTEXCEPTION_H
14
15#include <iosfwd>
16
17#include <zypp-core/base/Exception.h>
18#include <zypp-core/Pathname.h>
19
21namespace zypp
22{
23
25 class ZYPP_API PluginScriptException : public Exception
26 {
27 public:
28 PluginScriptException();
29 PluginScriptException( const std::string & msg_r );
30 PluginScriptException( const std::string & msg_r, const std::string & hist_r );
31 ~PluginScriptException() throw() override;
32 };
33
35#define declException( EXCP, BASE ) \
36 class ZYPP_API EXCP : public BASE { \
37 public: \
38 EXCP() : BASE( #EXCP ) {} \
39 EXCP( const std::string & msg_r ) : BASE( msg_r ) {} \
40 EXCP( const std::string & msg_r, const std::string & hist_r ) : BASE( msg_r, hist_r ) {} \
41 virtual ~EXCP() throw() {} \
42 }
43
45 declException( PluginScriptNotConnected, PluginScriptException );
46
48 declException( PluginScriptDiedUnexpectedly, PluginScriptException );
49
50
52 declException( PluginScriptTimeout, PluginScriptException );
53
55 declException( PluginScriptSendTimeout, PluginScriptTimeout );
56
58 declException( PluginScriptReceiveTimeout, PluginScriptTimeout );
59
60#undef declException
61
63} // namespace zypp
65#endif // ZYPP_PLUGINSCRIPTEXCEPTION_H
Exception.h
Pathname.h
declException
#define declException(EXCP, BASE)
Convenience macro to declare more specific PluginScriptExceptions.
Definition PluginScriptException.h:35
zypp::Exception::Exception
Exception()
Default ctor.
Definition Exception.cc:94
zypp::PluginScriptException
Base class for PluginScript Exception.
Definition PluginScriptException.h:26
zypp::PluginScriptException::PluginScriptException
PluginScriptException()
Definition PluginScriptException.cc:24
zypp
Easy-to use interface to the ZYPP dependency resolver.
Definition CodePitfalls.doc:2
zypp::ZYPP_API
const Arch Arch_empty ZYPP_API
relates: Arch This is an empty Arch represented by an empty string.
Definition Arch.h:173