1 /* 2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26 /* this file is generated by RelaxNGCC */ 27 package com.sun.xml.internal.xsom.impl.parser.state; 28 import org.xml.sax.SAXException; 29 import org.xml.sax.XMLReader; 30 import org.xml.sax.Attributes; 31 import com.sun.xml.internal.xsom.impl.parser.NGCCRuntimeEx; 32 33 import com.sun.xml.internal.xsom.*; 34 import com.sun.xml.internal.xsom.parser.*; 35 import com.sun.xml.internal.xsom.impl.*; 36 import com.sun.xml.internal.xsom.impl.parser.*; 37 import org.xml.sax.Locator; 38 import org.xml.sax.ContentHandler; 39 import org.xml.sax.helpers.*; 40 import java.util.*; 41 import java.math.BigInteger; 42 43 44 45 class attributeDeclBody extends NGCCHandler { 46 private String name; 47 private ForeignAttributesImpl fa; 48 private AnnotationImpl annotation; 49 private Locator locator; 50 private boolean isLocal; 51 private String defaultValue; 52 private UName typeName; 53 private String fixedValue; 54 protected final NGCCRuntimeEx $runtime; 55 private int $_ngcc_current_state; 56 protected String $uri; 57 protected String $localName; 58 protected String $qname; 59 60 public final NGCCRuntime getRuntime() { 61 return($runtime); 441 NGCCHandler h = new qualification(this, super._source, $runtime, 395); 442 spawnChildFromText(h, $value); 443 } 444 } 445 } 446 break; 447 case 1: 448 { 449 if(($ai = $runtime.getAttributeIndex("","type"))>=0) { 450 $runtime.consumeAttribute($ai); 451 $runtime.sendText(super._cookie, $value); 452 } 453 else { 454 $_ngcc_current_state = 0; 455 $runtime.sendText(super._cookie, $value); 456 } 457 } 458 break; 459 case 11: 460 { 461 name = $value; 462 $_ngcc_current_state = 10; 463 } 464 break; 465 case 5: 466 { 467 NGCCHandler h = new qname(this, super._source, $runtime, 381); 468 spawnChildFromText(h, $value); 469 } 470 break; 471 } 472 } 473 474 public void onChildCompleted(Object $__result__, int $__cookie__, boolean $__needAttCheck__)throws SAXException { 475 switch($__cookie__) { 476 case 388: 477 { 478 annotation = ((AnnotationImpl)$__result__); 479 $_ngcc_current_state = 1; 480 } 481 break; 482 case 379: 483 { 484 type = ((SimpleTypeImpl)$__result__); 485 $_ngcc_current_state = 0; 486 } 487 break; 488 case 390: | 1 /* 2 * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided 9 * by Oracle in the LICENSE file that accompanied this code. 10 * 11 * This code is distributed in the hope that it will be useful, but WITHOUT 12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 14 * version 2 for more details (a copy is included in the LICENSE file that 15 * accompanied this code). 16 * 17 * You should have received a copy of the GNU General Public License version 18 * 2 along with this work; if not, write to the Free Software Foundation, 19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 20 * 21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 22 * or visit www.oracle.com if you need additional information or have any 23 * questions. 24 */ 25 26 /* this file is generated by RelaxNGCC */ 27 package com.sun.xml.internal.xsom.impl.parser.state; 28 29 import com.sun.xml.internal.bind.WhiteSpaceProcessor; 30 import org.xml.sax.SAXException; 31 import org.xml.sax.Attributes; 32 import com.sun.xml.internal.xsom.impl.parser.NGCCRuntimeEx; 33 34 import com.sun.xml.internal.xsom.parser.*; 35 import com.sun.xml.internal.xsom.impl.*; 36 import com.sun.xml.internal.xsom.impl.parser.*; 37 import org.xml.sax.Locator; 38 39 40 41 class attributeDeclBody extends NGCCHandler { 42 private String name; 43 private ForeignAttributesImpl fa; 44 private AnnotationImpl annotation; 45 private Locator locator; 46 private boolean isLocal; 47 private String defaultValue; 48 private UName typeName; 49 private String fixedValue; 50 protected final NGCCRuntimeEx $runtime; 51 private int $_ngcc_current_state; 52 protected String $uri; 53 protected String $localName; 54 protected String $qname; 55 56 public final NGCCRuntime getRuntime() { 57 return($runtime); 437 NGCCHandler h = new qualification(this, super._source, $runtime, 395); 438 spawnChildFromText(h, $value); 439 } 440 } 441 } 442 break; 443 case 1: 444 { 445 if(($ai = $runtime.getAttributeIndex("","type"))>=0) { 446 $runtime.consumeAttribute($ai); 447 $runtime.sendText(super._cookie, $value); 448 } 449 else { 450 $_ngcc_current_state = 0; 451 $runtime.sendText(super._cookie, $value); 452 } 453 } 454 break; 455 case 11: 456 { 457 // <xs:attribute> with attribute 'name' = $value 458 name = WhiteSpaceProcessor.collapse($value); 459 $_ngcc_current_state = 10; 460 } 461 break; 462 case 5: 463 { 464 // <xs:attribute> with attribute 'type' = $value 465 NGCCHandler h = new qname(this, super._source, $runtime, 381); 466 spawnChildFromText(h, WhiteSpaceProcessor.collapse($value)); 467 } 468 break; 469 } 470 } 471 472 public void onChildCompleted(Object $__result__, int $__cookie__, boolean $__needAttCheck__)throws SAXException { 473 switch($__cookie__) { 474 case 388: 475 { 476 annotation = ((AnnotationImpl)$__result__); 477 $_ngcc_current_state = 1; 478 } 479 break; 480 case 379: 481 { 482 type = ((SimpleTypeImpl)$__result__); 483 $_ngcc_current_state = 0; 484 } 485 break; 486 case 390: |