00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef YouError_h
00022 #define YouError_h
00023
00024 #include <iosfwd>
00025
00026 #include <y2pm/PMError.h>
00027
00029
00030
00035 class YouError {
00036
00037 private:
00038
00039 friend class PMError;
00040
00041 static const std::string errclass;
00042
00043 static std::string errtext( const unsigned e );
00044
00045 public:
00046
00047 enum Error {
00048 E_ok = PMError::E_ok,
00049 E_error = PMError::C_YouError,
00050
00051 E_bad_sig_file,
00052 E_bad_sig_rpm,
00053 E_get_youservers_failed,
00054 E_write_youservers_failed,
00055 E_read_youservers_failed,
00056 E_user_abort,
00057 E_user_skip,
00058 E_user_skip_all,
00059 E_user_retry,
00060 E_parse_error,
00061 E_script_failed,
00062 E_prescript_failed,
00063 E_postscript_failed,
00064 E_rpm_failed,
00065 E_install_failed,
00066 E_empty_location,
00067 E_read_mediapatches_failed,
00068 E_callback_missing,
00069 E_missing_sig_file,
00070 E_wrong_media
00071 };
00072
00073 friend std::ostream & operator<<( std::ostream & str, const Error & obj ) {
00074 return str << PMError( obj );
00075 }
00076 };
00077
00079
00080 #endif // YouError_h
00081