Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- reform :: (MonadIO m, Monoid view) => ([(Text, Text)] -> view -> view) -> Text -> Form (TrasaT m) Text err view a -> TrasaT m (Result err a, view)
- reformQP :: (MonadIO m, Monoid view) => ([(Text, Text)] -> view -> view) -> Text -> Form (TrasaT m) QueryParam err view a -> TrasaT m (Result err a, view)
- reformPost :: (MonadIO m, Monoid view) => ([(Text, Text)] -> view -> view) -> Text -> ByteString -> Form (TrasaT m) QueryParam err view a -> TrasaT m (Result err a, view)
- liftParser :: (Text -> Either Text a) -> QueryParam -> Either Text a
- type TrasaForm a = Form (TrasaT IO) QueryParam Text (Html ()) a
- type TrasaSimpleForm a = Form (TrasaT IO) Text Text (Html ()) a
- class FormError input err where
- commonFormError :: CommonFormError input -> err
Documentation
liftParser :: (Text -> Either Text a) -> QueryParam -> Either Text a Source #
class FormError input err where #
A Class to lift a CommonFormError
into an application-specific error type
commonFormError :: CommonFormError input -> err #
Instances
FormError Text Text | |
Defined in Ditto.Backend commonFormError :: CommonFormError Text -> Text # | |
FormError QueryParam Text Source # | |
Defined in Trasa.Form |
Orphan instances
FormInput QueryParam Source # | |
type FileType QueryParam :: Type # getInputString :: FormError QueryParam err => QueryParam -> Either err String # getInputStrings :: QueryParam -> [String] # getInputText :: FormError QueryParam err => QueryParam -> Either err Text # getInputTexts :: QueryParam -> [Text] # getInputFile :: FormError QueryParam err => QueryParam -> Either err (FileType QueryParam) # | |
FormError QueryParam Text Source # | |