comparison PalanthirCppClient/HttpException.h @ 50:a15e90e5d6fc

rename in code
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 05 Sep 2012 15:50:12 +0200
parents 33d67e1ab173
children
comparison
equal deleted inserted replaced
49:e1a3ae0dadf3 50:a15e90e5d6fc
1 /** 1 /**
2 * Palantir - A Lightweight, RESTful DICOM Store 2 * Palanthir - 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 * Permission is hereby granted, free of charge, to any person 6 * Permission is hereby granted, free of charge, to any person
7 * obtaining a copy of this software and associated documentation 7 * obtaining a copy of this software and associated documentation
29 29
30 #include "HttpEnumerations.h" 30 #include "HttpEnumerations.h"
31 31
32 #include <string> 32 #include <string>
33 33
34 namespace Palantir 34 namespace Palanthir
35 { 35 {
36 class HttpException 36 class HttpException
37 { 37 {
38 private: 38 private:
39 Palantir_HttpStatus status_; 39 Palanthir_HttpStatus status_;
40 std::string custom_; 40 std::string custom_;
41 41
42 public: 42 public:
43 static const char* GetDescription(Palantir_HttpStatus status); 43 static const char* GetDescription(Palanthir_HttpStatus status);
44 44
45 HttpException(const std::string& custom) 45 HttpException(const std::string& custom)
46 { 46 {
47 status_ = Palantir_HttpStatus_None; 47 status_ = Palanthir_HttpStatus_None;
48 custom_ = custom; 48 custom_ = custom;
49 } 49 }
50 50
51 HttpException(Palantir_HttpStatus status) 51 HttpException(Palanthir_HttpStatus status)
52 { 52 {
53 status_ = status; 53 status_ = status;
54 } 54 }
55 55
56 Palantir_HttpStatus GetHttpStatus() const 56 Palanthir_HttpStatus GetHttpStatus() const
57 { 57 {
58 return status_; 58 return status_;
59 } 59 }
60 60
61 const char* What() const; 61 const char* What() const;