00001 00008 #pragma once 00009 00010 #include <string> 00011 00012 #include "wiscdb_exception.h" 00013 #include "include/types.h" 00014 00015 namespace wiscdb { 00016 00021 class InsufficientSpaceException : public WiscDbException { 00022 public: 00031 InsufficientSpaceException(const PageId page_num, 00032 const std::size_t requested, 00033 const std::size_t available); 00034 00038 PageId page_number() const { return page_number_; } 00039 00043 std::size_t space_requested() const { return space_requested_; } 00044 00048 std::size_t space_available() const { return space_available_; } 00049 00050 protected: 00054 const PageId page_number_; 00055 00059 const std::size_t space_requested_; 00060 00064 const std::size_t space_available_; 00065 }; 00066 00067 }