Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- parseUA :: ByteString -> Maybe UAResult
- parseUALenient :: ByteString -> UAResult
- data UAResult = UAResult {}
- uarVersion :: UAResult -> Text
- parseOS :: ByteString -> Maybe OSResult
- parseOSLenient :: ByteString -> OSResult
- data OSResult = OSResult {}
- osrVersion :: OSResult -> Text
- parseDev :: ByteString -> Maybe DevResult
- parseDevLenient :: ByteString -> DevResult
- data DevResult = DevResult {}
Parsing browser (user agent)
parseUALenient :: ByteString -> UAResult Source #
Parser that, upon failure to match a pattern returns a result of family Other with all other fields blank. This is mainly for compatibility with the uap-core test suite
Results datatype for the parsed User-Agent
Instances
Eq UAResult Source # | |
Data UAResult Source # | |
Defined in Web.UAParser gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> UAResult -> c UAResult # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c UAResult # toConstr :: UAResult -> Constr # dataTypeOf :: UAResult -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c UAResult) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c UAResult) # gmapT :: (forall b. Data b => b -> b) -> UAResult -> UAResult # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> UAResult -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> UAResult -> r # gmapQ :: (forall d. Data d => d -> u) -> UAResult -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> UAResult -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> UAResult -> m UAResult # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> UAResult -> m UAResult # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> UAResult -> m UAResult # | |
Read UAResult Source # | |
Show UAResult Source # | |
Generic UAResult Source # | |
Default UAResult Source # | |
Defined in Web.UAParser | |
type Rep UAResult Source # | |
Defined in Web.UAParser type Rep UAResult = D1 (MetaData "UAResult" "Web.UAParser" "ua-parser-0.7.5.1-7oJFys6DGaK2z7G8wrTp0C" False) (C1 (MetaCons "UAResult" PrefixI True) ((S1 (MetaSel (Just "uarFamily") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: S1 (MetaSel (Just "uarV1") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Text))) :*: (S1 (MetaSel (Just "uarV2") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Text)) :*: S1 (MetaSel (Just "uarV3") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Text))))) |
Parsing OS
parseOSLenient :: ByteString -> OSResult Source #
Parser that, upon failure to match a pattern returns a result of family Other with all other fields blank. This is mainly for compatibility with the uap-core test suite
Result type for parseOS
Instances
Parsing Dev
parseDevLenient :: ByteString -> DevResult Source #
Parser that, upon failure to match a pattern returns a result of family Other with all other fields blank. This is mainly for compatibility with the uap-core test suite
Result type for parseDev
Instances
Eq DevResult Source # | |
Data DevResult Source # | |
Defined in Web.UAParser gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> DevResult -> c DevResult # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c DevResult # toConstr :: DevResult -> Constr # dataTypeOf :: DevResult -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c DevResult) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c DevResult) # gmapT :: (forall b. Data b => b -> b) -> DevResult -> DevResult # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> DevResult -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> DevResult -> r # gmapQ :: (forall d. Data d => d -> u) -> DevResult -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> DevResult -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> DevResult -> m DevResult # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> DevResult -> m DevResult # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> DevResult -> m DevResult # | |
Read DevResult Source # | |
Show DevResult Source # | |
Generic DevResult Source # | |
Default DevResult Source # | |
Defined in Web.UAParser | |
type Rep DevResult Source # | |
Defined in Web.UAParser type Rep DevResult = D1 (MetaData "DevResult" "Web.UAParser" "ua-parser-0.7.5.1-7oJFys6DGaK2z7G8wrTp0C" False) (C1 (MetaCons "DevResult" PrefixI True) (S1 (MetaSel (Just "drFamily") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Text) :*: (S1 (MetaSel (Just "drBrand") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Text)) :*: S1 (MetaSel (Just "drModel") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Maybe Text))))) |