Text.XML.HXT.Parser.XmlCharParser

hxt-9.3.1.16: A collection of tools for processing XML with Haskell.

Copyright | Copyright (C) 2010 Uwe Schmidt
License | MIT
Maintainer | Uwe Schmidt (uwe@fh-wedel.de)
Stability | stable
Portability | portable
Safe Haskell | Safe
Language | Haskell98

Text.XML.HXT.Parser.XmlCharParser

Description

UTF-8 character parser and simple XML token parsers

Synopsis

- type XParser s a = GenParser Char (XPState s) a
- type SimpleXParser a = XParser () a
- data XPState s = XPState {
  - xps_normalizeNewline :: !Bool
  - xps_userState :: s
  }
- withNormNewline :: a -> XPState a
- withoutNormNewline :: a -> XPState a
- xmlChar :: XParser s Unicode
- xmlNameChar :: XParser s Unicode
- xmlNameStartChar :: XParser s Unicode
- xmlNCNameChar :: XParser s Unicode
- xmlNCNameStartChar :: XParser s Unicode
- xmlLetter :: XParser s Unicode
- xmlSpaceChar :: XParser s Char
- xmlCRLFChar :: XParser s Char

# Documentation

type XParser s a = GenParser Char (XPState s) a #

type SimpleXParser a = XParser () a #

data XPState s #

Constructors

XPState |
Fields xps_normalizeNewline :: !Bool xps_userState :: s

withNormNewline :: a -> XPState a #

withoutNormNewline :: a -> XPState a #

xmlChar :: XParser s Unicode #

parse a single Unicode character

xmlNameChar :: XParser s Unicode #

parse a XML name character

xmlNameStartChar :: XParser s Unicode #

parse a XML name start character

xmlNCNameChar :: XParser s Unicode #

parse a XML NCName character

xmlNCNameStartChar :: XParser s Unicode #

parse a XML NCName start character

xmlLetter :: XParser s Unicode #

parse a XML letter character

xmlSpaceChar :: XParser s Char #

White Space (2.3)

end of line handling (2.11) will be done before or with `xmlCRLFChar` parser

xmlCRLFChar :: XParser s Char #

White Space Normalization

end of line handling (2.11) #x0D and #x0D#x0A are mapped to #x0A