9 #define MAGICKCORE_IMPLEMENTATION 1 10 #define MAGICK_PLUSPLUS_IMPLEMENTATION 1 37 : exception(original_),
38 _what(original_._what),
51 if (
this != &original_)
52 this->_what=original_._what;
58 return(_what.c_str());
91 :
Error(what_,nested_)
105 :
Error(what_,nested_)
119 :
Error(what_,nested_)
134 :
Error(what_,nested_)
149 :
Error(what_,nested_)
164 :
Error(what_,nested_)
178 :
Error(what_,nested_)
197 :
Error(what_,nested_)
208 :
Error(what_,nested_)
223 :
Error(what_,nested_)
237 :
Error(what_,nested_)
251 :
Error(what_,nested_)
265 :
Error(what_,nested_)
279 :
Error(what_,nested_)
295 :
Error(what_,nested_)
310 :
Error(what_,nested_)
324 :
Error(what_,nested_)
338 :
Error(what_,nested_)
353 :
Error(what_,nested_)
367 :
Error(what_,nested_)
520 const std::string& what_)
526 const std::string& what_,
Exception *nested_)
688 std::string message=GetClientName();
689 if (exception_->reason != (
char *) NULL)
691 message+=std::string(
": ");
692 message+=std::string(exception_->reason);
695 if (exception_->description != (
char *) NULL)
696 message +=
" (" + std::string(exception_->description) +
")";
703 switch (exception_->severity)
705 case MagickCore::BlobError:
706 case MagickCore::BlobFatalError:
708 case MagickCore::BlobWarning:
710 case MagickCore::CacheError:
711 case MagickCore::CacheFatalError:
713 case MagickCore::CacheWarning:
715 case MagickCore::CoderError:
716 case MagickCore::CoderFatalError:
718 case MagickCore::CoderWarning:
720 case MagickCore::ConfigureError:
721 case MagickCore::ConfigureFatalError:
723 case MagickCore::ConfigureWarning:
725 case MagickCore::CorruptImageError:
726 case MagickCore::CorruptImageFatalError:
728 case MagickCore::CorruptImageWarning:
730 case MagickCore::DelegateError:
731 case MagickCore::DelegateFatalError:
733 case MagickCore::DelegateWarning:
735 case MagickCore::DrawError:
736 case MagickCore::DrawFatalError:
738 case MagickCore::DrawWarning:
740 case MagickCore::FileOpenError:
741 case MagickCore::FileOpenFatalError:
743 case MagickCore::FileOpenWarning:
745 case MagickCore::ImageError:
746 case MagickCore::ImageFatalError:
748 case MagickCore::ImageWarning:
750 case MagickCore::MissingDelegateError:
751 case MagickCore::MissingDelegateFatalError:
753 case MagickCore::MissingDelegateWarning:
755 case MagickCore::ModuleError:
756 case MagickCore::ModuleFatalError:
758 case MagickCore::ModuleWarning:
760 case MagickCore::MonitorError:
761 case MagickCore::MonitorFatalError:
763 case MagickCore::MonitorWarning:
765 case MagickCore::OptionError:
766 case MagickCore::OptionFatalError:
768 case MagickCore::OptionWarning:
770 case MagickCore::PolicyWarning:
772 case MagickCore::PolicyError:
773 case MagickCore::PolicyFatalError:
775 case MagickCore::RegistryError:
776 case MagickCore::RegistryFatalError:
778 case MagickCore::RegistryWarning:
780 case MagickCore::ResourceLimitError:
781 case MagickCore::ResourceLimitFatalError:
783 case MagickCore::ResourceLimitWarning:
785 case MagickCore::StreamError:
786 case MagickCore::StreamFatalError:
788 case MagickCore::StreamWarning:
790 case MagickCore::TypeError:
791 case MagickCore::TypeFatalError:
793 case MagickCore::TypeWarning:
795 case MagickCore::UndefinedException:
798 case MagickCore::XServerError:
799 case MagickCore::XServerFatalError:
801 case MagickCore::XServerWarning:
807 const MagickCore::ExceptionType severity_,
const char* reason_,
808 const char* description_)
811 if (severity_ == MagickCore::UndefinedException)
815 ThrowException(exceptionInfo,severity_,reason_,description_);
829 MagickCore::ExceptionType
839 if (exception_->severity == MagickCore::UndefinedException)
843 nestedException=(Exception *) NULL;
844 q=(Exception *) NULL;
845 LockSemaphoreInfo(exception_->semaphore);
846 if (exception_->exceptions != (
void *) NULL)
848 index=GetNumberOfElementsInLinkedList((LinkedListInfo *)
849 exception_->exceptions);
852 p=(
const ExceptionInfo *) GetValueFromLinkedList((LinkedListInfo *)
853 exception_->exceptions,--index);
854 if ((p->severity != exception_->severity) || (LocaleCompare(p->reason,
855 exception_->reason) != 0) || (LocaleCompare(p->description,
856 exception_->description) != 0))
858 if (nestedException == (Exception *) NULL)
875 severity=exception_->severity;
876 UnlockSemaphoreInfo(exception_->semaphore);
878 if ((quiet_) && (severity < MagickCore::ErrorException))
880 delete nestedException;
884 DestroyExceptionInfo(exception_);
888 case MagickCore::BlobError:
889 case MagickCore::BlobFatalError:
890 throw ErrorBlob(message,nestedException);
891 case MagickCore::BlobWarning:
892 throw WarningBlob(message,nestedException);
893 case MagickCore::CacheError:
894 case MagickCore::CacheFatalError:
895 throw ErrorCache(message,nestedException);
896 case MagickCore::CacheWarning:
897 throw WarningCache(message,nestedException);
898 case MagickCore::CoderError:
899 case MagickCore::CoderFatalError:
900 throw ErrorCoder(message,nestedException);
901 case MagickCore::CoderWarning:
902 throw WarningCoder(message,nestedException);
903 case MagickCore::ConfigureError:
904 case MagickCore::ConfigureFatalError:
905 throw ErrorConfigure(message,nestedException);
906 case MagickCore::ConfigureWarning:
907 throw WarningConfigure(message,nestedException);
908 case MagickCore::CorruptImageError:
909 case MagickCore::CorruptImageFatalError:
910 throw ErrorCorruptImage(message,nestedException);
911 case MagickCore::CorruptImageWarning:
912 throw WarningCorruptImage(message,nestedException);
913 case MagickCore::DelegateError:
914 case MagickCore::DelegateFatalError:
915 throw ErrorDelegate(message,nestedException);
916 case MagickCore::DelegateWarning:
917 throw WarningDelegate(message,nestedException);
918 case MagickCore::DrawError:
919 case MagickCore::DrawFatalError:
920 throw ErrorDraw(message,nestedException);
921 case MagickCore::DrawWarning:
922 throw WarningDraw(message,nestedException);
923 case MagickCore::FileOpenError:
924 case MagickCore::FileOpenFatalError:
925 throw ErrorFileOpen(message,nestedException);
926 case MagickCore::FileOpenWarning:
927 throw WarningFileOpen(message,nestedException);
928 case MagickCore::ImageError:
929 case MagickCore::ImageFatalError:
930 throw ErrorImage(message,nestedException);
931 case MagickCore::ImageWarning:
932 throw WarningImage(message,nestedException);
933 case MagickCore::MissingDelegateError:
934 case MagickCore::MissingDelegateFatalError:
935 throw ErrorMissingDelegate(message,nestedException);
936 case MagickCore::MissingDelegateWarning:
937 throw WarningMissingDelegate(message,nestedException);
938 case MagickCore::ModuleError:
939 case MagickCore::ModuleFatalError:
940 throw ErrorModule(message,nestedException);
941 case MagickCore::ModuleWarning:
942 throw WarningModule(message,nestedException);
943 case MagickCore::MonitorError:
944 case MagickCore::MonitorFatalError:
945 throw ErrorMonitor(message,nestedException);
946 case MagickCore::MonitorWarning:
947 throw WarningMonitor(message,nestedException);
948 case MagickCore::OptionError:
949 case MagickCore::OptionFatalError:
950 throw ErrorOption(message,nestedException);
951 case MagickCore::OptionWarning:
952 throw WarningOption(message,nestedException);
953 case MagickCore::PolicyWarning:
954 throw WarningPolicy(message,nestedException);
955 case MagickCore::PolicyError:
956 case MagickCore::PolicyFatalError:
957 throw ErrorPolicy(message,nestedException);
958 case MagickCore::RegistryError:
959 case MagickCore::RegistryFatalError:
960 throw ErrorRegistry(message,nestedException);
961 case MagickCore::RegistryWarning:
962 throw WarningRegistry(message,nestedException);
963 case MagickCore::ResourceLimitError:
964 case MagickCore::ResourceLimitFatalError:
965 throw ErrorResourceLimit(message,nestedException);
966 case MagickCore::ResourceLimitWarning:
967 throw WarningResourceLimit(message,nestedException);
968 case MagickCore::StreamError:
969 case MagickCore::StreamFatalError:
970 throw ErrorStream(message,nestedException);
971 case MagickCore::StreamWarning:
972 throw WarningStream(message,nestedException);
973 case MagickCore::TypeError:
974 case MagickCore::TypeFatalError:
975 throw ErrorType(message,nestedException);
976 case MagickCore::TypeWarning:
977 throw WarningType(message,nestedException);
978 case MagickCore::UndefinedException:
980 throw ErrorUndefined(message,nestedException);
981 case MagickCore::XServerError:
982 case MagickCore::XServerFatalError:
983 throw ErrorXServer(message,nestedException);
984 case MagickCore::XServerWarning:
985 throw WarningXServer(message,nestedException);
virtual const char * what() const
WarningMissingDelegate(const std::string &what_)
WarningXServer(const std::string &what_)
ErrorDelegate(const std::string &what_)
ErrorImage(const std::string &what_)
WarningDraw(const std::string &what_)
WarningCoder(const std::string &what_)
WarningMonitor(const std::string &what_)
ErrorFileOpen(const std::string &what_)
Error(const std::string &what_)
ErrorUndefined(const std::string &what_)
WarningOption(const std::string &what_)
WarningRegistry(const std::string &what_)
WarningDelegate(const std::string &what_)
WarningStream(const std::string &what_)
WarningPolicy(const std::string &what_)
const Exception * nested() const
std::string formatExceptionMessage(const MagickCore::ExceptionInfo *exception_)
ErrorRegistry(const std::string &what_)
MagickPPExport void throwException(MagickCore::ExceptionInfo *exception_, const bool quiet_=false)
WarningResourceLimit(const std::string &what_)
WarningModule(const std::string &what_)
WarningUndefined(const std::string &what_)
WarningBlob(const std::string &what_)
ErrorCache(const std::string &what_)
Warning(const std::string &what_)
ErrorOption(const std::string &what_)
ErrorStream(const std::string &what_)
WarningCorruptImage(const std::string &what_)
MagickPPExport void throwExceptionExplicit(const MagickCore::ExceptionType severity_, const char *reason_, const char *description_=(char *) NULL)
WarningCache(const std::string &what_)
ErrorXServer(const std::string &what_)
ErrorPolicy(const std::string &what_)
ErrorBlob(const std::string &what_)
ErrorCorruptImage(const std::string &what_)
#define ThrowPPException(quiet)
WarningFileOpen(const std::string &what_)
ErrorResourceLimit(const std::string &what_)
ErrorCoder(const std::string &what_)
~WarningMissingDelegate()
ErrorType(const std::string &what_)
WarningImage(const std::string &what_)
ErrorModule(const std::string &what_)
ErrorDraw(const std::string &what_)
Exception & operator=(const Exception &original_)
ErrorMonitor(const std::string &what_)
Exception * createException(const MagickCore::ExceptionInfo *exception_)
Exception(const std::string &what_)
ErrorMissingDelegate(const std::string &what_)
WarningType(const std::string &what_)