owl.jjt 35.1 KB
Newer Older
1
/* -*-Java-*- */
2 3

/* 
4
 * Copyright (C) 2006,2010  Anders Nilsson <anders.nilsson@control.lth.se>
5 6
 *
 * This file is part of OntologyCompiler.
7 8 9 10 11 12 13 14 15 16 17 18 19
 *
 * OntologyCompiler is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.

 * OntologyCompiler is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 
 * You should have received a copy of the GNU General Public License
 * along with OntologyCompiler.  If not, see <http://www.gnu.org/licenses/>.
20 21
 */

22 23 24 25 26
options {
    MULTI                       = true;
    VISITOR                     = true;
    NODE_DEFAULT_VOID           = true;
    NODE_SCOPE_HOOK             = false;
27
    NODE_PREFIX                 = "";
28 29
    JAVA_UNICODE_ESCAPE         = true;
    STATIC                      = false;
30
    // DEBUG_PARSER                = true;
31
// 	DEBUG_LOOKAHEAD             = true;
32
  	 // DEBUG_TOKEN_MANAGER         = true;
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
} // options


PARSER_BEGIN(OwlParser)
package AST;
public class OwlParser {
}
PARSER_END(OwlParser)


//--------------------------------------------------------------------//
//                           LEXICAL TOKENS                           //
//--------------------------------------------------------------------//

<DEFAULT, BOUNDS> SKIP : /* WHITE SPACE */
{
    " "
    |
    "\t"
    |
    "\n"
    |
    "\r"
    |
    "\f"
}// WHITE SPACE


// <DEFAULT,BOUNDS> SPECIAL_TOKEN : /* COMMENTS */
// {
//     <SLASH_SLASH_COMMENT :  "//" (~["\n","\r"])* >
// }

SPECIAL_TOKEN : /* COMMENTS */
{
//     <SLASH_STAR_COMMENT  :  "/*" (~["*"])* "*" ("*" | (~["*","/"] (~["*"])* "*"))* "/"  >
69
< "<!--" ( ~["-"] | ( "-" ~["-"] ) )* "-->">
70
	| < "<rdfs:comment" ( ~["<"] | ( "<" ~["/"] ) )* "</rdfs:comment>" >
71
	| < "<!DOCTYPE" ( ~["]"] )* "]>" > 
72
//     <XML_COMMENT  :  "<!--" (~["-","-",">"])* "-->"  >
73 74 75
}// COMMENTS


76 77 78 79
// <BOUNDS> TOKEN: {
//     < BEGINCOMMENT : "<!--"     >
//   | < ENDCOMMENT   : "-->"     >
// }
80 81 82

