module Pxp_lexer_types: sig
.. end
alternate version of Within_tag for event-based attribute parsing:
type
lexers =
| |
Document |
| |
Document_type |
| |
Content |
| |
Within_tag |
| |
Within_tag_entry |
| |
Declaration |
| |
Comment of lexers |
| |
Ignored_section |
| |
Closed |
| |
Tag_eb |
| |
Tag_eb_att of bool |
type
prolog_token =
| |
Pro_name of string |
| |
Pro_eq |
| |
Pro_string of string |
| |
Pro_eof |
type
entity_id = < >
The class without properties; but you can still compare if two objects
are the same.
type
token =
| |
Begin_entity |
| |
End_entity |
| |
Comment_begin of entity_id |
| |
Comment_material of string |
| |
Comment_end of entity_id |
| |
Ignore |
| |
IgnoreLineEnd |
| |
Eq |
| |
Rangle |
| |
Rangle_empty |
| |
Percent |
| |
Plus |
| |
Star |
| |
Bar |
| |
Comma |
| |
Qmark |
| |
Pcdata |
| |
Required |
| |
Implied |
| |
Fixed |
| |
Bof |
| |
Eof |
| |
Conditional_begin of entity_id |
| |
Conditional_body of entity_id |
| |
Conditional_end of entity_id |
| |
Doctype of entity_id |
| |
Doctype_rangle of entity_id |
| |
Dtd_begin of entity_id |
| |
Dtd_end of entity_id |
| |
Decl_element of entity_id |
| |
Decl_attlist of entity_id |
| |
Decl_entity of entity_id |
| |
Decl_notation of entity_id |
| |
Decl_rangle of entity_id |
| |
Lparen of entity_id |
| |
Rparen of entity_id |
| |
RparenPlus of entity_id |
| |
RparenStar of entity_id |
| |
RparenQmark of entity_id |
| |
Tag_beg of (string * entity_id) |
| |
Tag_end of (string * entity_id) |
| |
PI of (string * string * entity_id) |
| |
PI_xml of prolog_token list |
| |
Cdata of string |
| |
CRef of int |
| |
ERef of string |
| |
PERef of string |
| |
CharData of string |
| |
Lcurly |
| |
LLcurly |
| |
Rcurly |
| |
RRcurly |
| |
LineEnd of string |
| |
LineEnd_att of string |
| |
Name of string |
| |
Nametoken of string |
| |
Attval of string |
| |
Attval_nl_normalized of string |
| |
Unparsed_string of string |
| |
SQuote |
| |
DQuote |
| |
ERef_att of string |
Notes:
- LineEnd s is converted to a single CharData "\n" if the entity manager
reads from an external entity, and to CharData s otherwise. This LineEnd
version is used when "\n" is the line separator (in most cases).
- LineEnd_att s is converted to a single CharData " " (space) if the
entity manager reads from an external entity, and to CharData s otherwise.
This LineEnd version is used when space is the line separator (i.e. in
attribute values)
- ERef n is substituted by the contents of the entity n by the entity
manager. The parser never sees this token, because it is already
replaced by its replacement text.
- ERef_att n is not touched by the entity manager, and this token is
seen by the parser. This is sometimes used when analyzing attribute
values.
- PERef n is substituted by the contents of the entity, too, and the
entity manager passed only the replacement text to the parser.
- Attval s: The scanner passes such tokens to the entity manager when
a complete attribute value is scanned at once, e.g. "abc" or 'def'.
The entity manager leaves this token as it is if it comes from an
external entity, but changes it to Attval_nl_normalized if it comes
from an internal entity (because newline characters are already
normalized).
- Attval_nl_normalized s: Generated by the entity manager if the
newline characters of the attribute value are already normalized
(always represented by "\n").
- Unparsed_string is only used in DTDs.
val string_of_lexers : lexers -> string
val string_of_tok : token -> string
class type lexer_factory = object
.. end
The lexer_factory
creates lexers for a certain character encoding.
class type lexer_obj = object
.. end
A lexer_obj
scans from a certain lexer_source
.
type
lexer_set = {
|
scan_name_string : Lexing.lexbuf -> token ; |
}
DEPRECATED. Only exists because WDialog needs it.