hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
proto_error_query_response.hpp
Go to the documentation of this file.
1 
6 #ifndef IROHA_SHARED_MODEL_PROTO_ERROR_RESPONSE_HPP
7 #define IROHA_SHARED_MODEL_PROTO_ERROR_RESPONSE_HPP
8 
12 #include "qry_responses.pb.h"
13 
14 namespace shared_model {
15  namespace proto {
16  class ErrorQueryResponse final
17  : public CopyableProto<interface::ErrorQueryResponse,
18  iroha::protocol::QueryResponse,
19  ErrorQueryResponse> {
20  public:
23  boost::variant<StatelessFailedErrorResponse,
32 
35  ProtoQueryErrorResponseVariantType::types;
36 
37  template <typename QueryResponseType>
38  explicit ErrorQueryResponse(QueryResponseType &&response);
39 
41 
43 
44  const QueryErrorResponseVariantType &get() const override;
45 
46  const ErrorMessageType &errorMessage() const override;
47 
48  ErrorCodeType errorCode() const override;
49 
50  private:
52 
53  const QueryErrorResponseVariantType ivariant_;
54  };
55  } // namespace proto
56 } // namespace shared_model
57 
58 #endif // IROHA_SHARED_MODEL_PROTO_ERROR_RESPONSE_HPP
TrivialProto< interface::NoAssetErrorResponse, iroha::protocol::ErrorResponse > NoAssetErrorResponse
Definition: proto_concrete_error_query_response.hpp:45
TrivialProto< interface::StatelessFailedErrorResponse, iroha::protocol::ErrorResponse > StatelessFailedErrorResponse
Definition: proto_concrete_error_query_response.hpp:25
TrivialProto< interface::NoAccountAssetsErrorResponse, iroha::protocol::ErrorResponse > NoAccountAssetsErrorResponse
Definition: proto_concrete_error_query_response.hpp:34
std::string ErrorMessageType
Message type.
Definition: error_query_response.hpp:56
w< StatelessFailedErrorResponse, StatefulFailedErrorResponse, NoAccountErrorResponse, NoAccountAssetsErrorResponse, NoAccountDetailErrorResponse, NoSignatoriesErrorResponse, NotSupportedErrorResponse, NoAssetErrorResponse, NoRolesErrorResponse > QueryErrorResponseVariantType
Type of container with all concrete error query responses.
Definition: error_query_response.hpp:45
TrivialProto< interface::StatefulFailedErrorResponse, iroha::protocol::ErrorResponse > StatefulFailedErrorResponse
Definition: proto_concrete_error_query_response.hpp:28
TrivialProto< interface::NoAccountDetailErrorResponse, iroha::protocol::ErrorResponse > NoAccountDetailErrorResponse
Definition: proto_concrete_error_query_response.hpp:37
TrivialProto< interface::NoSignatoriesErrorResponse, iroha::protocol::ErrorResponse > NoSignatoriesErrorResponse
Definition: proto_concrete_error_query_response.hpp:40
ProtoQueryErrorResponseVariantType::types ProtoQueryErrorResponseListType
list of types in proto variant
Definition: proto_error_query_response.hpp:35
ErrorCodeType errorCode() const override
Definition: proto_error_query_response.cpp:53
ErrorQueryResponse(QueryResponseType &&response)
Definition: proto_error_query_response.cpp:13
const ErrorMessageType & errorMessage() const override
Definition: proto_error_query_response.cpp:49
uint32_t ErrorCodeType
Error code type.
Definition: error_query_response.hpp:64
TrivialProto< interface::NotSupportedErrorResponse, iroha::protocol::ErrorResponse > NotSupportedErrorResponse
Definition: proto_concrete_error_query_response.hpp:43
const QueryErrorResponseVariantType & get() const override
Definition: proto_error_query_response.cpp:44
Definition: trivial_proto.hpp:19
TrivialProto< interface::NoAccountErrorResponse, iroha::protocol::ErrorResponse > NoAccountErrorResponse
Definition: proto_concrete_error_query_response.hpp:31
boost::variant< StatelessFailedErrorResponse, StatefulFailedErrorResponse, NoAccountErrorResponse, NoAccountAssetsErrorResponse, NoAccountDetailErrorResponse, NoSignatoriesErrorResponse, NotSupportedErrorResponse, NoAssetErrorResponse, NoRolesErrorResponse > ProtoQueryErrorResponseVariantType
type of proto variant
Definition: proto_error_query_response.hpp:31
Definition: command_executor.hpp:12
Definition: proto_error_query_response.hpp:16
Definition: trivial_proto.hpp:45