summaryrefslogtreecommitdiff
path: root/src/Hakyll/Core/ResourceProvider.hs
blob: 7b4f94af282ffb42df315b52c8d2a28f4ab33051 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
-- | This module provides an API for resource providers. Resource providers
-- allow Hakyll to get content from resources; the type of resource depends on
-- the concrete instance.
--
module Hakyll.Core.ResourceProvider
    ( ResourceProvider (..)
    ) where

import Hakyll.Core.Identifier

-- | A value responsible for retrieving and listing resources
--
data ResourceProvider = ResourceProvider
    { -- | A list of all resources this provider is able to provide
      resourceList   :: [Identifier]
    , -- | Retrieve a certain resource as string
      resourceString :: Identifier -> IO String
    }