aboutsummaryrefslogtreecommitdiff
path: root/Data/ConfigManager/Types/Internal.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Data/ConfigManager/Types/Internal.hs')
-rw-r--r--Data/ConfigManager/Types/Internal.hs9
1 files changed, 8 insertions, 1 deletions
diff --git a/Data/ConfigManager/Types/Internal.hs b/Data/ConfigManager/Types/Internal.hs
index c4d5d0e..4459b01 100644
--- a/Data/ConfigManager/Types/Internal.hs
+++ b/Data/ConfigManager/Types/Internal.hs
@@ -4,10 +4,11 @@ module Data.ConfigManager.Types.Internal
, Name
, Value
, Requirement(..)
+ , Configured
+ , convert
) where
import Data.Text (Text)
-
import Data.HashMap.Strict
-- | Configuration data.
@@ -37,3 +38,9 @@ data Requirement =
Required
| Optional
deriving (Eq, Read, Show)
+
+-- | This class represents types that can be converted /from/ a value /to/ a
+-- destination type
+
+class Configured a where
+ convert :: Value -> Maybe a