![]() |
User Manual, Developers Guide and API Documentation |
![]() |
#include <Exception.hpp>
Inherits wns::IOutputStreamable, and exception.
Inherited by rise::plmapping::PhyMode::UndefinedException, rise::scenario::pathloss::Deny::Exception, rise::scenario::Propagation::NoModelError, wimac::service::CIDNotFound, wns::Assure::Exception, wns::ChamaeleonBase::BadCast, wns::CloneNotSupported, wns::container::RangeMap< RangeType, ValueType, CleanupStrategy >::Exception, wns::container::Registry< KEY, ELEMENT, CLEANUPPOLICY, SORTINGPOLICY >::DuplicateKeyValue, wns::container::Registry< KEY, ELEMENT, CLEANUPPOLICY, SORTINGPOLICY >::UnknownKeyValue, wns::events::scheduler::ICommand::CancelException [private], wns::events::scheduler::IEvent::CancelException [private], wns::ldk::FlowSeparator::InstanceNotFound, wns::ldk::fun::FindFriendException, wns::ldk::harq::softcombining::Container< T >::InvalidPositionInTB, wns::ldk::harq::softcombining::Container< T >::InvalidRV, wns::NullException, wns::probe::bus::context::DuplicateKey, wns::probe::bus::context::NotFound, wns::probe::bus::context::TypeError, wns::probe::bus::detail::Table< T >::OutOfRange, wns::scheduler::queue::detail::InnerQueue::RequestBelowMinimumSize, wns::scheduler::queue::detail::InnerQueue::RetrieveException, wns::simulator::ModuleDependencyMismatchException, and wns::simulator::StatusReport::WriteError.

Public Member Functions | |
| Exception (const std::string &s) | |
| String s is set as reason. | |
| Exception () | |
| Creates empty Exception (contains no reason). | |
| const Backtrace & | getBacktrace () const |
| Return the backtrace of the stack at creation time of this Exception. | |
| virtual const char * | what () const throw () |
| Return the reason as C-style character string. | |
| virtual | ~Exception () throw () |
| Destructor. | |
Protected Member Functions | |
| virtual std::string | doToString () const |
| Represent the Exception as std::string. | |
Private Attributes | |
| Backtrace | backtrace_ |
| Backtrace of the current stack, taken at creation of time of the Exception. | |
| std::string | reason_ |
| String containing the reason for the exception. | |
Friends | |
| template<typename T> | |
| Exception & | operator<< (Exception &e, const T &t) |
| Allows using Exceptions like streams. | |
Definition at line 48 of file Exception.hpp.
| Exception::Exception | ( | ) |
Definition at line 32 of file Exception.cpp.
| Exception::Exception | ( | const std::string & | s | ) | [explicit] |
Reimplemented in wns::Assure::Exception, wns::container::RangeMap< RangeType, ValueType, CleanupStrategy >::Exception, and rise::scenario::pathloss::Deny::Exception.
Definition at line 41 of file Exception.cpp.
| Exception::~Exception | ( | ) | throw () [virtual] |
Reimplemented in wns::Assure::Exception, wns::container::RangeMap< RangeType, ValueType, CleanupStrategy >::Exception, and rise::scenario::pathloss::Deny::Exception.
Definition at line 50 of file Exception.cpp.
| std::string Exception::doToString | ( | ) | const [protected, virtual] |
| const wns::Backtrace & Exception::getBacktrace | ( | ) | const |
Can be used in streams like this:
std::cerr << exception.getBacktrace() << std::endl;
Definition at line 61 of file Exception.cpp.
| const char * Exception::what | ( | ) | const throw () [virtual] |
Definition at line 55 of file Exception.cpp.
Usgae: excp << "Reason: invalid argument";
Definition at line 97 of file Exception.hpp.
Backtrace wns::Exception::backtrace_ [private] |
Definition at line 122 of file Exception.hpp.
std::string wns::Exception::reason_ [private] |
Definition at line 116 of file Exception.hpp.
1.5.5