<DEFAULT, BOUNDS> TOKEN : /* RESERVED WORDS AND LITERALS */
{
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
    < ABBREVIATEDIRI          : "abbreviatedIRI" >
  | < ANNOTATION              : "Annotation" >
  | < ANNOTATIONPROPERTY      : "AnnotationProperty" >
  | < CARDINALITY             : "cardinality" >
  | < CLASS                   : "Class" >
  | < CLASSASSERTION          : "ClassAssertion" >
  | < DATAPROPERTY            : "DataProperty" >
  | < DATAPROPERTYDOMAIN      : "DataPropertyDomain" >
  | < DATAPROPERTYRANGE       : "DataPropertyRange" >
  | < DATATYPE                : "Datatype" >
  | < DATATYPEIRI             : "datatypeIRI" >
  | < DECLARATION             : "Declaration" >
  | < IRI                     : "IRI" >
  | < LITERAL                 : "Literal" >
  | < NAME                    : "name" >
  | < NAMEDINDIVIDUAL         : "NamedIndividual" >
  | < OBJECTEXACTCARDINALITY  : "ObjectExactCardinality" >
  | < OBJECTMINCARDINALITY    : "ObjectMinCardinality" >
  | < OBJECTSOMEVALUESFROM    : "ObjectSomeValuesFrom" >
  | < OBJECTPROPERTY          : "ObjectProperty" >
  | < OBJECTPROPERTYASSERTION : "ObjectPropertyAssertion" >
  | < OBJECTPROPERTYDOMAIN    : "ObjectPropertyDomain" >
  | < ONTOLOGY                : "Ontology" >
  | < ONTOLOGYIRI             : "ontologyIRI" >
  | < PREFIX                  : "Prefix" >
  | < SUBCLASSOF              : "SubClassOf" >
		 

// Compatibility with older ontology format (RDF) below.
  | < LIST_FIRST              : "list:first" >
113 114 115
  | < LIST_REST               : "list:rest" >
  | < EXPR_KIFCONDITION       : "expr:KIF-Condition" >
  | < EXPR_EXPRESSIONDATA     : "expr:expressionData" >
116 117 118 119
  | < EXPRESSION_CONDITION     : "Expression:Condition" >
  | < EXPRESSION_LOGICLANGUAGE : "Expression:LogicLanguage" >
  | < EXPRESSION_REFURI        : "Expression:refURI" >
  | < OBJECTLIST_LIST          : "ObjectList:List" >
120
  | < OWL_ALLVALUESFROM     : "owl:allValuesFrom" >
121
  | < OWL_ALLDIFFERENT      : "owl:AllDifferent" >
122
  | < OWL_CARDINALITY        : "owl:cardinality" >
123 124 125 126
  | < OWL_CLASS             : "owl:Class" >
  | < OWL_DATARANGE         : "owl:DataRange" >
  | < OWL_DATATYPEPROPERTY  : "owl:DatatypeProperty" >
  | < OWL_DISJOINTWITH      : "owl:disjointWith" >
127
  | < OWL_DISTINCTMEMBERS      : "owl:distinctMembers" >
128
  | < OWL_EQUIVALENTCLASS   : "owl:equivalentClass" >
129
  | < OWL_EQUIVALENTPROPERTY : "owl:equivalentProperty" >
130
  | < OWL_FUNCTIONALPROPERTY : "owl:FunctionalProperty" >
131
  | < OWL_HASVALUE             : "owl:hasValue" >
132 133
  | < OWL_IMPORTS            : "owl:imports" >
  | < OWL_INTERSECTIONOF     : "owl:intersectionOf" >
134
  | < OWL_INVERSEOF         : "owl:inverseOf" >
135
  | < OWL_MAXCARDINALITY     : "owl:maxCardinality" >
136
  | < OWL_MINCARDINALITY     : "owl:minCardinality" >
137
  | < OWL_NAMEDINDIVIDUAL   : "owl:NamedIndividual" >
138 139
  | < OWL_OBJECTPROPERTY    : "owl:ObjectProperty" >
  | < OWL_ONPROPERTY        : "owl:onProperty" >
140 141
  | < OWL_ONCLASS           : "owl:onClass" >
  | < OWL_ONDATATYPE        : "owl:onDatatype" >
142 143
  | < OWL_ONEOF             : "owl:oneOf" >
  | < OWL_ONTOLOGY          : "owl:Ontology" >
144
  | < OWL_QUALIFIEDCARDINALITY          : "owl:qualifiedCardinality" >
145 146
  | < OWL_RESTRICTION       : "owl:Restriction" >
  | < OWL_SOMEVALUESFROM    : "owl:someValuesFrom" >
147
  | < OWL_TRANSITIVEPROPERTY : "owl:TransitiveProperty" >
148
  | < OWL_UNIONOF           : "owl:unionOf" >
149
  | < OWL_VERSIONINFO       : "owl:versionInfo" >
150
  | < OWL_WITHRESTRICTIONS  : "owl:withRestrictions" >
151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170
  | < P1_ANYORDER           : "p1:Any-Order" >
  | < P1_COMPONENTS         : "p1:components" >
  | < P1_COMPOSEDOF         : "p1:composedOf" >
  | < P1_CONTROLCONSTRUCTBAG : "p1:ControlConstructBag" >
  | < P1_CONTROLCONSTRUCTLIST : "p1:ControlConstructList" >
  | < P1_ELSE               : "p1:else" >
  | < P1_HASINPUT           : "p1:hasInput" >
  | < P1_HASOUTPUT          : "p1:hasOutput" >
  | < P1_IFCONDITION        : "p1:ifCondition" >
  | < P1_IFTHENELSE         : "p1:If-Then-Else" >
  | < P1_INPUT              : "p1:Input" >
  | < P1_OUTPUT             : "p1:Output" >
  | < P1_PARAMETERTYPE      : "p1:parameterType" >
  | < P1_PERFORM            : "p1:Perform" >
  | < P1_PROCESS            : "p1:process" >
  | < P1_REPEATUNTIL        : "p1:Repeat-Until" >
  | < P1_SEQUENCE           : "p1:Sequence" >
  | < P1_THEN               : "p1:then" >
  | < P1_UNTILCONDITION     : "p1:untilCondition" >
  | < P1_UNTILPROCESS       : "p1:untilProcess" >
171 172
  | < PROCESS_PARTICIPANT     : "Process:Participant" >
  | < PROCESS_PERFORM         : "Process:Perform" >
173 174
  | < RDF_RDF               : "rdf:RDF"      >
  | < RDF_ABOUT             : "rdf:about" >
175
  | < RDF_DATATYPE          : "rdf:datatype" >
176
  | < RDF_DESCRIPTION       : "rdf:Description" >
177 178
  | < RDF_ID                : "rdf:ID" >
  | < RDF_FIRST             : "rdf:first" >
Anders Nilsson's avatar
Anders Nilsson committed
179
  | < RDF_PROPERTY          : "rdf:Property" >
180 181 182 183
  | < RDF_REST              : "rdf:rest" >
  | < RDF_PARSETYPE         : "rdf:parseType" >
  | < RDF_RESOURCE          : "rdf:resource" >
  | < RDF_TYPE              : "rdf:type" >
184
  | < RDFS_COMMENT          : "rdfs:comment" >
185
  | < RDFS_DATATYPE         : "rdfs:Datatype" >
186
  | < RDFS_DOMAIN           : "rdfs:domain" >
187
  | < RDFS_LABEL            : "rdfs:label" >
188
  | < RDFS_RANGE            : "rdfs:range" >
189
  | < RDFS_SEEALSO          : "rdfs:seeAlso" >
190
  | < RDFS_SUBCLASSOF       : "rdfs:subClassOf" >
191
  | < RDFS_SUBPROPERTYOF    : "rdfs:subPropertyOf" >
192
  | < VERSION               : "version" >
193 194 195
  | < XML                   : "xml"          >
  | < XML_BASE              : "xml:base" >
  | < XMLNS                 : "xmlns" >	 
196
  | < XMLNS_XML                 : "xmlns:xml" >	 
197
  | < XMLNS_XX                 : "xmlns:" >	 
198
  | < XSD_MININCLUSIVE      : "xsd:minInclusive" >	 
199 200 201 202 203 204 205 206 207 208 209 210 211 212
//   | < XMLNS_DAML            : "xmlns:daml" >	 
//   | < XMLNS_DC              : "xmlns:dc" >	 
//   | < XMLNS_EXPR              : "xmlns:expr" >	 
//   | < XMLNS_LIST              : "xmlns:list" >	 
//   | < XMLNS_P1              : "xmlns:p1" >	 
//   | < XMLNS_OWL             : "xmlns:owl" >	 
//   | < XMLNS_OWLS             : "xmlns:owl-s" >	 
//   | < XMLNS_PROTEGE         : "xmlns:protege" >	 
//   | < XMLNS_RDF             : "xmlns:rdf" >	 
//   | < XMLNS_RDFS            : "xmlns:rdfs" >	 
//   | < XMLNS_SWRL            : "xmlns:swrl" >	 
//   | < XMLNS_SWRLB           : "xmlns:swrlb" >	 
//   | < XMLNS_XSD             : "xmlns:xsd" >	 
//   | < XMLNS_XSP             : "xmlns:xsp" >	 
213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230

}// RESERVED WORDS AND LITERALS
<DEFAULT, BOUNDS> TOKEN : /* LITERALS */
{
    < INTEGER_LITERAL:
        <DECIMAL_LITERAL> (["l","L"])?
        |
        <HEX_LITERAL> (["l","L"])?
        |
        <OCTAL_LITERAL> (["l","L"])?
    >
    |
    < #DECIMAL_LITERAL: ["1"-"9"] (["0"-"9"])* >
    |
    < #HEX_LITERAL: "0" ["x","X"] (["0"-"9","a"-"f","A"-"F"])+ >
    |
    < #OCTAL_LITERAL: "0" (["0"-"7"])* >
    |
231
    < FLOAT_LITERAL:
232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277
        (["0"-"9"])+ "." (["0"-"9"])* (<EXPONENT>)? (["f","F","d","D"])?
        |
        "." (["0"-"9"])+ (<EXPONENT>)? (["f","F","d","D"])?
        |
        (["0"-"9"])+ <EXPONENT> (["f","F","d","D"])?
        |
        (["0"-"9"])+ (<EXPONENT>)? ["f","F","d","D"]
    >
    |
    < #EXPONENT: ["e","E"] (["+","-"])? (["0"-"9"])+ >
    |
    < CHARACTER_LITERAL:
        "'"
        (   (~["'","\\","\n","\r"])
            |
            ("\\"
                (   ["n","t","b","r","f","\\","'","\""]
                    |
                    ["0"-"7"] ( ["0"-"7"] )?
                    |
                    ["0"-"3"] ["0"-"7"] ["0"-"7"]
                )
            )
        )
        "'"
    >
    |
    < STRING_LITERAL:
        "\""
        (   (~["\"","\\","\n","\r"])
            |
            ("\\"
                (    ["n","t","b","r","f","\\","'","\""]
                     |
                     ["0"-"7"] ( ["0"-"7"] )?
                     |
                     ["0"-"3"] ["0"-"7"] ["0"-"7"]
                )
            )
        )*
        "\""
    >
}// LITERALS

