comparison Core/OrthancException.h @ 59:c996319e90bc orthanc-renaming

renaming in Core
author Sebastien Jodogne <s.jodogne@gmail.com>
date Sun, 16 Sep 2012 09:28:56 +0200
parents 6da7fc87efaa
children fe180eae201d
comparison
equal deleted inserted replaced
58:6da7fc87efaa 59:c996319e90bc
1 /** 1 /**
2 * Palanthir - A Lightweight, RESTful DICOM Store 2 * Orthanc - A Lightweight, RESTful DICOM Store
3 * Copyright (C) 2012 Medical Physics Department, CHU of Liege, 3 * Copyright (C) 2012 Medical Physics Department, CHU of Liege,
4 * Belgium 4 * Belgium
5 * 5 *
6 * This program is free software: you can redistribute it and/or 6 * This program is free software: you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as 7 * modify it under the terms of the GNU General Public License as
21 #pragma once 21 #pragma once
22 22
23 #include <string> 23 #include <string>
24 #include "Enumerations.h" 24 #include "Enumerations.h"
25 25
26 namespace Palanthir 26 namespace Orthanc
27 { 27 {
28 class PalanthirException 28 class OrthancException
29 { 29 {
30 private: 30 private:
31 ErrorCode error_; 31 ErrorCode error_;
32 std::string custom_; 32 std::string custom_;
33 33
34 public: 34 public:
35 static const char* GetDescription(ErrorCode error); 35 static const char* GetDescription(ErrorCode error);
36 36
37 PalanthirException(const std::string& custom) 37 OrthancException(const std::string& custom)
38 { 38 {
39 error_ = ErrorCode_Custom; 39 error_ = ErrorCode_Custom;
40 custom_ = custom; 40 custom_ = custom;
41 } 41 }
42 42
43 PalanthirException(ErrorCode error) 43 OrthancException(ErrorCode error)
44 { 44 {
45 error_ = error; 45 error_ = error;
46 } 46 }
47 47
48 ErrorCode GetErrorCode() const 48 ErrorCode GetErrorCode() const