< prev index next >

src/java.xml/share/classes/com/sun/org/apache/xalan/internal/xsltc/compiler/VariableBase.java

Print this page


   1 /*
   2  * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
   3  * @LastModified: Oct 2017
   4  */
   5 /*
   6  * Licensed to the Apache Software Foundation (ASF) under one or more
   7  * contributor license agreements.  See the NOTICE file distributed with
   8  * this work for additional information regarding copyright ownership.
   9  * The ASF licenses this file to You under the Apache License, Version 2.0
  10  * (the "License"); you may not use this file except in compliance with
  11  * the License.  You may obtain a copy of the License at
  12  *
  13  *      http://www.apache.org/licenses/LICENSE-2.0
  14  *
  15  * Unless required by applicable law or agreed to in writing, software
  16  * distributed under the License is distributed on an "AS IS" BASIS,
  17  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  18  * See the License for the specific language governing permissions and
  19  * limitations under the License.
  20  */
  21 
  22 package com.sun.org.apache.xalan.internal.xsltc.compiler;
  23 


  31 import com.sun.org.apache.bcel.internal.generic.LocalVariableGen;
  32 import com.sun.org.apache.bcel.internal.generic.NEW;
  33 import com.sun.org.apache.bcel.internal.generic.PUSH;
  34 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ClassGenerator;
  35 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMsg;
  36 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.MethodGenerator;
  37 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.NodeSetType;
  38 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ResultTreeType;
  39 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type;
  40 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Util;
  41 import com.sun.org.apache.xml.internal.utils.XML11Char;
  42 import java.util.ArrayList;
  43 import java.util.List;
  44 
  45 /**
  46  * @author Jacek Ambroziak
  47  * @author Santiago Pericas-Geertsen
  48  * @author Morten Jorgensen
  49  * @author Erwin Bolwidt <ejb@klomp.org>
  50  * @author John Howard <JohnH@schemasoft.com>

  51  */
  52 class VariableBase extends TopLevelElement {
  53 
  54     protected QName       _name;             // The name of the variable.
  55     protected String      _escapedName;      // The escaped qname of the variable.
  56     protected Type        _type;             // The type of this variable.
  57     protected boolean     _isLocal;          // True if the variable is local.
  58     protected LocalVariableGen _local;       // Reference to JVM variable
  59     protected Instruction _loadInstruction;  // Instruction to load JVM variable
  60     protected Instruction _storeInstruction; // Instruction to load JVM variable
  61     protected Expression  _select;           // Reference to variable expression
  62     protected String      select;            // Textual repr. of variable expr.
  63 
  64     // References to this variable (when local)
  65     protected List<VariableRefBase> _refs = new ArrayList<>(2);
  66 
  67     // Used to make sure parameter field is not added twice
  68     protected boolean    _ignore = false;
  69 
  70     /**


   1 /*
   2  * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.

   3  */
   4 /*
   5  * Licensed to the Apache Software Foundation (ASF) under one or more
   6  * contributor license agreements.  See the NOTICE file distributed with
   7  * this work for additional information regarding copyright ownership.
   8  * The ASF licenses this file to You under the Apache License, Version 2.0
   9  * (the "License"); you may not use this file except in compliance with
  10  * the License.  You may obtain a copy of the License at
  11  *
  12  *      http://www.apache.org/licenses/LICENSE-2.0
  13  *
  14  * Unless required by applicable law or agreed to in writing, software
  15  * distributed under the License is distributed on an "AS IS" BASIS,
  16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  17  * See the License for the specific language governing permissions and
  18  * limitations under the License.
  19  */
  20 
  21 package com.sun.org.apache.xalan.internal.xsltc.compiler;
  22 


  30 import com.sun.org.apache.bcel.internal.generic.LocalVariableGen;
  31 import com.sun.org.apache.bcel.internal.generic.NEW;
  32 import com.sun.org.apache.bcel.internal.generic.PUSH;
  33 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ClassGenerator;
  34 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMsg;
  35 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.MethodGenerator;
  36 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.NodeSetType;
  37 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.ResultTreeType;
  38 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Type;
  39 import com.sun.org.apache.xalan.internal.xsltc.compiler.util.Util;
  40 import com.sun.org.apache.xml.internal.utils.XML11Char;
  41 import java.util.ArrayList;
  42 import java.util.List;
  43 
  44 /**
  45  * @author Jacek Ambroziak
  46  * @author Santiago Pericas-Geertsen
  47  * @author Morten Jorgensen
  48  * @author Erwin Bolwidt <ejb@klomp.org>
  49  * @author John Howard <JohnH@schemasoft.com>
  50  * @LastModified: Oct 2017
  51  */
  52 class VariableBase extends TopLevelElement {
  53 
  54     protected QName       _name;             // The name of the variable.
  55     protected String      _escapedName;      // The escaped qname of the variable.
  56     protected Type        _type;             // The type of this variable.
  57     protected boolean     _isLocal;          // True if the variable is local.
  58     protected LocalVariableGen _local;       // Reference to JVM variable
  59     protected Instruction _loadInstruction;  // Instruction to load JVM variable
  60     protected Instruction _storeInstruction; // Instruction to load JVM variable
  61     protected Expression  _select;           // Reference to variable expression
  62     protected String      select;            // Textual repr. of variable expr.
  63 
  64     // References to this variable (when local)
  65     protected List<VariableRefBase> _refs = new ArrayList<>(2);
  66 
  67     // Used to make sure parameter field is not added twice
  68     protected boolean    _ignore = false;
  69 
  70     /**


< prev index next >