litert:: Error
#include <litert_expected.h>
A C++ wrapper for a LiteRtStatus code, providing a status and an error message.
Summary
Constructors and Destructors |
|
|---|---|
Error(::litert::Status status, std::string message)
Constructs an
Error from a status and an optional error message. |
|
Error(LiteRtStatus status, std::string message)
|
Public functions |
|
|---|---|
Message() const
|
const std::string &
Gets the error message.
|
Status() const
|
constexpr LiteRtStatus
|
StatusCC() const
|
constexpr::litert::Status
Gets the status.
|
Friend classes |
|
|---|---|
AbslStringify
|
friend void
|
operator<<
|
friend std::ostream &
|
Public functions
Error
Error( ::litert::Status status, std::string message )
Constructs an Error from a status and an optional error message.
Error
Error( LiteRtStatus status, std::string message )
Message
const std::string & Message() const
Gets the error message.
Returns an empty string if none was attached.
Status
constexpr LiteRtStatus Status() const
StatusCC
constexpr::litert::Status StatusCC() const
Gets the status.
Friend classes
AbslStringify
friend void AbslStringify(Sink &sink, const Error &error)
operator<<
friend std::ostream & operator<<(std::ostream &stream, const Error &error)