foscam-filename-0.0.3: Foscam File format

Safe HaskellNone
LanguageHaskell2010

Data.Foscam.File.AliasCharacter

Synopsis

Documentation

aliasCharacter :: (Monad f, CharParsing f) => f AliasCharacter Source #

>>> parse aliasCharacter "test" "2062"
Right (AliasCharacter '2')
>>> parse aliasCharacter "test" "2"
Right (AliasCharacter '2')
>>> parse aliasCharacter "test" "abc"
Right (AliasCharacter 'a')
>>> parse aliasCharacter "test" "*"
Left "test" (line 1, column 2):
not an alias character: *
>>> parse aliasCharacter "test" "<"
Left "test" (line 1, column 2):
not an alias character: <
>>> parse aliasCharacter "test" ""
Left "test" (line 1, column 1):
unexpected end of input
expecting alias character