layout
This commit is contained in:
parent
f596084a59
commit
455fca65bf
1 changed files with 5 additions and 8 deletions
|
@ -18,14 +18,11 @@ data KeySource = KeySource
|
||||||
, contentLocation :: FilePath
|
, contentLocation :: FilePath
|
||||||
}
|
}
|
||||||
|
|
||||||
data BackendA a = Backend {
|
data BackendA a = Backend
|
||||||
-- name of this backend
|
{ name :: String
|
||||||
name :: String,
|
, getKey :: KeySource -> a (Maybe Key)
|
||||||
-- gets the key to use for a given content
|
, fsckKey :: Maybe (Key -> FilePath -> a Bool)
|
||||||
getKey :: KeySource -> a (Maybe Key),
|
}
|
||||||
-- called during fsck to check a key, if the backend has its own checks
|
|
||||||
fsckKey :: Maybe (Key -> FilePath -> a Bool)
|
|
||||||
}
|
|
||||||
|
|
||||||
instance Show (BackendA a) where
|
instance Show (BackendA a) where
|
||||||
show backend = "Backend { name =\"" ++ name backend ++ "\" }"
|
show backend = "Backend { name =\"" ++ name backend ++ "\" }"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue