#include <iostream>
#include <sstream>
#include <string>
#include <typeinfo>
#include <stdexcept>
#include <vector>
#include <boost/filesystem.hpp>
#include <boost/config.hpp>
#include <nuklei/Definitions.h>
#include <nuklei/Log.h>
#include <nuklei/LoggingMacros.h>
#include <nuklei/LinearAlgebraTypes.h>
Go to the source code of this file.
Classes | |
class | nuklei::Error |
Nuklei-related errors. More... | |
class | nuklei::VerificationFailure |
class | nuklei::BadStrNumConversion |
Namespaces | |
nuklei | |
Public namespace. | |
Macros | |
#define | NUKLEI_UNIQUE_PTR_IMPL 2 |
#define | NUKLEI_UNIQUE_PTR std::unique_ptr |
#define | NUKLEI_MOVE(PTR) std::move(PTR) |
#define | NUKLEI_RELEASE(PTR) (PTR).release() |
#define | NUKLEI_NVP(x) #x << "=" << x |
Name-value pair. More... | |
#define | NUKLEI_HERE() |
String file:line. More... | |
#define | NUKLEI_THROW(x) |
Throws an Error. More... | |
#define | NUKLEI_ASSERT(expression) |
Throws an Error if expression is not true. More... | |
#define | NUKLEI_DEBUG_ASSERT NUKLEI_ASSERT |
#define | NUKLEI_FAST_ASSERT(expression) assert(expression) |
#define | NUKLEI_FAST_DEBUG_ASSERT NUKLEI_FAST_ASSERT |
#define | NUKLEI_ASSERT_AFE(e1, e2) |
#define | NUKLEI_ASSERT_AFE_TOL(e1, e2, tol) |
#define | NUKLEI_TRACE_BEGIN() try { |
#define | NUKLEI_TRACE_END() |
#define | NUKLEI_LBLACK "\033[0;30m" |
#define | NUKLEI_LRED "\033[0;31m" |
#define | NUKLEI_LGREEN "\033[0;32m" |
#define | NUKLEI_LBROWN "\033[0;33m" |
#define | NUKLEI_LBLUE "\033[0;34m" |
#define | NUKLEI_LPURPLE "\033[0;35m" |
#define | NUKLEI_LCYAN "\033[0;36m" |
#define | NUKLEI_LWHITE "\033[0;37m" |
#define | NUKLEI_DBLACK "\033[1;30m" |
#define | NUKLEI_DRED "\033[1;31m" |
#define | NUKLEI_DGREEN "\033[1;32m" |
#define | NUKLEI_DBROWN "\033[1;33m" |
#define | NUKLEI_DBLUE "\033[1;34m" |
#define | NUKLEI_DPURPLE "\033[1;35m" |
#define | NUKLEI_DCYAN "\033[1;36m" |
#define | NUKLEI_DWHITE "\033[1;37m" |
#define | NUKLEI_NOCOLOR "\033[0m" |
Functions | |
template<class T > | |
T const & | nuklei::as_const (T const &t) |
Provides a const reference to an object. | |
template<typename T > | |
std::string | nuklei::stringify (const T &x, int precision=-1, int width=0) |
Converts an object to a std::string using operator<<. | |
std::istream & | nuklei::operator>> (std::istream &in, Vector3 &l) |
std::istream & | nuklei::operator>> (std::istream &in, Quaternion &q) |
std::ostream & | nuklei::operator<< (std::ostream &out, const Quaternion &q) |
std::ostream & | nuklei::operator<< (std::ostream &out, const Matrix3 &m) |
std::istream & | nuklei::operator>> (std::istream &in, Matrix3 &m) |
template<typename ForwardIterator > | |
std::string | nuklei::stringifyRange (ForwardIterator first, ForwardIterator last, int precision=-1, int width=0) |
Converts a range to a std::string using operator<< on elements. | |
template<typename T > | |
T | nuklei::numify (const std::string &s, bool failIfLeftoverChars=true) |
Converts a string to an object using operator>>. | |
std::string & | nuklei::cleanLine (std::string &line) |
void | nuklei::copy_file (const std::string &input, const std::string &output) |
#define NUKLEI_ASSERT | ( | expression | ) |
Throws an Error if expression is not true.
Example usage: NUKLEI_ASSERT(i != 0);
Note that if a function throws, calling it is slow. Do not throw from functions that are supposed to execute fast.
For functions that have to go fast, use NUKLEI_FAST_ASSERT instead.
Do not use from within a destructor!
#define NUKLEI_ASSERT_AFE | ( | e1, | |
e2 | |||
) |
#define NUKLEI_ASSERT_AFE_TOL | ( | e1, | |
e2, | |||
tol | |||
) |
#define NUKLEI_HERE | ( | ) |
String file:line.
#define NUKLEI_NVP | ( | x | ) | #x << "=" << x |
Name-value pair.
Example usage: NUKLEI_THROW( NUKLEI_NVP(variable) );
#define NUKLEI_THROW | ( | x | ) |
Throws an Error.
Example usage: NUKLEI_THROW("int i is equal to " << i);
Note that if a function throws, calling it is slow. Do not throw from functions that are supposed to execute fast.
Do not use from within a destructor!
#define NUKLEI_TRACE_END | ( | ) |