Safe Haskell | None |
---|---|
Language | Haskell2010 |
Servant.Client.Core.ClientError
Synopsis
- data ClientError
- = FailureResponse (RequestF () (BaseUrl, ByteString)) Response
- | DecodeFailure Text Response
- | UnsupportedContentType MediaType Response
- | InvalidContentTypeHeader Response
- | ConnectionError SomeException
Documentation
data ClientError Source #
A type representing possible errors in a request
Note that this type substantially changed in 0.12.
Constructors
FailureResponse (RequestF () (BaseUrl, ByteString)) Response | The server returned an error response including the
failing request. |
DecodeFailure Text Response | The body could not be decoded at the expected type |
UnsupportedContentType MediaType Response | The content-type of the response is not supported |
InvalidContentTypeHeader Response | The content-type header is invalid |
ConnectionError SomeException | There was a connection error, and no response was received |
Instances
Eq ClientError Source # | |
Defined in Servant.Client.Core.ClientError | |
Show ClientError Source # | |
Defined in Servant.Client.Core.ClientError Methods showsPrec :: Int -> ClientError -> ShowS show :: ClientError -> String showList :: [ClientError] -> ShowS | |
Generic ClientError Source # | |
Defined in Servant.Client.Core.ClientError Associated Types type Rep ClientError :: Type -> Type | |
NFData ClientError Source # | Note: an exception in |
Defined in Servant.Client.Core.ClientError Methods rnf :: ClientError -> () | |
Exception ClientError Source # | |
Defined in Servant.Client.Core.ClientError Methods toException :: ClientError -> SomeException fromException :: SomeException -> Maybe ClientError displayException :: ClientError -> String | |
type Rep ClientError Source # | |
Defined in Servant.Client.Core.ClientError type Rep ClientError = D1 ('MetaData "ClientError" "Servant.Client.Core.ClientError" "servant-client-core-0.18.3-CPuVNEacXg473k3Ui93oYu" 'False) ((C1 ('MetaCons "FailureResponse" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (RequestF () (BaseUrl, ByteString))) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Response)) :+: C1 ('MetaCons "DecodeFailure" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Response))) :+: (C1 ('MetaCons "UnsupportedContentType" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 MediaType) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Response)) :+: (C1 ('MetaCons "InvalidContentTypeHeader" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Response)) :+: C1 ('MetaCons "ConnectionError" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 SomeException))))) |