src/share/jaxws_classes/com/sun/xml/internal/xsom/impl/parser/state/notation.java

changeset 286
f50545b5e2f1
child 397
b99d7e355d4b
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/share/jaxws_classes/com/sun/xml/internal/xsom/impl/parser/state/notation.java	Tue Mar 06 16:09:35 2012 -0800
     1.3 @@ -0,0 +1,483 @@
     1.4 +/*
     1.5 + * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved.
     1.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.7 + *
     1.8 + * This code is free software; you can redistribute it and/or modify it
     1.9 + * under the terms of the GNU General Public License version 2 only, as
    1.10 + * published by the Free Software Foundation.  Oracle designates this
    1.11 + * particular file as subject to the "Classpath" exception as provided
    1.12 + * by Oracle in the LICENSE file that accompanied this code.
    1.13 + *
    1.14 + * This code is distributed in the hope that it will be useful, but WITHOUT
    1.15 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1.16 + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    1.17 + * version 2 for more details (a copy is included in the LICENSE file that
    1.18 + * accompanied this code).
    1.19 + *
    1.20 + * You should have received a copy of the GNU General Public License version
    1.21 + * 2 along with this work; if not, write to the Free Software Foundation,
    1.22 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    1.23 + *
    1.24 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
    1.25 + * or visit www.oracle.com if you need additional information or have any
    1.26 + * questions.
    1.27 + */
    1.28 +
    1.29 +/* this file is generated by RelaxNGCC */
    1.30 +package com.sun.xml.internal.xsom.impl.parser.state;
    1.31 +import org.xml.sax.SAXException;
    1.32 +import org.xml.sax.XMLReader;
    1.33 +import org.xml.sax.Attributes;
    1.34 +import com.sun.xml.internal.xsom.impl.parser.NGCCRuntimeEx;
    1.35 +
    1.36 +    import com.sun.xml.internal.xsom.*;
    1.37 +    import com.sun.xml.internal.xsom.parser.*;
    1.38 +    import com.sun.xml.internal.xsom.impl.*;
    1.39 +    import com.sun.xml.internal.xsom.impl.parser.*;
    1.40 +    import org.xml.sax.Locator;
    1.41 +    import org.xml.sax.ContentHandler;
    1.42 +    import org.xml.sax.helpers.*;
    1.43 +    import java.util.*;
    1.44 +    import java.math.BigInteger;
    1.45 +
    1.46 +
    1.47 +
    1.48 +class notation extends NGCCHandler {
    1.49 +    private String name;
    1.50 +    private String pub;
    1.51 +    private ForeignAttributesImpl fa;
    1.52 +    private String sys;
    1.53 +    private AnnotationImpl ann;
    1.54 +    protected final NGCCRuntimeEx $runtime;
    1.55 +    private int $_ngcc_current_state;
    1.56 +    protected String $uri;
    1.57 +    protected String $localName;
    1.58 +    protected String $qname;
    1.59 +
    1.60 +    public final NGCCRuntime getRuntime() {
    1.61 +        return($runtime);
    1.62 +    }
    1.63 +
    1.64 +    public notation(NGCCHandler parent, NGCCEventSource source, NGCCRuntimeEx runtime, int cookie) {
    1.65 +        super(source, parent, cookie);
    1.66 +        $runtime = runtime;
    1.67 +        $_ngcc_current_state = 16;
    1.68 +    }
    1.69 +
    1.70 +    public notation(NGCCRuntimeEx runtime) {
    1.71 +        this(null, runtime, runtime, -1);
    1.72 +    }
    1.73 +
    1.74 +    private void action0()throws SAXException {
    1.75 +        loc = $runtime.copyLocator();
    1.76 +}
    1.77 +
    1.78 +    public void enterElement(String $__uri, String $__local, String $__qname, Attributes $attrs) throws SAXException {
    1.79 +        int $ai;
    1.80 +        $uri = $__uri;
    1.81 +        $localName = $__local;
    1.82 +        $qname = $__qname;
    1.83 +        switch($_ngcc_current_state) {
    1.84 +        case 0:
    1.85 +            {
    1.86 +                revertToParentFromEnterElement(makeResult(), super._cookie, $__uri, $__local, $__qname, $attrs);
    1.87 +            }
    1.88 +            break;
    1.89 +        case 15:
    1.90 +            {
    1.91 +                if((($ai = $runtime.getAttributeIndex("","name"))>=0 && ($__uri.equals("http://www.w3.org/2001/XMLSchema") && $__local.equals("annotation")))) {
    1.92 +                    NGCCHandler h = new foreignAttributes(this, super._source, $runtime, 554, null);
    1.93 +                    spawnChildFromEnterElement(h, $__uri, $__local, $__qname, $attrs);
    1.94 +                }
    1.95 +                else {
    1.96 +                    unexpectedEnterElement($__qname);
    1.97 +                }
    1.98 +            }
    1.99 +            break;
   1.100 +        case 2:
   1.101 +            {
   1.102 +                if(($__uri.equals("http://www.w3.org/2001/XMLSchema") && $__local.equals("annotation"))) {
   1.103 +                    NGCCHandler h = new annotation(this, super._source, $runtime, 539, null,AnnotationContext.NOTATION);
   1.104 +                    spawnChildFromEnterElement(h, $__uri, $__local, $__qname, $attrs);
   1.105 +                }
   1.106 +                else {
   1.107 +                    $_ngcc_current_state = 1;
   1.108 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.109 +                }
   1.110 +            }
   1.111 +            break;
   1.112 +        case 4:
   1.113 +            {
   1.114 +                if(($ai = $runtime.getAttributeIndex("","system"))>=0) {
   1.115 +                    $runtime.consumeAttribute($ai);
   1.116 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.117 +                }
   1.118 +                else {
   1.119 +                    $_ngcc_current_state = 2;
   1.120 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.121 +                }
   1.122 +            }
   1.123 +            break;
   1.124 +        case 14:
   1.125 +            {
   1.126 +                if(($ai = $runtime.getAttributeIndex("","name"))>=0) {
   1.127 +                    $runtime.consumeAttribute($ai);
   1.128 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.129 +                }
   1.130 +                else {
   1.131 +                    unexpectedEnterElement($__qname);
   1.132 +                }
   1.133 +            }
   1.134 +            break;
   1.135 +        case 8:
   1.136 +            {
   1.137 +                if(($ai = $runtime.getAttributeIndex("","public"))>=0) {
   1.138 +                    $runtime.consumeAttribute($ai);
   1.139 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.140 +                }
   1.141 +                else {
   1.142 +                    $_ngcc_current_state = 4;
   1.143 +                    $runtime.sendEnterElement(super._cookie, $__uri, $__local, $__qname, $attrs);
   1.144 +                }
   1.145 +            }
   1.146 +            break;
   1.147 +        case 16:
   1.148 +            {
   1.149 +                if(($__uri.equals("http://www.w3.org/2001/XMLSchema") && $__local.equals("notation"))) {
   1.150 +                    $runtime.onEnterElementConsumed($__uri, $__local, $__qname, $attrs);
   1.151 +                    action0();
   1.152 +                    $_ngcc_current_state = 15;
   1.153 +                }
   1.154 +                else {
   1.155 +                    unexpectedEnterElement($__qname);
   1.156 +                }
   1.157 +            }
   1.158 +            break;
   1.159 +        default:
   1.160 +            {
   1.161 +                unexpectedEnterElement($__qname);
   1.162 +            }
   1.163 +            break;
   1.164 +        }
   1.165 +    }
   1.166 +
   1.167 +    public void leaveElement(String $__uri, String $__local, String $__qname) throws SAXException {
   1.168 +        int $ai;
   1.169 +        $uri = $__uri;
   1.170 +        $localName = $__local;
   1.171 +        $qname = $__qname;
   1.172 +        switch($_ngcc_current_state) {
   1.173 +        case 0:
   1.174 +            {
   1.175 +                revertToParentFromLeaveElement(makeResult(), super._cookie, $__uri, $__local, $__qname);
   1.176 +            }
   1.177 +            break;
   1.178 +        case 1:
   1.179 +            {
   1.180 +                if(($__uri.equals("http://www.w3.org/2001/XMLSchema") && $__local.equals("notation"))) {
   1.181 +                    $runtime.onLeaveElementConsumed($__uri, $__local, $__qname);
   1.182 +                    $_ngcc_current_state = 0;
   1.183 +                }
   1.184 +                else {
   1.185 +                    unexpectedLeaveElement($__qname);
   1.186 +                }
   1.187 +            }
   1.188 +            break;
   1.189 +        case 15:
   1.190 +            {
   1.191 +                if((($ai = $runtime.getAttributeIndex("","name"))>=0 && ($__uri.equals("http://www.w3.org/2001/XMLSchema") && $__local.equals("notation")))) {
   1.192 +                    NGCCHandler h = new foreignAttributes(this, super._source, $runtime, 554, null);
   1.193 +                    spawnChildFromLeaveElement(h, $__uri, $__local, $__qname);
   1.194 +                }
   1.195 +                else {
   1.196 +                    unexpectedLeaveElement($__qname);
   1.197 +                }
   1.198 +            }
   1.199 +            break;
   1.200 +        case 2:
   1.201 +            {
   1.202 +                $_ngcc_current_state = 1;
   1.203 +                $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.204 +            }
   1.205 +            break;
   1.206 +        case 4:
   1.207 +            {
   1.208 +                if(($ai = $runtime.getAttributeIndex("","system"))>=0) {
   1.209 +                    $runtime.consumeAttribute($ai);
   1.210 +                    $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.211 +                }
   1.212 +                else {
   1.213 +                    $_ngcc_current_state = 2;
   1.214 +                    $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.215 +                }
   1.216 +            }
   1.217 +            break;
   1.218 +        case 14:
   1.219 +            {
   1.220 +                if(($ai = $runtime.getAttributeIndex("","name"))>=0) {
   1.221 +                    $runtime.consumeAttribute($ai);
   1.222 +                    $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.223 +                }
   1.224 +                else {
   1.225 +                    unexpectedLeaveElement($__qname);
   1.226 +                }
   1.227 +            }
   1.228 +            break;
   1.229 +        case 8:
   1.230 +            {
   1.231 +                if(($ai = $runtime.getAttributeIndex("","public"))>=0) {
   1.232 +                    $runtime.consumeAttribute($ai);
   1.233 +                    $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.234 +                }
   1.235 +                else {
   1.236 +                    $_ngcc_current_state = 4;
   1.237 +                    $runtime.sendLeaveElement(super._cookie, $__uri, $__local, $__qname);
   1.238 +                }
   1.239 +            }
   1.240 +            break;
   1.241 +        default:
   1.242 +            {
   1.243 +                unexpectedLeaveElement($__qname);
   1.244 +            }
   1.245 +            break;
   1.246 +        }
   1.247 +    }
   1.248 +
   1.249 +    public void enterAttribute(String $__uri, String $__local, String $__qname) throws SAXException {
   1.250 +        int $ai;
   1.251 +        $uri = $__uri;
   1.252 +        $localName = $__local;
   1.253 +        $qname = $__qname;
   1.254 +        switch($_ngcc_current_state) {
   1.255 +        case 0:
   1.256 +            {
   1.257 +                revertToParentFromEnterAttribute(makeResult(), super._cookie, $__uri, $__local, $__qname);
   1.258 +            }
   1.259 +            break;
   1.260 +        case 15:
   1.261 +            {
   1.262 +                if(($__uri.equals("") && $__local.equals("name"))) {
   1.263 +                    NGCCHandler h = new foreignAttributes(this, super._source, $runtime, 554, null);
   1.264 +                    spawnChildFromEnterAttribute(h, $__uri, $__local, $__qname);
   1.265 +                }
   1.266 +                else {
   1.267 +                    unexpectedEnterAttribute($__qname);
   1.268 +                }
   1.269 +            }
   1.270 +            break;
   1.271 +        case 2:
   1.272 +            {
   1.273 +                $_ngcc_current_state = 1;
   1.274 +                $runtime.sendEnterAttribute(super._cookie, $__uri, $__local, $__qname);
   1.275 +            }
   1.276 +            break;
   1.277 +        case 4:
   1.278 +            {
   1.279 +                if(($__uri.equals("") && $__local.equals("system"))) {
   1.280 +                    $_ngcc_current_state = 6;
   1.281 +                }
   1.282 +                else {
   1.283 +                    $_ngcc_current_state = 2;
   1.284 +                    $runtime.sendEnterAttribute(super._cookie, $__uri, $__local, $__qname);
   1.285 +                }
   1.286 +            }
   1.287 +            break;
   1.288 +        case 14:
   1.289 +            {
   1.290 +                if(($__uri.equals("") && $__local.equals("name"))) {
   1.291 +                    $_ngcc_current_state = 13;
   1.292 +                }
   1.293 +                else {
   1.294 +                    unexpectedEnterAttribute($__qname);
   1.295 +                }
   1.296 +            }
   1.297 +            break;
   1.298 +        case 8:
   1.299 +            {
   1.300 +                if(($__uri.equals("") && $__local.equals("public"))) {
   1.301 +                    $_ngcc_current_state = 10;
   1.302 +                }
   1.303 +                else {
   1.304 +                    $_ngcc_current_state = 4;
   1.305 +                    $runtime.sendEnterAttribute(super._cookie, $__uri, $__local, $__qname);
   1.306 +                }
   1.307 +            }
   1.308 +            break;
   1.309 +        default:
   1.310 +            {
   1.311 +                unexpectedEnterAttribute($__qname);
   1.312 +            }
   1.313 +            break;
   1.314 +        }
   1.315 +    }
   1.316 +
   1.317 +    public void leaveAttribute(String $__uri, String $__local, String $__qname) throws SAXException {
   1.318 +        int $ai;
   1.319 +        $uri = $__uri;
   1.320 +        $localName = $__local;
   1.321 +        $qname = $__qname;
   1.322 +        switch($_ngcc_current_state) {
   1.323 +        case 0:
   1.324 +            {
   1.325 +                revertToParentFromLeaveAttribute(makeResult(), super._cookie, $__uri, $__local, $__qname);
   1.326 +            }
   1.327 +            break;
   1.328 +        case 2:
   1.329 +            {
   1.330 +                $_ngcc_current_state = 1;
   1.331 +                $runtime.sendLeaveAttribute(super._cookie, $__uri, $__local, $__qname);
   1.332 +            }
   1.333 +            break;
   1.334 +        case 4:
   1.335 +            {
   1.336 +                $_ngcc_current_state = 2;
   1.337 +                $runtime.sendLeaveAttribute(super._cookie, $__uri, $__local, $__qname);
   1.338 +            }
   1.339 +            break;
   1.340 +        case 5:
   1.341 +            {
   1.342 +                if(($__uri.equals("") && $__local.equals("system"))) {
   1.343 +                    $_ngcc_current_state = 2;
   1.344 +                }
   1.345 +                else {
   1.346 +                    unexpectedLeaveAttribute($__qname);
   1.347 +                }
   1.348 +            }
   1.349 +            break;
   1.350 +        case 8:
   1.351 +            {
   1.352 +                $_ngcc_current_state = 4;
   1.353 +                $runtime.sendLeaveAttribute(super._cookie, $__uri, $__local, $__qname);
   1.354 +            }
   1.355 +            break;
   1.356 +        case 9:
   1.357 +            {
   1.358 +                if(($__uri.equals("") && $__local.equals("public"))) {
   1.359 +                    $_ngcc_current_state = 4;
   1.360 +                }
   1.361 +                else {
   1.362 +                    unexpectedLeaveAttribute($__qname);
   1.363 +                }
   1.364 +            }
   1.365 +            break;
   1.366 +        case 12:
   1.367 +            {
   1.368 +                if(($__uri.equals("") && $__local.equals("name"))) {
   1.369 +                    $_ngcc_current_state = 8;
   1.370 +                }
   1.371 +                else {
   1.372 +                    unexpectedLeaveAttribute($__qname);
   1.373 +                }
   1.374 +            }
   1.375 +            break;
   1.376 +        default:
   1.377 +            {
   1.378 +                unexpectedLeaveAttribute($__qname);
   1.379 +            }
   1.380 +            break;
   1.381 +        }
   1.382 +    }
   1.383 +
   1.384 +    public void text(String $value) throws SAXException {
   1.385 +        int $ai;
   1.386 +        switch($_ngcc_current_state) {
   1.387 +        case 0:
   1.388 +            {
   1.389 +                revertToParentFromText(makeResult(), super._cookie, $value);
   1.390 +            }
   1.391 +            break;
   1.392 +        case 10:
   1.393 +            {
   1.394 +                pub = $value;
   1.395 +                $_ngcc_current_state = 9;
   1.396 +            }
   1.397 +            break;
   1.398 +        case 15:
   1.399 +            {
   1.400 +                if(($ai = $runtime.getAttributeIndex("","name"))>=0) {
   1.401 +                    NGCCHandler h = new foreignAttributes(this, super._source, $runtime, 554, null);
   1.402 +                    spawnChildFromText(h, $value);
   1.403 +                }
   1.404 +            }
   1.405 +            break;
   1.406 +        case 2:
   1.407 +            {
   1.408 +                $_ngcc_current_state = 1;
   1.409 +                $runtime.sendText(super._cookie, $value);
   1.410 +            }
   1.411 +            break;
   1.412 +        case 13:
   1.413 +            {
   1.414 +                name = $value;
   1.415 +                $_ngcc_current_state = 12;
   1.416 +            }
   1.417 +            break;
   1.418 +        case 4:
   1.419 +            {
   1.420 +                if(($ai = $runtime.getAttributeIndex("","system"))>=0) {
   1.421 +                    $runtime.consumeAttribute($ai);
   1.422 +                    $runtime.sendText(super._cookie, $value);
   1.423 +                }
   1.424 +                else {
   1.425 +                    $_ngcc_current_state = 2;
   1.426 +                    $runtime.sendText(super._cookie, $value);
   1.427 +                }
   1.428 +            }
   1.429 +            break;
   1.430 +        case 6:
   1.431 +            {
   1.432 +                sys = $value;
   1.433 +                $_ngcc_current_state = 5;
   1.434 +            }
   1.435 +            break;
   1.436 +        case 14:
   1.437 +            {
   1.438 +                if(($ai = $runtime.getAttributeIndex("","name"))>=0) {
   1.439 +                    $runtime.consumeAttribute($ai);
   1.440 +                    $runtime.sendText(super._cookie, $value);
   1.441 +                }
   1.442 +            }
   1.443 +            break;
   1.444 +        case 8:
   1.445 +            {
   1.446 +                if(($ai = $runtime.getAttributeIndex("","public"))>=0) {
   1.447 +                    $runtime.consumeAttribute($ai);
   1.448 +                    $runtime.sendText(super._cookie, $value);
   1.449 +                }
   1.450 +                else {
   1.451 +                    $_ngcc_current_state = 4;
   1.452 +                    $runtime.sendText(super._cookie, $value);
   1.453 +                }
   1.454 +            }
   1.455 +            break;
   1.456 +        }
   1.457 +    }
   1.458 +
   1.459 +    public void onChildCompleted(Object $__result__, int $__cookie__, boolean $__needAttCheck__)throws SAXException {
   1.460 +        switch($__cookie__) {
   1.461 +        case 554:
   1.462 +            {
   1.463 +                fa = ((ForeignAttributesImpl)$__result__);
   1.464 +                $_ngcc_current_state = 14;
   1.465 +            }
   1.466 +            break;
   1.467 +        case 539:
   1.468 +            {
   1.469 +                ann = ((AnnotationImpl)$__result__);
   1.470 +                $_ngcc_current_state = 1;
   1.471 +            }
   1.472 +            break;
   1.473 +        }
   1.474 +    }
   1.475 +
   1.476 +    public boolean accepted() {
   1.477 +        return(($_ngcc_current_state == 0));
   1.478 +    }
   1.479 +
   1.480 +
   1.481 +      private Locator loc;
   1.482 +      private XSNotation makeResult() {
   1.483 +        return new NotationImpl( $runtime.document,ann,loc,fa,name,pub,sys);
   1.484 +      }
   1.485 +
   1.486 +}

mercurial