Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- type XML = XML (FileSource Offset)
- type XMLs = XMLs (FileSource Offset)
- type Parser e s a = Parsable e s a => ReaderT Reader (Parsec e s) a
- type Parsable e s a = (Stream s, Token s ~ Char, Ord e, IsString (Tokens s), ShowErrorComponent e)
- data Reader = Reader {}
- p_Offset :: Parser e s Offset
- p_Sourced :: Parser e s a -> Parser e s (Sourced (FileSource Offset) a)
- setSource :: FileRange pos -> FileSource pos -> FileSource pos
- p_SourcedBegin :: Parser e s a -> Parser e s a
- p_SourcedEnd :: Parser e s (a -> Sourced (FileSource Offset) a)
- data Error
- = Error_CharRef_invalid Integer
- | Error_EntityRef_unknown NCName
- | Error_Closing_tag_unexpected QName QName
- | Error_Attribute_collision QName
- | Error_PI_reserved PName
- | Error_Namespace_prefix_unknown NCName
- | Error_Namespace_empty NCName
- | Error_Namespace_reserved Namespace
- | Error_Namespace_reserved_prefix NCName
- p_error :: e -> Parser e s a
- p_quoted :: Tokens s ~ Text => (Char -> Parser e s a) -> Parser e s a
- p_until :: Tokens s ~ Text => (Char -> Bool) -> (Char, Text) -> Parser e s Text
- p_until1 :: Tokens s ~ Text => (Char -> Bool) -> (Char, Text) -> Parser e s Text
Documentation
Type Parser
Type Parsable
type Parsable e s a = (Stream s, Token s ~ Char, Ord e, IsString (Tokens s), ShowErrorComponent e) Source #
Type Reader
setSource :: FileRange pos -> FileSource pos -> FileSource pos Source #
p_SourcedBegin :: Parser e s a -> Parser e s a Source #
Like p_Sourced
but uncoupled (through the use of p_SourcedEnd
) for more flexibility.
p_SourcedEnd :: Parser e s (a -> Sourced (FileSource Offset) a) Source #
WARNING: Only to be used within a p_SourcedBegin
.
Type Error
Error_CharRef_invalid Integer | Well-formedness constraint: Legal Character. Characters referred to using character references MUST match the production for Char. |
Error_EntityRef_unknown NCName | Well-formedness constraint: Entity Declared In a document without any DTD, a document with only an internal DTD
subset which contains no parameter entity references, or a document
with " standalone= Note that non-validating processors are not obligated to read and
process entity declarations occurring in parameter entities or in the
external subset; for such documents, the rule that an entity must be
declared is a well-formedness constraint only if standalone= |
Error_Closing_tag_unexpected QName QName | Well-formedness constraint: Element Type Match. The Name in an element's end-tag MUST match the element type in the start-tag. |
Error_Attribute_collision QName | Well-formedness constraint: Unique Att Spec. An attribute name MUST NOT appear more than once in the same start-tag or empty-element tag. |
Error_PI_reserved PName | The target names " XML ", " xml ", and so on are reserved for standardization. |
Error_Namespace_prefix_unknown NCName | Namespace constraint: Prefix Declared The namespace prefix, unless it is xml or xmlns, MUST have been declared in a namespace declaration attribute in either the start-tag of the element where the prefix is used or in an ancestor element (i.e., an element in whose content the prefixed markup occurs). |
Error_Namespace_empty NCName | Namespace constraint: No Prefix Undeclaring In a namespace declaration for a prefix (i.e., where the NSAttName is a PrefixedAttName), the attribute value MUST NOT be empty. |
Error_Namespace_reserved Namespace | |
Error_Namespace_reserved_prefix NCName | Namespace constraint: Reserved Prefixes and Namespace Names The prefix xml is by definition bound to the namespace name http://www.w3.org/XML/1998/namespace. It MAY, but need not, be declared, and MUST NOT be bound to any other namespace name. Other prefixes MUST NOT be bound to this namespace name, and it MUST NOT be declared as the default namespace. The prefix xmlns is used only to declare namespace bindings and is by definition bound to the namespace name http://www.w3.org/2000/xmlns/. It MUST NOT be declared . Other prefixes MUST NOT be bound to this namespace name, and it MUST NOT be declared as the default namespace. Element names MUST NOT have the prefix xmlns. All other prefixes beginning with the three-letter sequence x, m, l, in any case combination, are reserved. This means that:
|