{-# LANGUAGE DeriveAnyClass #-}
module IHP.Router.Types where
import IHP.Prelude
import Network.HTTP.Types.Method
data TypedAutoRouteError
= BadType
{ TypedAutoRouteError -> ByteString
expectedType :: !ByteString
, TypedAutoRouteError -> Maybe ByteString
value :: !(Maybe ByteString)
, TypedAutoRouteError -> ByteString
field :: !ByteString
}
| TooFewArguments
| NotMatched
| NoConstructorMatched
{ expectedType :: !ByteString
, value :: !(Maybe ByteString)
, field :: !ByteString
}
deriving (Int -> TypedAutoRouteError -> ShowS
[TypedAutoRouteError] -> ShowS
TypedAutoRouteError -> String
(Int -> TypedAutoRouteError -> ShowS)
-> (TypedAutoRouteError -> String)
-> ([TypedAutoRouteError] -> ShowS)
-> Show TypedAutoRouteError
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> TypedAutoRouteError -> ShowS
showsPrec :: Int -> TypedAutoRouteError -> ShowS
$cshow :: TypedAutoRouteError -> String
show :: TypedAutoRouteError -> String
$cshowList :: [TypedAutoRouteError] -> ShowS
showList :: [TypedAutoRouteError] -> ShowS
Show, Show TypedAutoRouteError
Typeable TypedAutoRouteError
(Typeable TypedAutoRouteError, Show TypedAutoRouteError) =>
(TypedAutoRouteError -> SomeException)
-> (SomeException -> Maybe TypedAutoRouteError)
-> (TypedAutoRouteError -> String)
-> Exception TypedAutoRouteError
SomeException -> Maybe TypedAutoRouteError
TypedAutoRouteError -> String
TypedAutoRouteError -> SomeException
forall e.
(Typeable e, Show e) =>
(e -> SomeException)
-> (SomeException -> Maybe e) -> (e -> String) -> Exception e
$ctoException :: TypedAutoRouteError -> SomeException
toException :: TypedAutoRouteError -> SomeException
$cfromException :: SomeException -> Maybe TypedAutoRouteError
fromException :: SomeException -> Maybe TypedAutoRouteError
$cdisplayException :: TypedAutoRouteError -> String
displayException :: TypedAutoRouteError -> String
Exception)
data UnexpectedMethodException
= UnexpectedMethodException
{ UnexpectedMethodException -> [StdMethod]
allowedMethods :: [StdMethod]
, UnexpectedMethodException -> StdMethod
method :: StdMethod
}
deriving (Int -> UnexpectedMethodException -> ShowS
[UnexpectedMethodException] -> ShowS
UnexpectedMethodException -> String
(Int -> UnexpectedMethodException -> ShowS)
-> (UnexpectedMethodException -> String)
-> ([UnexpectedMethodException] -> ShowS)
-> Show UnexpectedMethodException
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> UnexpectedMethodException -> ShowS
showsPrec :: Int -> UnexpectedMethodException -> ShowS
$cshow :: UnexpectedMethodException -> String
show :: UnexpectedMethodException -> String
$cshowList :: [UnexpectedMethodException] -> ShowS
showList :: [UnexpectedMethodException] -> ShowS
Show, Show UnexpectedMethodException
Typeable UnexpectedMethodException
(Typeable UnexpectedMethodException,
Show UnexpectedMethodException) =>
(UnexpectedMethodException -> SomeException)
-> (SomeException -> Maybe UnexpectedMethodException)
-> (UnexpectedMethodException -> String)
-> Exception UnexpectedMethodException
SomeException -> Maybe UnexpectedMethodException
UnexpectedMethodException -> String
UnexpectedMethodException -> SomeException
forall e.
(Typeable e, Show e) =>
(e -> SomeException)
-> (SomeException -> Maybe e) -> (e -> String) -> Exception e
$ctoException :: UnexpectedMethodException -> SomeException
toException :: UnexpectedMethodException -> SomeException
$cfromException :: SomeException -> Maybe UnexpectedMethodException
fromException :: SomeException -> Maybe UnexpectedMethodException
$cdisplayException :: UnexpectedMethodException -> String
displayException :: UnexpectedMethodException -> String
Exception)