Safe Haskell | None |
---|---|
Language | Haskell2010 |
BDCS.API.Utils
Description
Utility functions for BDCS.API
- applyLimits :: Int -> Int -> [a] -> [a]
- argify :: Foldable t => t String -> [String]
- caseInsensitive :: String -> String -> Ordering
- caseInsensitiveT :: Text -> Text -> Ordering
- data GitLock = GitLock {
- gitRepoLock :: RWLock
- gitRepo :: Repository
- maybeIO :: IO a -> IO (Maybe a)
- maybeThrow :: Exception e => e -> Maybe a -> IO a
Documentation
applyLimits :: Int -> Int -> [a] -> [a] Source #
Apply limit and offset to a list.
argify :: Foldable t => t String -> [String] Source #
Take a list of possiby comma, or comma-space, separated options and turn it into a list of options
caseInsensitive :: String -> String -> Ordering Source #
Compare 2 strings case-insensitively
Takes into account unicode
caseInsensitiveT :: Text -> Text -> Ordering Source #
Compare 2 T.Text's case-insensitively
Takes into account unicode
Git Repository and its RWLock
This is used to control access to the Git repository. Users should take the lock like this:
RWL.withRead (gitRepoLock repoLock)
Constructors
GitLock | |
Fields
|