<DEFAULT, BOUNDS> TOKEN : /* IDENTIFIERS */
{
278
    < IDENTIFIER: <LETTER> (<LETTER>|<DIGIT>|"-")* >
279 280 281 282 283 284 285 286 287 288 289 290 291 292 293
    |
    < #LETTER:
        [
        "\u0024",
        "\u0041"-"\u005a",
        "\u005f",
        "\u0061"-"\u007a",
        "\u00c0"-"\u00d6",
        "\u00d8"-"\u00f6",
        "\u00f8"-"\u00ff",
        "\u0100"-"\u1fff",
        "\u3040"-"\u318f",
        "\u3300"-"\u337f",
        "\u3400"-"\u3d2d",
        "\u4e00"-"\u9fff",
294 295 296 297
        "\uf900"-"\ufaff",
		"+",
		"-",
		",",
Anders Nilsson's avatar
Anders Nilsson committed
298 299
		"[",
		"]",
300 301
		".",
		"&",
Anders Nilsson's avatar
Anders Nilsson committed
302 303
		"@",
		";"
304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329
        ]
    >
    |
    < #DIGIT:
        [
        "\u0030"-"\u0039",
        "\u0660"-"\u0669",
        "\u06f0"-"\u06f9",
        "\u0966"-"\u096f",
        "\u09e6"-"\u09ef",
        "\u0a66"-"\u0a6f",
        "\u0ae6"-"\u0aef",
        "\u0b66"-"\u0b6f",
        "\u0be7"-"\u0bef",
        "\u0c66"-"\u0c6f",
        "\u0ce6"-"\u0cef",
        "\u0d66"-"\u0d6f",
        "\u0e50"-"\u0e59",
        "\u0ed0"-"\u0ed9",
        "\u1040"-"\u1049"
        ]
    >
}// IDENTIFIERS

<DEFAULT,BOUNDS> TOKEN : /* SEPARATORS */
{
330 331 332
//       < LPAREN               : "("    >
//     | < RPAREN               : ")"    >
     < LBRACE               : "{"    >
333
    | < RBRACE               : "}"    >
Anders Nilsson's avatar
Anders Nilsson committed
334 335
//     | < LBRACKET             : "["    >
//     | < RBRACKET             : "]"    >
Anders Nilsson's avatar
Anders Nilsson committed
336
    // | < SEMICOLON            : ";"    >
337 338 339
    | < QUOTE                : "\""    >
//     | < COMMA                : ","    >
//     | < DOT                  : "."    >
340 341 342
}// SEPARATORS


343 344
<DEFAULT,BOUNDS> TOKEN : /* OPERATORS */
{
345 346 347
       < ASSIGN               : "="    >
     | < START_ENDTAG        : "</"    >
     | < START_TAG           : "<"    >
348 349 350 351 352
//     | < GT                   : ">"    >
//     | < LT                   : "<"    >
//     | < BANG                 : "!"    >
//     | < TILDE                : "~"    >
//     | < HOOK                 : "?"    >
353
     | < COLON                : ":"    >
354 355 356 357 358 359 360 361
//     | < EQ                   : "=="   >
//     | < LE                   : "<="   >
//     | < GE                   : ">="   >
//     | < NE                   : "!="   >
//     | < SC_OR                : "||"   >
//     | < SC_AND               : "&&"   >
//     | < INCR                 : "++"   >
//     | < DECR                 : "--"   >
362 363
//      | < PLUS                 : "+"    >
//      | < MINUS                : "-"    >
364
//     | < STAR                 : "*"    >
365
     | < SLASH                : "/"    >
366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383
//     | < BIT_AND              : "&"    >
//     | < BIT_OR               : "|"    >
//     | < XOR                  : "^"    >
//     | < REM                  : "%"    >
//     | < LSHIFT               : "<<"   >
//     | < RSIGNEDSHIFT         : ">>"   >
//     | < RUNSIGNEDSHIFT       : ">>>"  >
//     | < PLUSASSIGN           : "+="   >
//     | < MINUSASSIGN          : "-="   >
//     | < STARASSIGN           : "*="   >
//     | < SLASHASSIGN          : "/="   >
//     | < ANDASSIGN            : "&="   >
//     | < ORASSIGN             : "|="   >
//     | < XORASSIGN            : "^="   >
//     | < REMASSIGN            : "%="   >
//     | < LSHIFTASSIGN         : "<<="  >
//     | < RSIGNEDSHIFTASSIGN   : ">>="  >
//     | < RUNSIGNEDSHIFTASSIGN : ">>>=" >
384
}// OPERATORS
385 386


387 388 389 390 391 392
// <DEFAULT,BOUNDS> TOKEN : /* TEXT */
// {
//     < TEXT : <LETTER> (~["<",">"])*    >
// }// TEXT


393 394 395 396
//--------------------------------------------------------------------//
//                      THE OWL LANGUAGE GRAMMAR                     //
//--------------------------------------------------------------------//

397
Start Start() #Start : {}
398
{
399
    Specification()
400 401 402
  { return jjtThis; }
}

403 404
void Specification() #Specification : {}
{
405
    XmlHeader()
406 407
		"<" (RdfDeclaration() 
			 | OntologyDeclaration())
408 409 410 411 412 413 414
}

void XmlHeader() #XmlHeader : {}
{
    "<?" <XML> AttributeList() "?>"
}

415 416 417 418 419 420 421
void OntologyDeclaration() #Ontology : {}
{
    <ONTOLOGY> AttributeList() ">"
	ElementList()
    "</" <ONTOLOGY> ">"
}

422 423
void RdfDeclaration() #RdfDeclaration : {}
{
424
    <RDF_RDF> AttributeList() ">"
425 426 427 428 429 430 431 432 433 434 435
	ElementList()
    "</" <RDF_RDF> ">"
}

void ElementList() #List : {}
{
    (Element())*    
}

void Element() : {}
{
436
    ( "<" ( JElement()
437
		| OntologyElement()
438
	    | OwlElement()
439
	    | RdfElement()
440
	    | P1Element()
441 442
	    | ProcessElement()
	    | DiscardedElement()
443
	    | XsdElement()
444 445 446 447
	    ))
	| SimpleElement()
}

448 449 450 451 452 453 454 455 456 457 458 459
void DiscardedElement() #DiscardedElement : {}
{
	Identifier() AttributeList() 
	(">" ElementList() "</" <IDENTIFIER> ">" | ElementList() "/>")
}

void Identifier() #Identifier : {Token t;}
{
	t = <IDENTIFIER>
	{jjtThis.setIDENTIFIER(t.image);}
}

460 461 462
void SimpleElement() : {}
{
    IntElement()
463
	| FloatElement()
464 465 466 467 468 469
	| StringElement()
}

void IntElement() #IntElement : { Token t; }
{
    t = <INTEGER_LITERAL>
470
	{jjtThis.setLITERAL(t.image);}
471 472
}

473 474 475
void FloatElement() #FloatElement : { Token t; }
{
    t = <FLOAT_LITERAL>
476
	{jjtThis.setLITERAL(t.image);}
477 478
}

479
void StringElement() #StringElement : { Token t;String s; }
480
{
481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508
	t = <IDENTIFIER>
	{
		s = t.image;
		if (getToken(1).kind != START_TAG ) {
		s += getData();
	}
	}
        {jjtThis.setLITERAL(s);}
}

JAVACODE
String getData() {
	StringBuffer s = new StringBuffer();
//     jjtThis.someData = true;
    while ((getToken(1)).kind != START_TAG && (getToken(1)).kind != START_ENDTAG) {
		Token t = getNextToken();
		if (t.specialToken != null) {
			Token tmp_t = t.specialToken;
			while (tmp_t.specialToken != null) {
				tmp_t = tmp_t.specialToken;
			}
			while (tmp_t != null) {
				s.append(tmp_t.image);
				tmp_t = tmp_t.next;
			}
		}
		s.append(t.image);
	}
509
	return s.toString().trim();
510 511
}

512 513 514 515 516 517 518
// void StringElement() #StringElement : { Token t; }
// {
//     t = <IDENTIFIER> | t = <COMMA> | t = <MINUS> | t = <DOT> | t = <PLUS> | t = <SLASH>
// 		| t = <COLON>
// 	{jjtThis.setIDENTIFIER(t.image);}
// }

519 520
void JElement(): {}
{
521 522 523 524
	ListFirst()
	| ListRest()
	| ExprKIFCondition()
	| ExprExpressionData()
525 526 527 528
	| ExpressionCondition()
	| ExpressionLogicLanguage()
	| ExpressionRefURI()
	| ObjectListList()
529 530
}

531
void ListFirst() #ListFirst : {}
532
{
533 534
    <LIST_FIRST> AttributeList() 
	(">" ElementList() "</" <LIST_FIRST> ">" | ElementList() "/>")
535 536
}

537
void ListRest() #ListRest : {}
538
{
539 540
    <LIST_REST> AttributeList() 
	(">" ElementList() "</" <LIST_REST> ">" | ElementList() "/>")
541 542 543
}


544
void ExprKIFCondition() #ExprKIFCondition : {}
545
{
546 547
    <EXPR_KIFCONDITION> AttributeList() 
	(">" ElementList() "</" <EXPR_KIFCONDITION> ">" | ElementList() "/>")
548 549 550
}


551
void ExprExpressionData() #ExprExpressionData : {}
552
{
553 554
    <EXPR_EXPRESSIONDATA> AttributeList() 
	(">" ElementList() "</" <EXPR_EXPRESSIONDATA> ">" | ElementList() "/>")
555 556
}

557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580
void ExpressionCondition() #ExpressionCondition : {}
{
    <EXPRESSION_CONDITION> AttributeList() 
	(">" ElementList() "</" <EXPRESSION_CONDITION> ">" | ElementList() "/>")
}

void ExpressionLogicLanguage() #ExpressionLogicLanguage : {}
{
    <EXPRESSION_LOGICLANGUAGE> AttributeList() 
	(">" ElementList() "</" <EXPRESSION_LOGICLANGUAGE> ">" | ElementList() "/>")
}

void ExpressionRefURI() #ExpressionRefURI : {}
{
    <EXPRESSION_REFURI> AttributeList() 
	(">" ElementList() "</" <EXPRESSION_REFURI> ">" | ElementList() "/>")
}

void ObjectListList() #ObjectListList : {}
{
    <OBJECTLIST_LIST> AttributeList() 
	(">" ElementList() "</" <OBJECTLIST_LIST> ">" | ElementList() "/>")
}

581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724
void OntologyElement() : {}
{
	Annotation()
		| AnnotationProperty()
		| Clazz()
		| ClassAssertion()
		| DataProperty()
		| DataPropertyDomain()
		| DataPropertyRange()
		| Datatype()
		| Declaration()
		| Literal()
		| NamedIndividual()
		| ObjectExactCardinality()
		| ObjectMinCardinality()
		| ObjectSomeValuesFrom()
		| ObjectProperty()
		| ObjectPropertyAssertion()
		| ObjectPropertyDomain()
		| Ontology()
		| Prefix()
		| SubClassOf()
}

void Annotation() #Annotation : {}
{
    <ANNOTATION> AttributeList() 
	(">" ElementList() "</" <ANNOTATION> ">" | ElementList() "/>")
}

void AnnotationProperty() #AnnotationProperty : {}
{
    <ANNOTATIONPROPERTY> AttributeList() 
	(">" ElementList() "</" <ANNOTATIONPROPERTY> ">" | ElementList() "/>")
}

void Clazz() #Clazz : {}
{
    <CLASS> AttributeList() 
	(">" ElementList() "</" <CLASS> ">" | ElementList() "/>")
}

void ClassAssertion() #ClassAssertion : {}
{
    <CLASSASSERTION> AttributeList() 
	(">" ElementList() "</" <CLASSASSERTION> ">" | ElementList() "/>")
}

void DataProperty() #DataProperty : {}
{
    <DATAPROPERTY> AttributeList() 
	(">" ElementList() "</" <DATAPROPERTY> ">" | ElementList() "/>")
}

void DataPropertyDomain() #DataPropertyDomain : {}
{
    <DATAPROPERTYDOMAIN> AttributeList() 
	(">" ElementList() "</" <DATAPROPERTYDOMAIN> ">" | ElementList() "/>")
}

void DataPropertyRange() #DataPropertyRange : {}
{
    <DATAPROPERTYRANGE> AttributeList() 
	(">" ElementList() "</" <DATAPROPERTYRANGE> ">" | ElementList() "/>")
}

void Datatype() #Datatype : {}
{
    <DATATYPE> AttributeList() 
	(">" ElementList() "</" <DATATYPE> ">" | ElementList() "/>")
}

void Declaration() #Declaration : {}
{
    <DECLARATION> AttributeList() 
	(">" ElementList() "</" <DECLARATION> ">" | ElementList() "/>")
}

void Literal() #Literal : {}
{
    <LITERAL> AttributeList() 
	(">" ElementList() "</" <LITERAL> ">" | ElementList() "/>")
}

