wisc_db
bad_buffer_exception.cpp
1 
8 #include "bad_buffer_exception.h"
9 
10 #include <sstream>
11 #include <string>
12 
13 namespace wiscdb {
14 
15 BadBufferException::BadBufferException(FrameId frameNoIn, bool dirtyIn, bool validIn, bool refbitIn)
16  : WiscDbException(""), frameNo(frameNoIn), dirty(dirtyIn), valid(validIn), refbit(refbitIn) {
17  std::stringstream ss;
18  ss << "This buffer is bad: " << frameNo;
19  message_.assign(ss.str());
20 }
21 
22 }
Definition: buffer.h:14
std::uint32_t FrameId
Identifier for a frame in buffer pool.
Definition: types.h:25
Base class for all WiscDB-specific exceptions.
BadBufferException(FrameId frameNoIn, bool dirtyIn, bool validIn, bool refbitIn)