OriginException class abstract
An exception containing a failure message as a response from an API origin.
- Inheritance
-
- Object
- ApiException
- OriginException
- Implementers
Constructors
- OriginException(String message, {Uri? reference})
-
A default constructor of
message
and an optionalreference
.const - OriginException.of(String message, {Uri? reference, OriginFailure failure, int statusCode, String? reasonPhrase})
-
Create an exception of
message
,failure
andstatusCode
.factory
Properties
- failure → OriginFailure
-
Common failure type. By default
undefined
if not set.no setter - hashCode → int
-
The hash code for this object.
no setterinherited
- isBadRequest → bool
-
True if failure is
badRequest
.no setter - isForbidden → bool
-
True if failure is
forbidden
.no setter - isNotAcceptable → bool
-
True if failure is
notAcceptable
.no setter - isNotFound → bool
-
True if failure is
notFound
.no setter - isNotModified → bool
-
True if failure is
notModified
.no setter -
True if failure is
unauthorized
.no setter - message → String
-
The descriptive message.
finalinherited
- reasonPhrase → String?
-
Protocol (like HTTP) specific reason phrase. By default nul if not set.
no setter
- reference → Uri?
-
An optional URI reference for an API resoure.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- statusCode → int
-
Protocol (like HTTP) specific status code. By default 0 if not set.
no setter
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited