WPILibC++  unspecified
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Pages
TableKeyNotDefinedException.h
1 /*----------------------------------------------------------------------------*/
2 /* Copyright (c) FIRST 2015. All Rights Reserved. */
3 /* Open Source Software - may be modified and shared by FRC teams. The code */
4 /* must be accompanied by the FIRST BSD license file in the root directory of */
5 /* the project. */
6 /*----------------------------------------------------------------------------*/
7 
8 #ifndef TABLEKEYNOTDEFINEDEXCEPTION_H_
9 #define TABLEKEYNOTDEFINEDEXCEPTION_H_
10 
11 #include <exception>
12 #include "llvm/StringRef.h"
13 
14 #if defined(_MSC_VER)
15 #define NT_NOEXCEPT throw()
16 #else
17 #define NT_NOEXCEPT noexcept
18 #endif
19 
23 class TableKeyNotDefinedException : public std::exception {
24  public:
28  TableKeyNotDefinedException(llvm::StringRef key);
29  ~TableKeyNotDefinedException() NT_NOEXCEPT;
30  const char* what() const NT_NOEXCEPT override;
31 
32  private:
33  std::string msg;
34 };
35 
36 #endif // TABLEKEYNOTDEFINEDEXCEPTION_H_
TableKeyNotDefinedException(llvm::StringRef key)
Definition: TableKeyNotDefinedException.cpp:10
An exception thrown when the lookup a a key-value fails in a ITable.
Definition: TableKeyNotDefinedException.h:23