xml-1.3.7: A simple XML library.Source codeContentsIndex
Text.XML.Light.Lexer
Synopsis
class XmlSource s where
uncons :: s -> Maybe (Char, s)
linenumber :: XmlSource s => Integer -> s -> LString
type LChar = (Line, Char)
type LString = [LChar]
data Token
= TokStart Line QName [Attr] Bool
| TokEnd Line QName
| TokCRef String
| TokText CData
tokens :: XmlSource source => source -> [Token]
tokens' :: LString -> [Token]
special :: LChar -> LString -> [Token]
qualName :: LString -> (QName, LString)
tag :: LString -> [Token]
attribs :: LString -> ([Attr], Bool, [Token])
attrib :: LString -> (Attr, LString)
attr_val :: LString -> (String, LString)
dropSpace :: LString -> LString
string :: LString -> (String, LString)
break' :: (a -> Bool) -> [(b, a)] -> ([a], [(b, a)])
breakn :: (a -> Bool) -> [(b, a)] -> ([a], [(b, a)])
decode_attr :: String -> String
data Txt
= TxtBit String
| CRefBit String
decode_text :: [Char] -> [Txt]
cref_to_char :: [Char] -> Maybe Char
num_esc :: String -> Maybe Char
cvt_char :: Int -> Maybe Char
Documentation
class XmlSource s whereSource
Methods
uncons :: s -> Maybe (Char, s)Source
linenumber :: XmlSource s => Integer -> s -> LStringSource
type LChar = (Line, Char)Source
type LString = [LChar]Source
data Token Source
Constructors
TokStart Line QName [Attr] Bool
TokEnd Line QName
TokCRef String
TokText CData
tokens :: XmlSource source => source -> [Token]Source
tokens' :: LString -> [Token]Source
special :: LChar -> LString -> [Token]Source
qualName :: LString -> (QName, LString)Source
tag :: LString -> [Token]Source
attribs :: LString -> ([Attr], Bool, [Token])Source
attrib :: LString -> (Attr, LString)Source
attr_val :: LString -> (String, LString)Source
dropSpace :: LString -> LStringSource
string :: LString -> (String, LString)Source
Match the value for an attribute. For malformed XML we do our best to guess the programmer's intention.
break' :: (a -> Bool) -> [(b, a)] -> ([a], [(b, a)])Source
breakn :: (a -> Bool) -> [(b, a)] -> ([a], [(b, a)])Source
decode_attr :: String -> StringSource
data Txt Source
Constructors
TxtBit String
CRefBit String
decode_text :: [Char] -> [Txt]Source
cref_to_char :: [Char] -> Maybe CharSource
num_esc :: String -> Maybe CharSource
cvt_char :: Int -> Maybe CharSource
Produced by Haddock version 2.6.0