1 /*
2 * reserved comment block
3 * DO NOT REMOVE OR ALTER!
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.xpath.internal.compiler;
23
429 case 0 :
430 index = OpCodes.EMPTY;
431 break;
432 case 1 :
433 index = OpCodes.ELEMWILDCARD;
434 break;
435 case 2 :
436 index = m_opMap.elementAt(opPosOfStep + 4);
437 break;
438 case 3 :
439 index = m_opMap.elementAt(opPosOfStep + 5);
440 break;
441 default :
442 index = OpCodes.EMPTY;
443 break; // Should assert error
444 }
445
446 // int index = (argLenOfStep == 3) ? m_opMap[opPosOfStep+5]
447 // : ((argLenOfStep == 1) ? -3 : -2);
448 if (index >= 0)
449 return (String) m_tokenQueue.elementAt(index).toString();
450 else if (OpCodes.ELEMWILDCARD == index)
451 return NodeTest.WILD;
452 else
453 return null;
454 }
455
456 }
|
1 /*
2 * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
3 * @LastModified: Nov 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.xpath.internal.compiler;
23
429 case 0 :
430 index = OpCodes.EMPTY;
431 break;
432 case 1 :
433 index = OpCodes.ELEMWILDCARD;
434 break;
435 case 2 :
436 index = m_opMap.elementAt(opPosOfStep + 4);
437 break;
438 case 3 :
439 index = m_opMap.elementAt(opPosOfStep + 5);
440 break;
441 default :
442 index = OpCodes.EMPTY;
443 break; // Should assert error
444 }
445
446 // int index = (argLenOfStep == 3) ? m_opMap[opPosOfStep+5]
447 // : ((argLenOfStep == 1) ? -3 : -2);
448 if (index >= 0)
449 return m_tokenQueue.elementAt(index).toString();
450 else if (OpCodes.ELEMWILDCARD == index)
451 return NodeTest.WILD;
452 else
453 return null;
454 }
455
456 }
|