void NamedIndividual() #NamedIndividual : {}
{
    <NAMEDINDIVIDUAL> AttributeList() 
	(">" ElementList() "</" <NAMEDINDIVIDUAL> ">" | ElementList() "/>")
}

void ObjectExactCardinality() #ObjectExactCardinality : {}
{
    <OBJECTEXACTCARDINALITY> AttributeList() 
	(">" ElementList() "</" <OBJECTEXACTCARDINALITY> ">" | ElementList() "/>")
}

void ObjectMinCardinality() #ObjectMinCardinality : {}
{
    <OBJECTMINCARDINALITY> AttributeList() 
	(">" ElementList() "</" <OBJECTMINCARDINALITY> ">" | ElementList() "/>")
}

void ObjectSomeValuesFrom() #ObjectSomeValuesFrom : {}
{
    <OBJECTSOMEVALUESFROM> AttributeList() 
	(">" ElementList() "</" <OBJECTSOMEVALUESFROM> ">" | ElementList() "/>")
}

void ObjectProperty() #ObjectProperty : {}
{
    <OBJECTPROPERTY> AttributeList() 
	(">" ElementList() "</" <OBJECTPROPERTY> ">" | ElementList() "/>")
}

void ObjectPropertyAssertion() #ObjectPropertyAssertion : {}
{
    <OBJECTPROPERTYASSERTION> AttributeList() 
	(">" ElementList() "</" <OBJECTPROPERTYASSERTION> ">" | ElementList() "/>")
}

void ObjectPropertyDomain() #ObjectPropertyDomain : {}
{
    <OBJECTPROPERTYDOMAIN> AttributeList() 
	(">" ElementList() "</" <OBJECTPROPERTYDOMAIN> ">" | ElementList() "/>")
}

void Ontology() #Ontology : {}
{
    <ONTOLOGY> AttributeList() 
	(">" ElementList() "</" <ONTOLOGY> ">" | ElementList() "/>")
}

void Prefix() #Prefix : {}
{
    <PREFIX> AttributeList() 
	(">" ElementList() "</" <PREFIX> ">" | ElementList() "/>")
}

void SubClassOf() #SubClassOf : {}
{
    <SUBCLASSOF> AttributeList() 
	(">" ElementList() "</" <SUBCLASSOF> ">" | ElementList() "/>")
}

725 726 727
void OwlElement() : {}
{
    OwlOntology()
728
	| OwlAllDifferent()
729
	| OwlAllValuesFrom()
730
	| OwlCardinality()
731
	| OwlClass()
732 733
	| OwlDataRange()
	| OwlDatatypeProperty()
734
	| OwlDisjointWith()
735
	| OwlDistinctMembers()
736
	| OwlEquivalentClass()
737
	| OwlEquivalentProperty()
738
	| OwlFunctionalProperty()
739
	| OwlHasValue()
740 741
	| OwlImports()
	| OwlIntersectionOf()
742
	| OwlInverseOf()
743
	| OwlMaxCardinality()
744
	| OwlMinCardinality()
745
	| OwlNamedIndividual()
746
	| OwlObjectProperty()
747
	| OwlOneOf()
748 749
	| OwlOnClass()
	| OwlOnDatatype()
750
	| OwlOnProperty()
751
	| OwlQualifiedCardinality()
752
	| OwlRestriction()
753 754
	| OwlSomeValuesFrom()
	| OwlTransitiveProperty()
755
	| OwlUnionOf()
756
	| OwlVersionInfo()
757
	| OwlWithRestrictions()
758 759 760 761
}

void OwlOntology() #OwlOntology : {}
{
762 763
    <OWL_ONTOLOGY> AttributeList() 
	(">" ElementList() "</" <OWL_ONTOLOGY> ">" | ElementList() "/>")
764 765
}

766 767 768 769 770 771
void OwlAllDifferent() #OwlAllDifferent : {}
{
    <OWL_ALLDIFFERENT> AttributeList() 
	(">" ElementList() "</" <OWL_ALLDIFFERENT> ">" | ElementList() "/>")
}

772 773 774 775 776 777
void OwlAllValuesFrom() #OwlAllValuesFrom : {}
{
    <OWL_ALLVALUESFROM> AttributeList() 
	(">" ElementList() "</" <OWL_ALLVALUESFROM> ">" | ElementList() "/>")
}

778 779 780 781 782 783
void OwlCardinality() #OwlCardinality : {}
{
    <OWL_CARDINALITY> AttributeList() 
	(">" ElementList() "</" <OWL_CARDINALITY> ">" | ElementList() "/>")
}

784 785 786 787 788 789
void OwlClass() #OwlClass : {}
{
    <OWL_CLASS> AttributeList() 
	(">" ElementList() "</" <OWL_CLASS> ">" | ElementList() "/>")
}

790 791 792 793 794 795 796 797 798 799 800 801
void OwlDataRange() #OwlDataRange : {}
{
    <OWL_DATARANGE> AttributeList() 
	(">" ElementList() "</" <OWL_DATARANGE> ">" | ElementList() "/>")
}

void OwlDatatypeProperty() #OwlDatatypeProperty : {}
{
    <OWL_DATATYPEPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_DATATYPEPROPERTY> ">" | ElementList() "/>")
}

802 803 804 805 806 807
void OwlDisjointWith() #OwlDisjointWith : {}
{
    <OWL_DISJOINTWITH> AttributeList() 
	(">" ElementList() "</" <OWL_DISJOINTWITH> ">" | ElementList() "/>")
}

808 809 810 811 812 813
void OwlDistinctMembers() #OwlDistinctMembers : {}
{
    <OWL_DISTINCTMEMBERS> AttributeList() 
	(">" ElementList() "</" <OWL_DISTINCTMEMBERS> ">" | ElementList() "/>")
}

814 815 816 817 818 819
void OwlEquivalentClass() #OwlEquivalentClass : {}
{
    <OWL_EQUIVALENTCLASS> AttributeList() 
	(">" ElementList() "</" <OWL_EQUIVALENTCLASS> ">" | ElementList() "/>")
}

820 821 822 823 824 825
void OwlEquivalentProperty() #OwlEquivalentProperty : {}
{
    <OWL_EQUIVALENTPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_EQUIVALENTPROPERTY> ">" | ElementList() "/>")
}

826 827 828 829 830 831
void OwlFunctionalProperty() #OwlFunctionalProperty : {}
{
    <OWL_FUNCTIONALPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_FUNCTIONALPROPERTY> ">" | ElementList() "/>")
}

832 833 834 835 836 837
void OwlHasValue () #OwlHasValue  : {}
{
    <OWL_HASVALUE> AttributeList() 
	(">" ElementList() "</" <OWL_HASVALUE> ">" | ElementList() "/>")
}

838 839 840 841 842 843 844 845 846 847 848 849
void OwlImports () #OwlImports  : {}
{
    <OWL_IMPORTS> AttributeList() 
	(">" ElementList() "</" <OWL_IMPORTS> ">" | ElementList() "/>")
}

void OwlIntersectionOf () #OwlIntersectionOf  : {}
{
    <OWL_INTERSECTIONOF> AttributeList() 
	(">" ElementList() "</" <OWL_INTERSECTIONOF> ">" | ElementList() "/>")
}

850 851 852 853 854 855
void OwlInverseOf () #OwlInverseOf  : {}
{
    <OWL_INVERSEOF> AttributeList() 
	(">" ElementList() "</" <OWL_INVERSEOF> ">" | ElementList() "/>")
}

856 857 858 859 860 861
void OwlMaxCardinality () #OwlMaxCardinality  : {}
{
    <OWL_MAXCARDINALITY> AttributeList() 
	(">" ElementList() "</" <OWL_MAXCARDINALITY> ">" | ElementList() "/>")
}

862 863 864 865 866 867
void OwlMinCardinality () #OwlMinCardinality  : {}
{
    <OWL_MINCARDINALITY> AttributeList() 
	(">" ElementList() "</" <OWL_MINCARDINALITY> ">" | ElementList() "/>")
}

868 869 870 871 872 873
void OwlNamedIndividual () #OwlNamedIndividual  : {}
{
    <OWL_NAMEDINDIVIDUAL> AttributeList() 
	(">" ElementList() "</" <OWL_NAMEDINDIVIDUAL> ">" | ElementList() "/>")
}

874 875 876 877 878 879
void OwlObjectProperty () #OwlObjectProperty  : {}
{
    <OWL_OBJECTPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_OBJECTPROPERTY> ">" | ElementList() "/>")
}

880 881 882 883 884 885
void OwlOneOf () #OwlOneOf  : {}
{
    <OWL_ONEOF> AttributeList() 
	(">" ElementList() "</" <OWL_ONEOF> ">" | ElementList() "/>")
}

886 887 888 889 890 891 892 893 894 895 896 897
void OwlOnClass () #OwlOnClass  : {}
{
    <OWL_ONCLASS> AttributeList() 
	(">" ElementList() "</" <OWL_ONCLASS> ">" | ElementList() "/>")
}

void OwlOnDatatype () #OwlOnDatatype  : {}
{
    <OWL_ONDATATYPE> AttributeList() 
	(">" ElementList() "</" <OWL_ONDATATYPE> ">" | ElementList() "/>")
}

898 899 900 901 902 903
void OwlOnProperty () #OwlOnProperty  : {}
{
    <OWL_ONPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_ONPROPERTY> ">" | ElementList() "/>")
}

904 905 906 907 908 909
void OwlQualifiedCardinality () #OwlQualifiedCardinality  : {}
{
    <OWL_QUALIFIEDCARDINALITY> AttributeList() 
	(">" ElementList() "</" <OWL_QUALIFIEDCARDINALITY> ">" | ElementList() "/>")
}

910 911 912 913 914 915
void OwlRestriction () #OwlRestriction  : {}
{
    <OWL_RESTRICTION> AttributeList() 
	(">" ElementList() "</" <OWL_RESTRICTION> ">" | ElementList() "/>")
}

916 917 918 919 920 921
void OwlSomeValuesFrom () #OwlSomeValuesFrom  : {}
{
    <OWL_SOMEVALUESFROM> AttributeList() 
	(">" ElementList() "</" <OWL_SOMEVALUESFROM> ">" | ElementList() "/>")
}

922
void OwlTransitiveProperty () #OwlTransitiveProperty  : {}
923
{
924 925
    <OWL_TRANSITIVEPROPERTY> AttributeList() 
	(">" ElementList() "</" <OWL_TRANSITIVEPROPERTY> ">" | ElementList() "/>")
926 927
}

928 929 930 931 932 933
void OwlUnionOf () #OwlUnionOf  : {}
{
    <OWL_UNIONOF> AttributeList() 
	(">" ElementList() "</" <OWL_UNIONOF> ">" | ElementList() "/>")
}

934 935 936 937 938 939
void OwlVersionInfo () #OwlVersionInfo  : {}
{
    <OWL_VERSIONINFO> AttributeList() 
	(">" ElementList() "</" <OWL_VERSIONINFO> ">" | ElementList() "/>")
}

940 941 942 943 944 945
void OwlWithRestrictions () #OwlWithRestrictions  : {}
{
    <OWL_WITHRESTRICTIONS> AttributeList() 
	(">" ElementList() "</" <OWL_WITHRESTRICTIONS> ">" | ElementList() "/>")
}

946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089
void P1Element() : {}
{
    P1AnyOrder()
    | P1Components()
    | P1ComposedOf()
	| P1ControlConstructBag()
	| P1ControlConstructList()
	| P1Else()
	| P1HasInput()
	| P1HasOutput()
	| P1IfCondition()
	| P1IfThenElse()
	| P1Input()
	| P1Output()
	| P1ParameterType()
	| P1Perform()
	| P1Process()
	| P1RepeatUntil()
	| P1Sequence()
	| P1Then()
	| P1UntilCondition()
	| P1UntilProcess()
}

void P1AnyOrder() #P1AnyOrder : {}
{
    <P1_ANYORDER> AttributeList() 
	(">" ElementList() "</" <P1_ANYORDER> ">" | ElementList() "/>")
}

void P1Components() #P1Components : {}
{
    <P1_COMPONENTS> AttributeList() 
	(">" ElementList() "</" <P1_COMPONENTS> ">" | ElementList() "/>")
}

void P1ComposedOf() #P1ComposedOf : {}
{
    <P1_COMPOSEDOF> AttributeList() 
	(">" ElementList() "</" <P1_COMPOSEDOF> ">" | ElementList() "/>")
}

void P1ControlConstructBag() #P1ControlConstructBag : {}
{
    <P1_CONTROLCONSTRUCTBAG> AttributeList() 
	(">" ElementList() "</" <P1_CONTROLCONSTRUCTBAG> ">" | ElementList() "/>")
}

void P1ControlConstructList() #P1ControlConstructList : {}
{
    <P1_CONTROLCONSTRUCTLIST> AttributeList() 
	(">" ElementList() "</" <P1_CONTROLCONSTRUCTLIST> ">" | ElementList() "/>")
}

void P1Else() #P1Else : {}
{
    <P1_ELSE> AttributeList() 
	(">" ElementList() "</" <P1_ELSE> ">" | ElementList() "/>")
}

void P1HasInput() #P1HasInput : {}
{
    <P1_HASINPUT> AttributeList() 
	(">" ElementList() "</" <P1_HASINPUT> ">" | ElementList() "/>")
}

void P1HasOutput() #P1HasOutput : {}
{
    <P1_HASOUTPUT> AttributeList() 
	(">" ElementList() "</" <P1_HASOUTPUT> ">" | ElementList() "/>")
}

void P1IfCondition() #P1IfCondition : {}
{
    <P1_IFCONDITION> AttributeList() 
	(">" ElementList() "</" <P1_IFCONDITION> ">" | ElementList() "/>")
}

void P1IfThenElse() #P1IfThenElse : {}
{
    <P1_IFTHENELSE> AttributeList() 
	(">" ElementList() "</" <P1_IFTHENELSE> ">" | ElementList() "/>")
}

void P1Input() #P1Input : {}
{
    <P1_INPUT> AttributeList() 
	(">" ElementList() "</" <P1_INPUT> ">" | ElementList() "/>")
}

void P1Output() #P1Output : {}
{
    <P1_OUTPUT> AttributeList() 
	(">" ElementList() "</" <P1_OUTPUT> ">" | ElementList() "/>")
}

void P1ParameterType() #P1ParameterType : {}
{
    <P1_PARAMETERTYPE> AttributeList() 
	(">" ElementList() "</" <P1_PARAMETERTYPE> ">" | ElementList() "/>")
}

void P1Perform() #P1Perform : {}
{
    <P1_PERFORM> AttributeList() 
	(">" ElementList() "</" <P1_PERFORM> ">" | ElementList() "/>")
}

void P1Process() #P1Process : {}
{
    <P1_PROCESS> AttributeList() 
	(">" ElementList() "</" <P1_PROCESS> ">" | ElementList() "/>")
}

void P1RepeatUntil() #P1RepeatUntil : {}
{
    <P1_REPEATUNTIL> AttributeList() 
	(">" ElementList() "</" <P1_REPEATUNTIL> ">" | ElementList() "/>")
}

void P1Sequence() #P1Sequence : {}
{
    <P1_SEQUENCE> AttributeList() 
	(">" ElementList() "</" <P1_SEQUENCE> ">" | ElementList() "/>")
}

void P1Then() #P1Then : {}
{
    <P1_THEN> AttributeList() 
	(">" ElementList() "</" <P1_THEN> ">" | ElementList() "/>")
}

void P1UntilCondition() #P1UntilCondition : {}
{
    <P1_UNTILCONDITION> AttributeList() 
	(">" ElementList() "</" <P1_UNTILCONDITION> ">" | ElementList() "/>")
}

void P1UntilProcess() #P1UntilProcess : {}
{
    <P1_UNTILPROCESS> AttributeList() 
	(">" ElementList() "</" <P1_UNTILPROCESS> ">" | ElementList() "/>")
}

1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107
void ProcessElement(): {}
{
    ProcessParticipant()
  | ProcessPerform()
}

void ProcessParticipant() #ProcessParticipant : {}
{
    <PROCESS_PARTICIPANT> AttributeList() 
	(">" ElementList() "</" <PROCESS_PARTICIPANT> ">" | ElementList() "/>")
}

void ProcessPerform() #ProcessPerform : {}
{
    <PROCESS_PERFORM> AttributeList() 
	(">" ElementList() "</" <PROCESS_PERFORM> ">" | ElementList() "/>")
}

1108

1109 1110
void RdfElement() : {}
{
1111
    RdfType()
1112
	| RdfDescription()
1113
	| RdfFirst()
Anders Nilsson's avatar
Anders Nilsson committed
1114
	| RdfProperty()
1115
	| RdfRest()
1116
	| RdfsComment()
1117
	| RdfsDatatype()
1118
	| RdfsDomain()
1119
	| RdfsLabel()
1120
	| RdfsRange()
1121
	| RdfsSeeAlso()
1122 1123
	| RdfsSubClassOf()
	| RdfsSubPropertyOf()
1124 1125
}

1126
void RdfType() #RdfType : {}
1127
{
1128 1129 1130 1131
    <RDF_TYPE> AttributeList() 
	(">" ElementList() "</" <RDF_TYPE> ">" | ElementList() "/>")
}

1132 1133 1134 1135 1136 1137
void RdfDescription() #RdfDescription : {}
{
    <RDF_DESCRIPTION> AttributeList() 
	(">" ElementList() "</" <RDF_DESCRIPTION> ">" | ElementList() "/>")
}

1138 1139 1140 1141 1142 1143
void RdfFirst() #RdfFirst : {}
{
    <RDF_FIRST> AttributeList() 
	(">" ElementList() "</" <RDF_FIRST> ">" | ElementList() "/>")
}

Anders Nilsson's avatar
Anders Nilsson committed
1144 1145 1146 1147 1148 1149
void RdfProperty() #RdfProperty : {}
{
    <RDF_PROPERTY> AttributeList() 
	(">" ElementList() "</" <RDF_PROPERTY> ">" | ElementList() "/>")
}

1150 1151 1152 1153
void RdfRest() #RdfRest : {}
{
    <RDF_REST> AttributeList() 
	(">" ElementList() "</" <RDF_REST> ">" | ElementList() "/>")
1154 1155
}

1156 1157 1158 1159 1160 1161
void RdfsComment() #RdfsComment : {}
{
    <RDFS_COMMENT> AttributeList() 
	(">" ElementList() "</" <RDFS_COMMENT> ">" | ElementList() "/>")
}

1162 1163 1164 1165 1166 1167
void RdfsDatatype() #RdfsDatatype : {}
{
    <RDFS_DATATYPE> AttributeList() 
	(">" ElementList() "</" <RDFS_DATATYPE> ">" | ElementList() "/>")
}

1168 1169 1170 1171
void RdfsDomain() #RdfsDomain : {}
{
    <RDFS_DOMAIN> AttributeList() 
	(">" ElementList() "</" <RDFS_DOMAIN> ">" | ElementList() "/>")
1172 1173
}

1174 1175 1176 1177 1178 1179
void RdfsLabel() #RdfsLabel : {}
{
    <RDFS_LABEL> AttributeList() 
	(">" ElementList() "</" <RDFS_LABEL> ">" | ElementList() "/>")
}

1180 1181 1182 1183 1184 1185
void RdfsRange() #RdfsRange : {}
{
    <RDFS_RANGE> AttributeList() 
	(">" ElementList() "</" <RDFS_RANGE> ">" | ElementList() "/>")
}

1186 1187 1188 1189 1190 1191
void RdfsSeeAlso() #RdfsSeeAlso : {}
{
    <RDFS_SEEALSO> AttributeList() 
	(">" ElementList() "</" <RDFS_SEEALSO> ">" | ElementList() "/>")
}

1192 1193 1194 1195 1196 1197
void RdfsSubClassOf() #RdfsSubClassOf : {}
{
    <RDFS_SUBCLASSOF> AttributeList() 
	(">" ElementList() "</" <RDFS_SUBCLASSOF> ">" | ElementList() "/>")
}

