Google Cloud C++ Client  2.7.0
C++ Client Library for Google Cloud Platform
Public Member Functions | Friends | List of all members
google::cloud::ErrorInfo Class Reference

Describes the cause of the error with structured details. More...

#include <google/cloud/status.h>

Public Member Functions

 ErrorInfo ()=default
 
 ErrorInfo (std::string reason, std::string domain, std::unordered_map< std::string, std::string > metadata)
 
std::string const & reason () const
 
std::string const & domain () const
 
std::unordered_map< std::string, std::string > const & metadata () const
 

Friends

bool operator== (ErrorInfo const &, ErrorInfo const &)
 
bool operator!= (ErrorInfo const &, ErrorInfo const &)
 

Detailed Description

Describes the cause of the error with structured details.

See also
https://cloud.google.com/apis/design/errors#error_info

Definition at line 71 of file status.h.

Constructor & Destructor Documentation

◆ ErrorInfo() [1/2]

google::cloud::ErrorInfo::ErrorInfo ( )
default

◆ ErrorInfo() [2/2]

google::cloud::ErrorInfo::ErrorInfo ( std::string  reason,
std::string  domain,
std::unordered_map< std::string, std::string >  metadata 
)
inlineexplicit

Definition at line 74 of file status.h.

Member Function Documentation

◆ domain()

std::string const& google::cloud::ErrorInfo::domain ( ) const
inline

Definition at line 81 of file status.h.

◆ metadata()

std::unordered_map<std::string, std::string> const& google::cloud::ErrorInfo::metadata ( ) const
inline

Definition at line 82 of file status.h.

◆ reason()

std::string const& google::cloud::ErrorInfo::reason ( ) const
inline

Definition at line 80 of file status.h.

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( ErrorInfo const &  ,
ErrorInfo const &   
)
friend

◆ operator==

bool operator== ( ErrorInfo const &  ,
ErrorInfo const &   
)
friend