Home | History | Annotate | Download | only in errors

Lines Matching refs:Error

17 class Error;  // Forward declaration.
19 using ErrorPtr = std::unique_ptr<Error>;
21 class BRILLO_EXPORT Error {
23 virtual ~Error() = default;
25 // Creates an instance of Error class.
35 // If |error| is not nullptr, creates another instance of Error class,
37 // the error chain pointed to by |error|.
38 static void AddTo(ErrorPtr* error,
43 // Same as the Error::AddTo above, but allows to pass in a printf-like
44 // format string and optional parameters to format the error message.
45 static void AddToPrintf(ErrorPtr* error,
52 // Clones error with all inner errors.
55 // Returns the error domain, code and message
60 // Returns the location of the error in the source code.
66 // error domain.
70 // specified error domain and code.
73 // Gets a pointer to the inner error, if present. Returns nullptr otherwise.
74 const Error* GetInnerError() const { return inner_error_.get(); }
76 // Gets a pointer to the first error occurred.
77 // Returns itself if no inner error are available.
78 const Error* GetFirstError() const;
80 // Finds an error object of particular domain in the error chain stating at
81 // |error_chain_start|. Returns the a pointer to the first matching error
86 static const Error* FindErrorOfDomain(const Error* error_chain_start,
88 // Finds an error of particular domain with the given code in the error chain
90 // error object.
92 static const Error* FindError(const Error* error_chain_start,
99 Error(const tracked_objects::Location& location,
105 Error(const tracked_objects::LocationSnapshot& location,
111 // Error domain. The domain defines the scopes for error codes.
114 // Error code. A unique error code identifier within the given domain.
116 // Human-readable error message.
118 // Error origin in the source code.
120 // Pointer to inner error, if any. This forms a chain of errors.
124 DISALLOW_COPY_AND_ASSIGN(Error);