pXML Syntax Railroad Diagrams

The following railroad diagrams specify pXML's basic syntax. Extensions like attributes, namespaces, etc. are not included.

The syntax is also specified as EBNF.

Notes:

Element

empty_elementnon_empty_element

Empty element

[name]

Example:

[map]

Non-empty element

[name<space>value]

Examples:

[teacher Bob]
[div A [i nice] dog]

Name

a-zA-Z_a-zA-Z0-9-_.

Examples:

index
Index_12
_INDEX_12.5-a

Value

textelement

Examples:

Tree
[list]
[color orange]
All is [i [b very] well]!

Text

character

Examples:

abc
3.14
config.\["port"\]

Character

Unicode character, except [, ], and \\[\]\\\uhexhexhexhex

Examples:

a
é
\[        ([)
\]        (])
\\        (\)
\u002A    (*)

Hexadecimal digit

0-9a-fA-F

Examples:

1
a
F