Electroneum
hw::trezor::exc::UnexpectedMessageException Class Reference

#include <transport.hpp>

Inheritance diagram for hw::trezor::exc::UnexpectedMessageException:
Collaboration diagram for hw::trezor::exc::UnexpectedMessageException:

Public Member Functions

 UnexpectedMessageException ()
 
 UnexpectedMessageException (hw::trezor::messages::MessageType recvType, const std::shared_ptr< google::protobuf::Message > &recvMsg)
 
 ProtocolException ()
 
- Public Member Functions inherited from hw::trezor::exc::ProtocolException
 ProtocolException ()
 
 CommunicationException ()
 
- Public Member Functions inherited from hw::trezor::exc::CommunicationException
 CommunicationException ()
 
 TrezorException ()
 
 TrezorException (std::string what)
 
- Public Member Functions inherited from hw::trezor::exc::TrezorException
 TrezorException ()
 
 TrezorException (std::string what)
 
virtual const char * what () const throw ()
 

Protected Attributes

hw::trezor::messages::MessageType recvType
 
std::shared_ptr< google::protobuf::Message > recvMsg
 
- Protected Attributes inherited from hw::trezor::exc::TrezorException
boost::optional< std::string > reason
 

Detailed Description

Definition at line 330 of file transport.hpp.

Constructor & Destructor Documentation

◆ UnexpectedMessageException() [1/2]

hw::trezor::exc::UnexpectedMessageException::UnexpectedMessageException ( )
inline

Definition at line 337 of file transport.hpp.

337 : ProtocolException("Trezor returned unexpected message") {};

◆ UnexpectedMessageException() [2/2]

hw::trezor::exc::UnexpectedMessageException::UnexpectedMessageException ( hw::trezor::messages::MessageType  recvType,
const std::shared_ptr< google::protobuf::Message > &  recvMsg 
)
inline

Definition at line 338 of file transport.hpp.

341  reason = std::string("Trezor returned unexpected message: ") + std::to_string(recvType);
342  }
boost::optional< std::string > reason
Definition: exceptions.hpp:62
::std::string string
Definition: gtest-port.h:1097
std::shared_ptr< google::protobuf::Message > recvMsg
Definition: transport.hpp:333
std::string to_string(t_connection_type type)
hw::trezor::messages::MessageType recvType
Definition: transport.hpp:332
Here is the call graph for this function:

Member Function Documentation

◆ ProtocolException()

hw::trezor::exc::ProtocolException::ProtocolException
inline

Definition at line 118 of file exceptions.hpp.

118 : CommunicationException("Trezor protocol error"){}

Member Data Documentation

◆ recvMsg

std::shared_ptr<google::protobuf::Message> hw::trezor::exc::UnexpectedMessageException::recvMsg
protected

Definition at line 333 of file transport.hpp.

◆ recvType

hw::trezor::messages::MessageType hw::trezor::exc::UnexpectedMessageException::recvType
protected

Definition at line 332 of file transport.hpp.


The documentation for this class was generated from the following file: