#Processed by Id: cwm.py,v 1.197 2007/12/13 15:38:39 syosi Exp # using base file:///devel/WWW/2000/10/swap/grammar/ # Notation3 generation by # notation3.py,v 1.200 2007/12/11 21:18:08 syosi Exp # Base was: file:///devel/WWW/2000/10/swap/grammar/ @prefix : . @prefix bnf: . @prefix log: . @prefix n: . @prefix rul: . @forSome <#_g0>, <#_g1>, <#_g2>, <#_g3>, <#_g4>, <#_g5>, <#_g6> . "!" :reference """"!"""" . "(" :reference """"("""" . ")" :reference """")"""" . "," :reference """","""" . "." :reference """"."""" . ";" :reference """";"""" . "=" :reference """"="""" . "=>" :reference """"=>"""" . "@" :reference """"@"""" . "@a" :reference """"@a"""" . "@base" :reference """"@base"""" . "@forAll" :reference """"@forAll"""" . "@forSome" :reference """"@forSome"""" . "@has" :reference """"@has"""" . "@is" :reference """"@is"""" . "@keywords" :reference """"@keywords"""" . "@of" :reference """"@of"""" . "@prefix" :reference """"@prefix"""" . "[" :reference """"["""" . "]" :reference """"]"""" . "^" :reference """"^"""" . "^^" :reference """"^^"""" . "{" :reference """"{"""" . "}" :reference """"}"""" . () a :Sequence, :SequenceTail; :seqlabel "void" . ( "!" n:path ) a :Sequence, :SequenceTail; :seqlabel """"!" path""" . ( "(" n:itemlist ")" ) a :Sequence, :SequenceTail; :seqlabel """"(" itemlist ")"""" . ( ")" ) a :SequenceTail; :seqlabel """")"""" . ( "," n:barename <#_g6> ) a :Sequence, :SequenceTail; :seqlabel """"," barename barename_csl""" . ( "," n:object n:objecttail ) a :Sequence, :SequenceTail; :seqlabel """"," object objecttail""" . ( "," n:symbol <#_g4> ) a :Sequence, :SequenceTail; :seqlabel """"," symbol symbol_csl""" . ( "," n:symbol <#_g5> ) a :Sequence, :SequenceTail; :seqlabel """"," symbol symbol_csl""" . ( "." n:statementlist ) a :Sequence, :SequenceTail; :seqlabel """"." statementlist""" . ( "." n:statements_optional ) a :SequenceTail; :seqlabel """"." statements_optional""" . ( "." ) a :Sequence, :SequenceTail; :seqlabel """"."""" . ( "0" 0 ) log:outputString """ BNF

BNF

Productions are in normal type, linked to their definitions.
Regular expressions are in italics
Literal characters in quoted in bold
void means an empty production.

""" . ( ";" n:propertylist ) a :Sequence, :SequenceTail; :seqlabel """";" propertylist""" . ( "=" ) a :Sequence, :SequenceTail; :seqlabel """"="""" . ( "=>" "{" n:formula_safe "}" ) a :SequenceTail . ( "=>" "{" n:formulacontent "}" ) a :SequenceTail; :seqlabel """"=>" "{" formulacontent "}"""" . ( "@" n:langcode ) a :Sequence, :SequenceTail; :seqlabel """"@" langcode""" . ( "@a" ) a :Sequence, :SequenceTail; :seqlabel """"@a"""" . ( "@base" n:explicituri "." ) a :Sequence, :SequenceTail; :seqlabel """"@base" explicituri "."""" . ( "@forAll" <#_g4> ) a :Sequence, :SequenceTail; :seqlabel """"@forAll" symbol_csl""" . ( "@forSome" <#_g5> ) a :Sequence, :SequenceTail; :seqlabel """"@forSome" symbol_csl""" . ( "@has" n:prop ) a :Sequence, :SequenceTail; :seqlabel """"@has" prop""" . ( "@is" n:prop "@of" ) a :Sequence, :SequenceTail; :seqlabel """"@is" prop "@of"""" . ( "@keywords" <#_g6> ) a :Sequence, :SequenceTail; :seqlabel """"@keywords" barename_csl""" . ( "@of" ) a :SequenceTail; :seqlabel """"@of"""" . ( "@prefix" n:qname n:explicituri "." ) a :Sequence, :SequenceTail; :seqlabel """"@prefix" qname explicituri "."""" . ( "[" n:propertylist "]" ) a :Sequence, :SequenceTail; :seqlabel """"[" propertylist "]"""" . ( "]" ) a :SequenceTail; :seqlabel """"]"""" . ( "^" n:path ) a :Sequence, :SequenceTail; :seqlabel """"^" path""" . ( "^^" n:symbol ) a :Sequence, :SequenceTail; :seqlabel """"^^" symbol""" . ( "alphanumeric" 0 ) log:outputString """
alphanumeric
""" . ( "alphanumeric" 6 ) log:outputString """

[a-zA-Z][a-zA-Z0-9_]*

""" . ( "alphanumeric" 9 ) log:outputString "\t
\n" . ( "barename" 0 ) log:outputString """
barename
""" . ( "barename" 6 ) log:outputString """

[a-zA-Z_][a-zA-Z0-9_]*

""" . ( "barename" 9 ) log:outputString "\t
\n" . ( "barename_csl" 0 ) log:outputString """
barename_csl
""" . ( "barename_csl" 5 ) log:outputString """

"," barename barename_csl

""", """

"."

""" . ( "barename_csl" 9 ) log:outputString "\t
\n" . ( "declaration" 0 ) log:outputString """
declaration
""" . ( "declaration" 5 ) log:outputString """

"@base" explicituri "."

""", """

"@keywords" barename_csl

""", """

"@prefix" qname explicituri "."

""" . ( "declaration" 9 ) log:outputString "\t
\n" . ( "declaration_s" 0 ) log:outputString """
declaration_s
""" . ( "declaration_s" 5 ) log:outputString """

declaration declaration_s

""", """

void

""" . ( "declaration_s" 9 ) log:outputString "\t
\n" . ( "document" 0 ) log:outputString """
document
""" . ( "document" 5 ) log:outputString """

declaration_s existential_s statements_optional EOF

""" . ( "document" 9 ) log:outputString "\t
\n" . ( "dtlang" 0 ) log:outputString """
dtlang
""" . ( "dtlang" 5 ) log:outputString """

"@" langcode

""", """

"^^" symbol

""", """

void

""" . ( "dtlang" 9 ) log:outputString "\t
\n" . ( "existential" 0 ) log:outputString """
existential
""" . ( "existential" 5 ) log:outputString """

"@forSome" symbol_csl

""" . ( "existential" 9 ) log:outputString "\t
\n" . ( "existential_s" 0 ) log:outputString """
existential_s
""" . ( "existential_s" 5 ) log:outputString """

existential existential_s

""", """

void

""" . ( "existential_s" 9 ) log:outputString "\t
\n" . ( "explicituri" 0 ) log:outputString """
explicituri
""" . ( "explicituri" 6 ) log:outputString """

<[^>].*>

""" . ( "explicituri" 9 ) log:outputString "\t
\n" . ( "formulacontent" 0 ) log:outputString """
formulacontent
""" . ( "formulacontent" 5 ) log:outputString """

declaration_s existential_s statementlist

""" . ( "formulacontent" 9 ) log:outputString "\t
\n" . ( "item" 0 ) log:outputString """
item
""" . ( "item" 5 ) log:outputString """

path

""" . ( "item" 9 ) log:outputString "\t
\n" . ( "itemlist" 0 ) log:outputString """
itemlist
""" . ( "itemlist" 5 ) log:outputString """

item itemlist

""", """

void

""" . ( "itemlist" 9 ) log:outputString "\t
\n" . ( "langcode" 0 ) log:outputString """
langcode
""" . ( "langcode" 6 ) log:outputString """

[a-zA-Z0-9]+(-[a-zA-Z0-9]+)?

""" . ( "langcode" 9 ) log:outputString "\t
\n" . ( "literal" 0 ) log:outputString """
literal
""" . ( "literal" 5 ) log:outputString """

string dtlang

""" . ( "literal" 9 ) log:outputString "\t
\n" . ( "node" 0 ) log:outputString """
node
""" . ( "node" 5 ) log:outputString """

literal

""", """

numericliteral

""", """

symbol

""", """

variable

""", """

"(" itemlist ")"

""", """

"[" propertylist "]"

""" . ( "node" 9 ) log:outputString "\t
\n" . ( "node_safe" 0 ) log:outputString """
node_safe
""" . ( "node_safe" 5 ) log:outputString """

literal

""", """

numericliteral

""", """

symbol

""", """

variable

""" . ( "node_safe" 9 ) log:outputString "\t
\n" . ( "numericliteral" 0 ) log:outputString """
numericliteral
""" . ( "numericliteral" 6 ) log:outputString """

[-+]?[0-9]+(\\.[0-9]+)?(e[-+]?[0-9]+)?

""" . ( "numericliteral" 9 ) log:outputString "\t
\n" . ( "object" 0 ) log:outputString """
object
""" . ( "object" 5 ) log:outputString """

item

""" . ( "object" 9 ) log:outputString "\t
\n" . ( "objecttail" 0 ) log:outputString """
objecttail
""" . ( "objecttail" 5 ) log:outputString """

"," object objecttail

""", """

void

""" . ( "objecttail" 9 ) log:outputString "\t
\n" . ( "path" 0 ) log:outputString """
path
""" . ( "path" 5 ) log:outputString """

node pathtail

""" . ( "path" 9 ) log:outputString "\t
\n" . ( "pathtail" 0 ) log:outputString """
pathtail
""" . ( "pathtail" 5 ) log:outputString """

"!" path

""", """

"^" path

""", """

void

""" . ( "pathtail" 9 ) log:outputString "\t
\n" . ( "prop" 0 ) log:outputString """
prop
""" . ( "prop" 5 ) log:outputString """

node

""" . ( "prop" 9 ) log:outputString "\t
\n" . ( "propertylist" 0 ) log:outputString """
propertylist
""" . ( "propertylist" 5 ) log:outputString """

verb object objecttail propertylisttail

""", """

void

""" . ( "propertylist" 9 ) log:outputString "\t
\n" . ( "propertylisttail" 0 ) log:outputString """
propertylisttail
""" . ( "propertylisttail" 5 ) log:outputString """

";" propertylist

""", """

void

""" . ( "propertylisttail" 9 ) log:outputString "\t
\n" . ( "qname" 0 ) log:outputString """
qname
""" . ( "qname" 6 ) log:outputString """

(([a-zA-Z_][a-zA-Z0-9_]*)?:)?([a-zA-Z_][a-zA-Z0-9_]*)?

""" . ( "qname" 9 ) log:outputString "\t
\n" . ( "rule" 0 ) log:outputString """
rule
""" . ( "rule" 5 ) log:outputString """

"{" formulacontent "}" "=>" "{" formulacontent "}"

""" . ( "rule" 9 ) log:outputString "\t
\n" . ( "rule_safe" 0 ) log:outputString """
rule_safe
""" . ( "rule_safe" 9 ) log:outputString "\t
\n" . ( "statement" 0 ) log:outputString """
statement
""" . ( "statement" 5 ) log:outputString """

subject propertylist

""" . ( "statement" 9 ) log:outputString "\t
\n" . ( "statement_or_rule" 0 ) log:outputString """
statement_or_rule
""" . ( "statement_or_rule" 5 ) log:outputString """

rule

""", """

statement

""" . ( "statement_or_rule" 9 ) log:outputString "\t
\n" . ( "statementlist" 0 ) log:outputString """
statementlist
""" . ( "statementlist" 5 ) log:outputString """

statement statementtail

""", """

void

""" . ( "statementlist" 9 ) log:outputString "\t
\n" . ( "statements_optional" 0 ) log:outputString """
statements_optional
""" . ( "statements_optional" 5 ) log:outputString """

statement_or_rule "." statements_optional

""", """

void

""" . ( "statements_optional" 9 ) log:outputString "\t
\n" . ( "statementtail" 0 ) log:outputString """
statementtail
""" . ( "statementtail" 5 ) log:outputString """

"." statementlist

""", """

void

""" . ( "statementtail" 9 ) log:outputString "\t
\n" . ( "string" 0 ) log:outputString """
string
""" . ( "string" 6 ) log:outputString """

(\"""[^"\\\\]*(?:(?:\\\\.|"(?!""))[^"\\\\]*)*\""")|("[^"\\\\]*(?:\\\\.[^"\\\\]*)*")

""" . ( "string" 9 ) log:outputString "\t
\n" . ( "subject" 0 ) log:outputString """
subject
""" . ( "subject" 5 ) log:outputString """

item

""" . ( "subject" 9 ) log:outputString "\t
\n" . ( "symbol" 0 ) log:outputString """
symbol
""" . ( "symbol" 5 ) log:outputString """

explicituri

""", """

qname

""" . ( "symbol" 9 ) log:outputString "\t
\n" . ( "symbol_csl" 0 ) log:outputString """
symbol_csl
""" . ( "symbol_csl" 5 ) log:outputString """

"," symbol symbol_csl

""", """

"."

""" . ( "symbol_csl" 9 ) log:outputString "\t
\n" . ( "universal" 0 ) log:outputString """
universal
""" . ( "universal" 5 ) log:outputString """

"@forAll" symbol_csl

""" . ( "universal" 9 ) log:outputString "\t
\n" . ( "variable" 0 ) log:outputString """
variable
""" . ( "variable" 6 ) log:outputString """

\\?[a-zA-Z_][a-zA-Z0-9_]*

""" . ( "variable" 9 ) log:outputString "\t
\n" . ( "verb" 0 ) log:outputString """
verb
""" . ( "verb" 5 ) log:outputString """

prop

""", """

"="

""", """

"@a"

""", """

"@has" prop

""", """

"@is" prop "@of"

""" . ( "verb" 9 ) log:outputString "\t
\n" . ( "{" n:formula_safe "}" ) a :SequenceTail . ( "{" n:formulacontent "}" "=>" "{" n:formula_safe "}" ) a :Sequence, :SequenceTail . ( "{" n:formulacontent "}" "=>" "{" n:formulacontent "}" ) a :Sequence, :SequenceTail; :seqlabel """"{" formulacontent "}" "=>" "{" formulacontent "}"""" . ( "{" n:formulacontent "}" ) a :SequenceTail; :seqlabel """"{" formulacontent "}"""" . ( "}" "=>" "{" n:formula_safe "}" ) a :SequenceTail . ( "}" "=>" "{" n:formulacontent "}" ) a :SequenceTail; :seqlabel """"}" "=>" "{" formulacontent "}"""" . ( "}" ) a :SequenceTail; :seqlabel """"}"""" . ( "~~" 9 ) log:outputString "\n
\n\n" . ( bnf:eof ) a :SequenceTail; :seqlabel "EOF" . ( n:barename <#_g6> ) a :SequenceTail; :seqlabel "barename barename_csl" . ( n:declaration <#_g0> ) a :Sequence, :SequenceTail; :seqlabel "declaration declaration_s" . ( n:declaration <#_g2> ) a :Sequence, :SequenceTail; :seqlabel "declaration declaration_s" . ( n:dtlang ) a :SequenceTail; :seqlabel "dtlang" . ( n:existential <#_g1> ) a :Sequence, :SequenceTail; :seqlabel "existential existential_s" . ( n:existential <#_g3> ) a :Sequence, :SequenceTail; :seqlabel "existential existential_s" . ( n:explicituri "." ) a :SequenceTail; :seqlabel """explicituri "."""" . ( n:explicituri ) a :Sequence, :SequenceTail; :seqlabel "explicituri" . ( n:formula_safe "}" ) a :SequenceTail . ( n:formulacontent "}" "=>" "{" n:formula_safe "}" ) a :SequenceTail . ( n:formulacontent "}" "=>" "{" n:formulacontent "}" ) a :SequenceTail; :seqlabel """formulacontent "}" "=>" "{" formulacontent "}"""" . ( n:formulacontent "}" ) a :SequenceTail; :seqlabel """formulacontent "}"""" . ( n:item n:itemlist ) a :Sequence, :SequenceTail; :seqlabel "item itemlist" . ( n:item ) a :Sequence, :SequenceTail; :seqlabel "item" . ( n:itemlist ")" ) a :SequenceTail; :seqlabel """itemlist ")"""" . ( n:itemlist ) a :SequenceTail; :seqlabel "itemlist" . ( n:langcode ) a :SequenceTail; :seqlabel "langcode" . ( n:literal ) a :Sequence, :SequenceTail; :seqlabel "literal" . ( n:node n:pathtail ) a :Sequence, :SequenceTail; :seqlabel "node pathtail" . ( n:node ) a :Sequence, :SequenceTail; :seqlabel "node" . ( n:numericliteral ) a :Sequence, :SequenceTail; :seqlabel "numericliteral" . ( n:object n:objecttail n:propertylisttail ) a :SequenceTail; :seqlabel "object objecttail propertylisttail" . ( n:object n:objecttail ) a :SequenceTail; :seqlabel "object objecttail" . ( n:objecttail n:propertylisttail ) a :SequenceTail; :seqlabel "objecttail propertylisttail" . ( n:objecttail ) a :SequenceTail; :seqlabel "objecttail" . ( n:path ) a :Sequence, :SequenceTail; :seqlabel "path" . ( n:pathtail ) a :SequenceTail; :seqlabel "pathtail" . ( n:prop "@of" ) a :SequenceTail; :seqlabel """prop "@of"""" . ( n:prop ) a :Sequence, :SequenceTail; :seqlabel "prop" . ( n:propertylist "]" ) a :SequenceTail; :seqlabel """propertylist "]"""" . ( n:propertylist ) a :SequenceTail; :seqlabel "propertylist" . ( n:propertylisttail ) a :SequenceTail; :seqlabel "propertylisttail" . ( n:qname n:explicituri "." ) a :SequenceTail; :seqlabel """qname explicituri "."""" . ( n:qname ) a :Sequence, :SequenceTail; :seqlabel "qname" . ( n:rule ) a :Sequence, :SequenceTail; :seqlabel "rule" . ( n:statement n:statementtail ) a :Sequence, :SequenceTail; :seqlabel "statement statementtail" . ( n:statement ) a :Sequence, :SequenceTail; :seqlabel "statement" . ( n:statement_or_rule "." n:statements_optional ) a :Sequence, :SequenceTail; :seqlabel """statement_or_rule "." statements_optional""" . ( n:statementlist ) a :SequenceTail; :seqlabel "statementlist" . ( n:statements_optional bnf:eof ) a :SequenceTail; :seqlabel "statements_optional EOF" . ( n:statements_optional ) a :SequenceTail; :seqlabel "statements_optional" . ( n:statementtail ) a :SequenceTail; :seqlabel "statementtail" . ( n:string n:dtlang ) a :Sequence, :SequenceTail; :seqlabel "string dtlang" . ( n:subject n:propertylist ) a :Sequence, :SequenceTail; :seqlabel "subject propertylist" . ( n:symbol <#_g4> ) a :SequenceTail; :seqlabel "symbol symbol_csl" . ( n:symbol <#_g5> ) a :SequenceTail; :seqlabel "symbol symbol_csl" . ( n:symbol ) a :Sequence, :SequenceTail; :seqlabel "symbol" . ( n:variable ) a :Sequence, :SequenceTail; :seqlabel "variable" . ( n:verb n:object n:objecttail n:propertylisttail ) a :Sequence, :SequenceTail; :seqlabel "verb object objecttail propertylisttail" . ( <#_g0> <#_g1> n:statements_optional bnf:eof ) a :Sequence, :SequenceTail; :seqlabel "declaration_s existential_s statements_optional EOF" . ( <#_g0> ) a :SequenceTail; :seqlabel "declaration_s" . ( <#_g1> n:statements_optional bnf:eof ) a :SequenceTail; :seqlabel "existential_s statements_optional EOF" . ( <#_g1> ) a :SequenceTail; :seqlabel "existential_s" . ( <#_g2> <#_g3> n:statementlist ) a :Sequence, :SequenceTail; :seqlabel "declaration_s existential_s statementlist" . ( <#_g2> ) a :SequenceTail; :seqlabel "declaration_s" . ( <#_g3> n:statementlist ) a :SequenceTail; :seqlabel "existential_s statementlist" . ( <#_g3> ) a :SequenceTail; :seqlabel "existential_s" . ( <#_g4> ) a :SequenceTail; :seqlabel "symbol_csl" . ( <#_g5> ) a :SequenceTail; :seqlabel "symbol_csl" . ( <#_g6> ) a :SequenceTail; :seqlabel "barename_csl" . bnf:eof :reference "EOF" . n:alphanumeric a :Production; bnf:canStartWith "a"; bnf:label "alphanumeric"; bnf:matches "[a-zA-Z][a-zA-Z0-9_]*"; :reference "alphanumeric" . n:barename a :Production; bnf:canStartWith "_", "a"; bnf:label "barename"; bnf:matches "[a-zA-Z_][a-zA-Z0-9_]*"; :reference "barename" . n:declaration a :Production; bnf:canBeSequence ( "@base" n:explicituri "." ), ( "@keywords" <#_g6> ), ( "@prefix" n:qname n:explicituri "." ); bnf:label "declaration"; bnf:mustBeOneSequence ( ( "@base" n:explicituri "." ) ( "@prefix" n:qname n:explicituri "." ) ( "@keywords" <#_g6> ) ); :optionTail (), ( ( "@base" n:explicituri "." ) ( "@prefix" n:qname n:explicituri "." ) ( "@keywords" <#_g6> ) ), ( ( "@keywords" <#_g6> ) ), ( ( "@prefix" n:qname n:explicituri "." ) ( "@keywords" <#_g6> ) ); :reference "declaration" . n:document a rul:Used, :Production; bnf:canBeSequence ( <#_g0> <#_g1> n:statements_optional bnf:eof ); bnf:label "document"; bnf:mustBeOneSequence ( ( <#_g0> <#_g1> n:statements_optional bnf:eof ) ); :optionTail (), ( ( <#_g0> <#_g1> n:statements_optional bnf:eof ) ); :reference "document" . n:dtlang a :Production; bnf:canBeSequence (), ( "@" n:langcode ), ( "^^" n:symbol ); bnf:label "dtlang"; bnf:mustBeOneSequence ( () ( "@" n:langcode ) ( "^^" n:symbol ) ); :optionTail (), ( () ( "@" n:langcode ) ( "^^" n:symbol ) ), ( ( "@" n:langcode ) ( "^^" n:symbol ) ), ( ( "^^" n:symbol ) ); :reference "dtlang" . n:existential a :Production; bnf:canBeSequence ( "@forSome" <#_g5> ); bnf:label "existential"; bnf:mustBeOneSequence ( ( "@forSome" <#_g5> ) ); :optionTail (), ( ( "@forSome" <#_g5> ) ); :reference "existential" . n:explicituri a :Production; bnf:canStartWith "<"; bnf:label "explicituri"; bnf:matches "<[^>].*>"; :reference "explicituri" . n:formulacontent a :Production; bnf:canBeSequence ( <#_g2> <#_g3> n:statementlist ); bnf:label "formulacontent"; bnf:mustBeOneSequence ( ( <#_g2> <#_g3> n:statementlist ) ); :optionTail (), ( ( <#_g2> <#_g3> n:statementlist ) ); :reference "formulacontent" . n:item a :Production; bnf:canBeSequence ( n:path ); bnf:label "item"; bnf:mustBeOneSequence ( ( n:path ) ); :optionTail (), ( ( n:path ) ); :reference "item" . n:itemlist a :Production; bnf:canBeSequence (), ( n:item n:itemlist ); bnf:label "itemlist"; bnf:mustBeOneSequence ( () ( n:item n:itemlist ) ); :optionTail (), ( () ( n:item n:itemlist ) ), ( ( n:item n:itemlist ) ); :reference "itemlist" . n:langcode a :Production; bnf:canStartWith "a"; bnf:label "langcode"; bnf:matches "[a-zA-Z0-9]+(-[a-zA-Z0-9]+)?"; :reference "langcode" . n:literal a :Production; bnf:canBeSequence ( n:string n:dtlang ); bnf:label "literal"; bnf:mustBeOneSequence ( ( n:string n:dtlang ) ); :optionTail (), ( ( n:string n:dtlang ) ); :reference "literal" . n:node a :Production; bnf:canBeSequence ( "(" n:itemlist ")" ), ( "[" n:propertylist "]" ), ( n:literal ), ( n:numericliteral ), ( n:symbol ), ( n:variable ); bnf:label "node"; bnf:mustBeOneSequence ( ( n:symbol ) ( n:variable ) ( n:numericliteral ) ( n:literal ) ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ); :optionTail (), ( ( "(" n:itemlist ")" ) ), ( ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ), ( ( n:literal ) ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ), ( ( n:numericliteral ) ( n:literal ) ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ), ( ( n:symbol ) ( n:variable ) ( n:numericliteral ) ( n:literal ) ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ), ( ( n:variable ) ( n:numericliteral ) ( n:literal ) ( "[" n:propertylist "]" ) ( "(" n:itemlist ")" ) ); :reference "node" . n:node_safe a :Production; bnf:canBeSequence ( n:literal ), ( n:numericliteral ), ( n:symbol ), ( n:variable ); bnf:label "node_safe"; bnf:mustBeOneSequence ( ( n:symbol ) ( n:variable ) ( n:numericliteral ) ( n:literal ) ); :optionTail (), ( ( n:literal ) ), ( ( n:numericliteral ) ( n:literal ) ), ( ( n:symbol ) ( n:variable ) ( n:numericliteral ) ( n:literal ) ), ( ( n:variable ) ( n:numericliteral ) ( n:literal ) ); :reference "node_safe" . n:numericliteral a :Production; bnf:canStartWith "+", "-", "0"; bnf:label "numericliteral"; bnf:matches "[-+]?[0-9]+(\\.[0-9]+)?(e[-+]?[0-9]+)?"; :reference "numericliteral" . n:object a :Production; bnf:canBeSequence ( n:item ); bnf:label "object"; bnf:mustBeOneSequence ( ( n:item ) ); :optionTail (), ( ( n:item ) ); :reference "object" . n:objecttail a :Production; bnf:canBeSequence (), ( "," n:object n:objecttail ); bnf:label "objecttail"; bnf:mustBeOneSequence ( () ( "," n:object n:objecttail ) ); :optionTail (), ( () ( "," n:object n:objecttail ) ), ( ( "," n:object n:objecttail ) ); :reference "objecttail" . n:path a :Production; bnf:canBeSequence ( n:node n:pathtail ); bnf:label "path"; bnf:mustBeOneSequence ( ( n:node n:pathtail ) ); :optionTail (), ( ( n:node n:pathtail ) ); :reference "path" . n:pathtail a :Production; bnf:canBeSequence (), ( "!" n:path ), ( "^" n:path ); bnf:label "pathtail"; bnf:mustBeOneSequence ( () ( "!" n:path ) ( "^" n:path ) ); :optionTail (), ( () ( "!" n:path ) ( "^" n:path ) ), ( ( "!" n:path ) ( "^" n:path ) ), ( ( "^" n:path ) ); :reference "pathtail" . n:prop a :Production; bnf:canBeSequence ( n:node ); bnf:label "prop"; bnf:mustBeOneSequence ( ( n:node ) ); :optionTail (), ( ( n:node ) ); :reference "prop" . n:propertylist a :Production; bnf:canBeSequence (), ( n:verb n:object n:objecttail n:propertylisttail ); bnf:label "propertylist"; bnf:mustBeOneSequence ( () ( n:verb n:object n:objecttail n:propertylisttail ) ); :optionTail (), ( () ( n:verb n:object n:objecttail n:propertylisttail ) ), ( ( n:verb n:object n:objecttail n:propertylisttail ) ); :reference "propertylist" . n:propertylisttail a :Production; bnf:canBeSequence (), ( ";" n:propertylist ); bnf:label "propertylisttail"; bnf:mustBeOneSequence ( () ( ";" n:propertylist ) ); :optionTail (), ( () ( ";" n:propertylist ) ), ( ( ";" n:propertylist ) ); :reference "propertylisttail" . n:qname a :Production; bnf:canStartWith "_", "a"; bnf:label "qname"; bnf:matches "(([a-zA-Z_][a-zA-Z0-9_]*)?:)?([a-zA-Z_][a-zA-Z0-9_]*)?"; :reference "qname" . n:rule a :Production; bnf:canBeSequence ( "{" n:formulacontent "}" "=>" "{" n:formulacontent "}" ); bnf:label "rule"; bnf:mustBeOneSequence ( ( "{" n:formulacontent "}" "=>" "{" n:formulacontent "}" ) ); :optionTail (), ( ( "{" n:formulacontent "}" "=>" "{" n:formulacontent "}" ) ); :reference "rule" . n:rule_safe a :Production; bnf:canBeSequence ( "{" n:formulacontent "}" "=>" "{" n:formula_safe "}" ); bnf:label "rule_safe"; bnf:mustBeOneSequence ( ( "{" n:formulacontent "}" "=>" "{" n:formula_safe "}" ) ); :optionTail (), ( ( "{" n:formulacontent "}" "=>" "{" n:formula_safe "}" ) ); :reference "rule_safe" . n:statement a :Production; bnf:canBeSequence ( n:subject n:propertylist ); bnf:label "statement"; bnf:mustBeOneSequence ( ( n:subject n:propertylist ) ); :optionTail (), ( ( n:subject n:propertylist ) ); :reference "statement" . n:statement_or_rule a :Production; bnf:canBeSequence ( n:rule ), ( n:statement ); bnf:label "statement_or_rule"; bnf:mustBeOneSequence ( ( n:statement ) ( n:rule ) ); :optionTail (), ( ( n:rule ) ), ( ( n:statement ) ( n:rule ) ); :reference "statement_or_rule" . n:statementlist a :Production; bnf:canBeSequence (), ( n:statement n:statementtail ); bnf:label "statementlist"; bnf:mustBeOneSequence ( () ( n:statement n:statementtail ) ); :optionTail (), ( () ( n:statement n:statementtail ) ), ( ( n:statement n:statementtail ) ); :reference "statementlist" . n:statements_optional a :Production; bnf:canBeSequence (), ( n:statement_or_rule "." n:statements_optional ); bnf:label "statements_optional"; bnf:mustBeOneSequence ( () ( n:statement_or_rule "." n:statements_optional ) ); :optionTail (), ( () ( n:statement_or_rule "." n:statements_optional ) ), ( ( n:statement_or_rule "." n:statements_optional ) ); :reference "statements_optional" . n:statementtail a :Production; bnf:canBeSequence (), ( "." n:statementlist ); bnf:label "statementtail"; bnf:mustBeOneSequence ( () ( "." n:statementlist ) ); :optionTail (), ( () ( "." n:statementlist ) ), ( ( "." n:statementlist ) ); :reference "statementtail" . n:string a :Production; bnf:canStartWith "\""; bnf:label "string"; bnf:matches """(\"""[^"\\\\]*(?:(?:\\\\.|"(?!""))[^"\\\\]*)*\""")|("[^"\\\\]*(?:\\\\.[^"\\\\]*)*")"""; :reference "string" . n:subject a :Production; bnf:canBeSequence ( n:item ); bnf:label "subject"; bnf:mustBeOneSequence ( ( n:item ) ); :optionTail (), ( ( n:item ) ); :reference "subject" . n:symbol a :Production; bnf:canBeSequence ( n:explicituri ), ( n:qname ); bnf:label "symbol"; bnf:mustBeOneSequence ( ( n:explicituri ) ( n:qname ) ); :optionTail (), ( ( n:explicituri ) ( n:qname ) ), ( ( n:qname ) ); :reference "symbol" . n:universal a :Production; bnf:canBeSequence ( "@forAll" <#_g4> ); bnf:label "universal"; bnf:mustBeOneSequence ( ( "@forAll" <#_g4> ) ); :optionTail (), ( ( "@forAll" <#_g4> ) ); :reference "universal" . n:variable a :Production; bnf:canStartWith "?"; bnf:label "variable"; bnf:matches "\\?[a-zA-Z_][a-zA-Z0-9_]*"; :reference "variable" . n:verb a :Production; bnf:canBeSequence ( "=" ), ( "@a" ), ( "@has" n:prop ), ( "@is" n:prop "@of" ), ( n:prop ); bnf:label "verb"; bnf:mustBeOneSequence ( ( n:prop ) ( "@has" n:prop ) ( "@is" n:prop "@of" ) ( "@a" ) ( "=" ) ); :optionTail (), ( ( "=" ) ), ( ( "@a" ) ( "=" ) ), ( ( "@has" n:prop ) ( "@is" n:prop "@of" ) ( "@a" ) ( "=" ) ), ( ( "@is" n:prop "@of" ) ( "@a" ) ( "=" ) ), ( ( n:prop ) ( "@has" n:prop ) ( "@is" n:prop "@of" ) ( "@a" ) ( "=" ) ); :reference "verb" . <#_g0> a :Production; bnf:canBeSequence (), ( n:declaration <#_g0> ); bnf:label "declaration_s"; bnf:mustBeOneSequence ( () ( n:declaration <#_g0> ) ); bnf:zeroOrMore n:declaration; :optionTail (), ( () ( n:declaration <#_g0> ) ), ( ( n:declaration <#_g0> ) ); :reference "declaration_s" . <#_g1> a :Production; bnf:canBeSequence (), ( n:existential <#_g1> ); bnf:label "existential_s"; bnf:mustBeOneSequence ( () ( n:existential <#_g1> ) ); bnf:zeroOrMore n:existential; :optionTail (), ( () ( n:existential <#_g1> ) ), ( ( n:existential <#_g1> ) ); :reference "existential_s" . <#_g2> a :Production; bnf:canBeSequence (), ( n:declaration <#_g2> ); bnf:label "declaration_s"; bnf:mustBeOneSequence ( () ( n:declaration <#_g2> ) ); bnf:zeroOrMore n:declaration; :optionTail (), ( () ( n:declaration <#_g2> ) ), ( ( n:declaration <#_g2> ) ); :reference "declaration_s" . <#_g3> a :Production; bnf:canBeSequence (), ( n:existential <#_g3> ); bnf:label "existential_s"; bnf:mustBeOneSequence ( () ( n:existential <#_g3> ) ); bnf:zeroOrMore n:existential; :optionTail (), ( () ( n:existential <#_g3> ) ), ( ( n:existential <#_g3> ) ); :reference "existential_s" . <#_g4> a :Production; bnf:canBeSequence ( "," n:symbol <#_g4> ), ( "." ); bnf:commaSeparatedPeriodTerminatedListOf n:symbol; bnf:label "symbol_csl"; bnf:mustBeOneSequence ( ( "." ) ( "," n:symbol <#_g4> ) ); :optionTail (), ( ( "," n:symbol <#_g4> ) ), ( ( "." ) ( "," n:symbol <#_g4> ) ); :reference "symbol_csl" . <#_g5> a :Production; bnf:canBeSequence ( "," n:symbol <#_g5> ), ( "." ); bnf:commaSeparatedPeriodTerminatedListOf n:symbol; bnf:label "symbol_csl"; bnf:mustBeOneSequence ( ( "." ) ( "," n:symbol <#_g5> ) ); :optionTail (), ( ( "," n:symbol <#_g5> ) ), ( ( "." ) ( "," n:symbol <#_g5> ) ); :reference "symbol_csl" . <#_g6> a :Production; bnf:canBeSequence ( "," n:barename <#_g6> ), ( "." ); bnf:commaSeparatedPeriodTerminatedListOf n:barename; bnf:label "barename_csl"; bnf:mustBeOneSequence ( ( "." ) ( "," n:barename <#_g6> ) ); :optionTail (), ( ( "," n:barename <#_g6> ) ), ( ( "." ) ( "," n:barename <#_g6> ) ); :reference "barename_csl" . #ENDS