| Copyright | Copyright © 2014 AlephCloud Systems, Inc. |
|---|---|
| License | MIT |
| Maintainer | Lars Kuhtz <lars@alephcloud.com> |
| Stability | experimental |
| Safe Haskell | None |
| Language | Haskell2010 |
Configuration.Utils.Validation
Description
Utilities for validating configuration values
- validateHttpOrHttpsUrl :: Text -> ConfigValidation String λ
- validateHttpUrl :: Text -> ConfigValidation String λ
- validateHttpsUrl :: Text -> ConfigValidation String λ
- validateUri :: Text -> ConfigValidation String λ
- validateAbsoluteUri :: Text -> ConfigValidation String λ
- validateAbsoluteUriFragment :: Text -> ConfigValidation String λ
- validateIPv4 :: Text -> ConfigValidation String λ
- validateIPv6 :: Text -> ConfigValidation String λ
- validatePort :: Text -> ConfigValidation Int λ
- validateNonEmpty :: (Eq α, Monoid α) => Text -> ConfigValidation α λ
- validateLength :: Foldable φ => Text -> Int -> ConfigValidation (φ α) λ
- validateMinLength :: Foldable φ => Text -> Int -> ConfigValidation (φ α) λ
- validateMaxLength :: Foldable φ => Text -> Int -> ConfigValidation (φ α) λ
- validateMinMaxLength :: Foldable φ => Text -> Int -> Int -> ConfigValidation (φ α) λ
- validateFilePath :: Text -> ConfigValidation FilePath λ
- validateFile :: Text -> ConfigValidation FilePath λ
- validateFileReadable :: Text -> ConfigValidation FilePath λ
- validateFileWritable :: Text -> ConfigValidation FilePath λ
- validateExecutable :: Text -> ConfigValidation FilePath λ
- validateDirectory :: Text -> ConfigValidation FilePath λ
Networking
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an HTTP or HTTPS URL
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an HTTP URL
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an HTTPS URL
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an URI without a fragment identifier
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an absolute URI without a fragment identifier
validateAbsoluteUriFragment Source
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Validates that a value is an absolute URI with an optional fragment identifier
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation String λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation Int λ |
Monoids, Foldables and Co
Arguments
| :: (Eq α, Monoid α) | |
| => Text | configuration property name that is used in the error message |
| -> ConfigValidation α λ |
Arguments
| :: Foldable φ | |
| => Text | configuration property name that is used in the error message |
| -> Int | exact length of the validated value |
| -> ConfigValidation (φ α) λ |
Arguments
| :: Foldable φ | |
| => Text | configuration property name that is used in the error message |
| -> Int | minimum length of the validated value |
| -> ConfigValidation (φ α) λ |
Arguments
| :: Foldable φ | |
| => Text | configuration property name that is used in the error message |
| -> Int | maximum length of the validated value |
| -> ConfigValidation (φ α) λ |
Arguments
| :: Foldable φ | |
| => Text | configuration property name that is used in the error message |
| -> Int | minimum length of the validated value |
| -> Int | maximum length of the validated value |
| -> ConfigValidation (φ α) λ |
Files
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |
Validates if the given executable name can be found in the system and can be executed.
Arguments
| :: Text | configuration property name that is used in the error message |
| -> ConfigValidation FilePath λ |