1198 1199 1200 1201 1202 1203
void RdfsSubPropertyOf() #RdfsSubPropertyOf : {}
{
    <RDFS_SUBPROPERTYOF> AttributeList() 
	(">" ElementList() "</" <RDFS_SUBPROPERTYOF> ">" | ElementList() "/>")
}

1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214
void XsdElement() : {}
{
    XsdMinInclusive()
}

void XsdMinInclusive() #XsdMinInclusive : {}
{
    <XSD_MININCLUSIVE> AttributeList() 
	(">" ElementList() "</" <XSD_MININCLUSIVE> ">" | ElementList() "/>")
}

1215 1216 1217 1218 1219
void AttributeList() #List : {}
{
    (Attribute())*
}

1220 1221 1222
void Attribute() : {}
{
    Version()
1223
	| OntologyAttribute()
1224 1225 1226 1227 1228 1229 1230 1231 1232 1233
	| RdfAttribute()
	| XmlAttribute()
	| XmlnsAttribute()
}

void Version() #Version : {}
{
    <VERSION> <ASSIGN> Value()
}

1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273
void OntologyAttribute() : {}
{
	AbbreviatedIRI()
		| Cardinality()
		| DatatypeIRI()
		| IRI()
		| Name()
		| OntologyIRI()
}

void AbbreviatedIRI() #AbbreviatedIRI : {}
{
    <ABBREVIATEDIRI> <ASSIGN> Value()
}

void Cardinality() #Cardinality : {}
{
    <CARDINALITY> <ASSIGN> Value()
}

void DatatypeIRI() #DatatypeIRI : {}
{
    <DATATYPEIRI> <ASSIGN> Value()
}

void IRI() #IRI : {}
{
    <IRI> <ASSIGN> Value()
}

void Name() #Name : {}
{
    <NAME> <ASSIGN> Value()
}

void OntologyIRI() #OntologyIRI : {}
{
    <ONTOLOGYIRI> <ASSIGN> Value()
}

1274 1275 1276
void RdfAttribute() : {}
{
    RdfAbout()
1277
	| RdfDatatype()
1278
	| RdfId()
1279
	| RdfParseType()
1280 1281 1282 1283 1284 1285 1286 1287
	| RdfResource()
}

void RdfAbout() #RdfAbout : {}
{
    <RDF_ABOUT> <ASSIGN> Value()
}

1288 1289 1290 1291 1292
void RdfDatatype() #RdfDatatype : {}
{
    <RDF_DATATYPE> <ASSIGN> Value()
}

1293 1294 1295 1296 1297
void RdfId() #RdfId : {}
{
    <RDF_ID> <ASSIGN> Value()
}

1298 1299 1300 1301 1302 1303
void RdfParseType() #RdfParseType : {}
{
    <RDF_PARSETYPE> <ASSIGN> Value()
}

void RdfResource() #RdfResource : {}
1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320
{
    <RDF_RESOURCE> <ASSIGN> Value()
}

void XmlAttribute() : {}
{
    XmlBase()
}

void XmlBase() #XmlBase : {}
{
    <XML_BASE> <ASSIGN> Value()
}

void XmlnsAttribute() : {}
{
    Xmlns()
1321
  | XmlnsXml()
1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336
  | XmlnsXX()
// 	| XmlnsDaml()
// 	| XmlnsDc()
// 	| XmlnsExpr()
// 	| XmlnsList()
// 	| XmlnsOwl()
// 	| XmlnsOwls()
// 	| XmlnsP1()
// 	| XmlnsProtege()
// 	| XmlnsRdf()
// 	| XmlnsRdfs()
// 	| XmlnsSwrl()
// 	| XmlnsSwrlb()
// 	| XmlnsXsd()
// 	| XmlnsXsp()
1337 1338 1339 1340 1341 1342 1343
}

void Xmlns() #Xmlns : {}
{
    <XMLNS> <ASSIGN> Value()
}

1344 1345 1346 1347 1348
void XmlnsXml() #XmlnsXml : {}
{
    <XMLNS_XML> <ASSIGN> Value()
}

1349
void XmlnsXX() #XmlnsXX : {Token t;}
1350
{
1351 1352
    <XMLNS_XX> t = <IDENTIFIER> <ASSIGN> Value()
	{jjtThis.setIDENTIFIER(t.image);}
1353 1354
}

1355 1356 1357 1358
// void XmlnsDaml() #XmlnsDaml : {}
// {
//     <XMLNS_DAML> <ASSIGN> Value()
// }
1359

1360 1361 1362 1363
// void XmlnsDc() #XmlnsDc : {}
// {
//     <XMLNS_DC> <ASSIGN> Value()
// }
1364

1365 1366 1367 1368
// void XmlnsExpr() #XmlnsExpr : {}
// {
//     <XMLNS_EXPR> <ASSIGN> Value()
// }
1369

1370 1371 1372 1373
// void XmlnsList() #XmlnsList : {}
// {
//     <XMLNS_LIST> <ASSIGN> Value()
// }
1374

1375 1376 1377 1378
// void XmlnsP1() #XmlnsP1 : {}
// {
//     <XMLNS_P1> <ASSIGN> Value()
// }
1379

1380 1381 1382 1383
// void XmlnsProtege() #XmlnsProtege : {}
// {
//     <XMLNS_PROTEGE> <ASSIGN> Value()
// }
1384

1385 1386 1387 1388
// void XmlnsRdf() #XmlnsRdf : {}
// {
//     <XMLNS_RDF> <ASSIGN> Value()
// }
1389

1390 1391 1392 1393
// void XmlnsSwrl() #XmlnsSwrl : {}
// {
//     <XMLNS_SWRL> <ASSIGN> Value()
// }
1394

1395 1396 1397 1398
// void XmlnsSwrlb() #XmlnsSwrlb : {}
// {
//     <XMLNS_SWRLB> <ASSIGN> Value()
// }
1399

1400 1401 1402 1403
// void XmlnsXsd() #XmlnsXsd : {}
// {
//     <XMLNS_XSD> <ASSIGN> Value()
// }
1404

1405 1406 1407 1408
// void XmlnsXsp() #XmlnsXsp : {}
// {
//     <XMLNS_XSP> <ASSIGN> Value()
// }
1409

1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423
// void XmlnsRdfs() #XmlnsRdfs : {}
// {
//     <XMLNS_RDFS> <ASSIGN> Value()
// }

// void XmlnsOwl() #XmlnsOwl : {}
// {
//     <XMLNS_OWL> <ASSIGN> Value()
// }

// void XmlnsOwls() #XmlnsOwls : {}
// {
//     <XMLNS_OWLS> <ASSIGN> Value()
// }
1424 1425 1426 1427 1428

void Value() #Value : { Token t; }
{
    t = <STRING_LITERAL>
	{jjtThis.setSTRING_LITERAL(t.image);}
1429
}
1430