+++ /dev/null
-package org.aspectj.apache.bcel.classfile;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Unknown (non-standard) attributes may be read via user-defined factory
- * objects that can be registered with the Attribute.addAttributeReader
- * method. These factory objects should implement this interface.
-
- * @see Attribute
- * @version $Id: AttributeReader.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface AttributeReader {
- /**
- When this attribute reader is added via the static method
- Attribute.addAttributeReader, an attribute name is associated with it.
- As the class file parser parses attributes, it will call various
- AttributeReaders based on the name of the attributes it is
- constructing.
-
- @param name_index An index into the constant pool, indexing a
- ConstantUtf8 that represents the name of the attribute.
-
- @param length The length of the data contained in the attribute. This
- is written into the constant pool and should agree with what the
- factory expects the length to be.
-
- @param file This is the data input stream that the factory needs to read
- its data from.
-
- @param constant_pool This is the constant pool associated with the
- Attribute that we are constructing.
-
- @return The user-defined AttributeReader should take this data and use
- it to construct an attribute. In the case of errors, a null can be
- returned which will cause the parsing of the class file to fail.
-
- @see Attribute#addAttributeReader( String, AttributeReader )
- */
- public Attribute createAttribute(int name_index,
- int length,
- java.io.DataInputStream file,
- ConstantPool constant_pool);
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM Corporation
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
- * ******************************************************************/
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * An annotation is an immutable object (AnnotationGen is the mutable variant) - it basically contains a list
- * of name-value pairs.
- */
-public class Annotation {
- private int typeIndex;
- private List /* ElementNameValuePair */ evs = new ArrayList();
- private ConstantPool cpool;
- private boolean isRuntimeVisible;
-
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append("ANNOTATION ["+getTypeSignature()+"] ["+
- (isRuntimeVisible?"runtimeVisible":"runtimeInvisible")+"] [");
- for (Iterator iter = evs.iterator(); iter.hasNext();) {
- ElementNameValuePair element = (ElementNameValuePair) iter.next();
- sb.append(element.toString());
- if (iter.hasNext()) sb.append(",");
- }
- sb.append("]");
- return sb.toString();
- }
-
- private Annotation(ConstantPool cpool) {
- this.cpool = cpool;
- }
-
- public Annotation(int index,ConstantPool cpool,boolean visible) {
- this.cpool = cpool;
- this.typeIndex = index;
- this.isRuntimeVisible = visible;
- }
-
- protected static Annotation read(DataInputStream dis,ConstantPool cpool,boolean isRuntimeVisible) throws IOException {
- Annotation a = new Annotation(cpool);
- a.typeIndex = dis.readUnsignedShort();
- int elemValuePairCount = dis.readUnsignedShort();
- for (int i=0;i<elemValuePairCount;i++) {
- int nidx = dis.readUnsignedShort();
- a.addElementNameValuePair(
- new ElementNameValuePair(nidx,ElementValue.readElementValue(dis,cpool),cpool));
- }
- a.isRuntimeVisible(isRuntimeVisible);
- return a;
- }
-
- protected void dump(DataOutputStream dos) throws IOException {
- dos.writeShort(typeIndex); // u2 index of type name in cpool
- dos.writeShort(evs.size()); // u2 element_value pair count
- for (int i = 0 ; i<evs.size();i++) {
- ElementNameValuePair envp = (ElementNameValuePair) evs.get(i);
- envp.dump(dos);
- }
- }
-
- public void addElementNameValuePair(ElementNameValuePair evp) {
- evs.add(evp);
- }
-
-
- public int getTypeIndex() {
- return typeIndex;
- }
-
- public String getTypeSignature() {
- ConstantUtf8 c = (ConstantUtf8)cpool.getConstant(typeIndex,Constants.CONSTANT_Utf8);
- return c.getBytes();
- }
-
- public String getTypeName() {
- ConstantUtf8 c = (ConstantUtf8)cpool.getConstant(typeIndex,Constants.CONSTANT_Utf8);
- return Utility.signatureToString(c.getBytes());
- }
-
- /**
- * Returns list of ElementNameValuePair objects
- */
- public List getValues() {
- return evs;
- }
-
- protected void isRuntimeVisible(boolean b) {
- isRuntimeVisible = b;
- }
-
- public boolean isRuntimeVisible() {
- return isRuntimeVisible;
- }
-
- public String toShortString() {
- StringBuffer result = new StringBuffer();
- result.append("@");
- result.append(getTypeName());
- if (getValues().size()>0) {
- result.append("(");
- for (Iterator iter = getValues().iterator(); iter.hasNext();) {
- ElementNameValuePair element = (ElementNameValuePair) iter.next();
- result.append(element.toShortString());
- }
- result.append(")");
- }
- return result.toString();
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-
-/**
- * An element value that is an annotation.
- */
-public class AnnotationElementValue extends ElementValue {
-
- // For annotation element values, this is the annotation
- private Annotation a;
-
- public AnnotationElementValue(int type, Annotation annotation, ConstantPool cpool) {
- super(type,cpool);
- if (type != ANNOTATION)
- throw new RuntimeException("Only element values of type annotation can be built with this ctor");
- this.a = annotation;
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ANNOTATION == '@')
- a.dump(dos);
- }
-
- public String stringifyValue() {
- StringBuffer sb = new StringBuffer();
- sb.append(a.toString());
- return sb.toString();
- }
-
- public String toString() {
- return stringifyValue();
- }
-
- public Annotation getAnnotation() { return a;}
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-
-
-public class ArrayElementValue extends ElementValue {
-
- // For array types, this is the array
- private ElementValue[] evalues;
-
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append("{");
- for (int i = 0; i < evalues.length; i++) {
- sb.append(evalues[i].toString());
- if ((i+1)<evalues.length) sb.append(",");
- }
- sb.append("}");
- return sb.toString();
- }
-
- public ArrayElementValue(int type, ElementValue[] datums, ConstantPool cpool) {
- super(type,cpool);
- if (type != ARRAY)
- throw new RuntimeException("Only element values of type array can be built with this ctor");
- this.evalues = datums;
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ARRAY == '[')
- dos.writeShort(evalues.length);
- for (int i=0; i<evalues.length; i++) {
- evalues[i].dump(dos);
- }
- }
-
- public String stringifyValue() {
- StringBuffer sb = new StringBuffer();
- sb.append("[");
- for(int i=0; i<evalues.length; i++) {
- sb.append(evalues[i].stringifyValue());
- if ((i+1)<evalues.length) sb.append(",");
- }
- sb.append("]");
- return sb.toString();
- }
-
- public ElementValue[] getElementValuesArray() { return evalues;}
- public int getElementValuesArraySize() { return evalues.length;}
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-
-
-public class ClassElementValue extends ElementValue {
-
- // For primitive types and string type, this points to the value entry in the cpool
- // For 'class' this points to the class entry in the cpool
- private int idx;
-
- public ClassElementValue(int type,int idx,ConstantPool cpool) {
- super(type,cpool);
- this.idx = idx;
- }
-
- public int getIndex() {
- return idx;
- }
-
- public String getClassString() {
- ConstantUtf8 c = (ConstantUtf8)cpool.getConstant(idx,Constants.CONSTANT_Utf8);
- return c.getBytes();
- }
-
- public String stringifyValue() {
- ConstantUtf8 cu8 = (ConstantUtf8)cpool.getConstant(idx,Constants.CONSTANT_Utf8);
- return cu8.getBytes();
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 kind of value
- dos.writeShort(idx);
- }
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-
-
-public class ElementNameValuePair {
- private int nameIdx;
- private ElementValue value;
- private ConstantPool cpool;
-
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append(getNameString()+"="+value.toString());
- return sb.toString();
- }
- public ElementNameValuePair(int idx,ElementValue value,ConstantPool cpool) {
- this.nameIdx = idx;
- this.value = value;
- this.cpool = cpool;
- }
-
- protected void dump(DataOutputStream dos) throws IOException {
- dos.writeShort(nameIdx); // u2 name of the element
- value.dump(dos);
- }
-
- public int getNameIndex() {
- return nameIdx;
- }
-
- public final String getNameString() {
- ConstantUtf8 c = (ConstantUtf8)cpool.getConstant(nameIdx,Constants.CONSTANT_Utf8);
- return c.getBytes();
- }
-
- public final ElementValue getValue() {
- return value;
- }
-
- public String toShortString() {
- StringBuffer result = new StringBuffer();
- result.append(getNameString()).append("=").append(getValue().toShortString());
- return result.toString();
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-
-public abstract class ElementValue {
-
- protected int type;
- protected ConstantPool cpool;
-
- public String toString() {
- return stringifyValue();
- }
-
- protected ElementValue(int type,ConstantPool cpool) {
- this.type = type;
- this.cpool = cpool;
- }
-
- public int getElementValueType() {
- return type;
- }
-
- public abstract String stringifyValue();
- public abstract void dump(DataOutputStream dos) throws IOException;
-
- public static final int STRING = 's';
- public static final int ENUM_CONSTANT = 'e';
- public static final int CLASS = 'c';
- public static final int ANNOTATION = '@';
- public static final int ARRAY = '[';
-
- public static final int PRIMITIVE_INT = 'I';
- public static final int PRIMITIVE_BYTE = 'B';
- public static final int PRIMITIVE_CHAR = 'C';
- public static final int PRIMITIVE_DOUBLE = 'D';
- public static final int PRIMITIVE_FLOAT = 'F';
- public static final int PRIMITIVE_LONG = 'J';
- public static final int PRIMITIVE_SHORT = 'S';
- public static final int PRIMITIVE_BOOLEAN= 'Z';
-
- public static ElementValue readElementValue(DataInputStream dis,ConstantPool cpool) throws IOException {
- int type= dis.readUnsignedByte();
- switch (type) {
- case 'B': // byte
- return new SimpleElementValue(PRIMITIVE_BYTE,dis.readUnsignedShort(),cpool);
- case 'C': // char
- return new SimpleElementValue(PRIMITIVE_CHAR,dis.readUnsignedShort(),cpool);
- case 'D': // double
- return new SimpleElementValue(PRIMITIVE_DOUBLE,dis.readUnsignedShort(),cpool);
- case 'F': // float
- return new SimpleElementValue(PRIMITIVE_FLOAT,dis.readUnsignedShort(),cpool);
- case 'I': // int
- return new SimpleElementValue(PRIMITIVE_INT,dis.readUnsignedShort(),cpool);
- case 'J': // long
- return new SimpleElementValue(PRIMITIVE_LONG,dis.readUnsignedShort(),cpool);
- case 'S': // short
- return new SimpleElementValue(PRIMITIVE_SHORT,dis.readUnsignedShort(),cpool);
- case 'Z': // boolean
- return new SimpleElementValue(PRIMITIVE_BOOLEAN,dis.readUnsignedShort(),cpool);
- case 's': // String
- return new SimpleElementValue(STRING,dis.readUnsignedShort(),cpool);
-
- case 'e': // Enum constant
- return new EnumElementValue(ENUM_CONSTANT,dis.readUnsignedShort(),dis.readUnsignedShort(),cpool);
-
- case 'c': // Class
- return new ClassElementValue(CLASS,dis.readUnsignedShort(),cpool);
-
- //J5TODO: Should it be 'true' in the next statement? What difference does it make? Should it be
- // the same as the 'super annotation' in which we are contained?
- case '@': // Annotation
- return new AnnotationElementValue(ANNOTATION,Annotation.read(dis,cpool,true),cpool);
-
- case '[': // Array
- int numArrayVals = dis.readUnsignedShort();
- List arrayVals = new ArrayList();
- ElementValue[] evalues = new ElementValue[numArrayVals];
- for (int j=0;j<numArrayVals;j++) {
- evalues[j] = ElementValue.readElementValue(dis,cpool);
- }
- return new ArrayElementValue(ARRAY,evalues,cpool);
-
- default:
- throw new RuntimeException("Unexpected element value kind in annotation: "+type);
- }
- }
-
-
- public String toShortString() {
- StringBuffer result = new StringBuffer();
- result.append(stringifyValue());
- return result.toString();
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-
-
-public class EnumElementValue extends ElementValue {
-
- // For enum types, these two indices point to the type and value
- private int typeIdx;
- private int valueIdx;
-
- public EnumElementValue(int type,int typeIdx,int valueIdx,ConstantPool cpool) {
- super(type,cpool);
- if (type != ENUM_CONSTANT)
- throw new RuntimeException("Only element values of type enum can be built with this ctor");
- this.typeIdx = typeIdx;
- this.valueIdx= valueIdx;
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ENUM_CONSTANT == 'e')
- dos.writeShort(typeIdx); // u2
- dos.writeShort(valueIdx); // u2
- }
-
- public String stringifyValue() {
- ConstantUtf8 cu8 = (ConstantUtf8)cpool.getConstant(valueIdx,Constants.CONSTANT_Utf8);
- return cu8.getBytes();
- }
-
- public String getEnumTypeString() {
- ConstantUtf8 cu8 = (ConstantUtf8)cpool.getConstant(typeIdx,Constants.CONSTANT_Utf8);
- return cu8.getBytes();//Utility.signatureToString(cu8.getBytes());
- }
-
- public String getEnumValueString() {
- ConstantUtf8 cu8 = (ConstantUtf8)cpool.getConstant(valueIdx,Constants.CONSTANT_Utf8);
- return cu8.getBytes();
- }
-
- public int getValueIndex() { return valueIdx;}
- public int getTypeIndex() { return typeIdx; }
-
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.classfile.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ConstantDouble;
-import org.aspectj.apache.bcel.classfile.ConstantFloat;
-import org.aspectj.apache.bcel.classfile.ConstantInteger;
-import org.aspectj.apache.bcel.classfile.ConstantLong;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-
-/**
- * An element value representing a primitive or string value.
- */
-public class SimpleElementValue extends ElementValue {
-
- // For primitive types and string type, this points to the value entry in the cpool
- // For 'class' this points to the class entry in the cpool
- private int idx;
-
- public SimpleElementValue(int type,int idx,ConstantPool cpool) {
- super(type,cpool);
- this.idx = idx;
- }
-
- public int getIndex() {
- return idx;
- }
-
-
- public String getValueString() {
- if (type != STRING)
- throw new RuntimeException("Dont call getValueString() on a non STRING ElementValue");
- ConstantUtf8 c = (ConstantUtf8)cpool.getConstant(idx,Constants.CONSTANT_Utf8);
- return c.getBytes();
- }
-
- public int getValueInt() {
- if (type != PRIMITIVE_INT)
- throw new RuntimeException("Dont call getValueString() on a non STRING ElementValue");
- ConstantInteger c = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return c.getBytes();
- }
-
- public byte getValueByte() {
- if (type != PRIMITIVE_BYTE)
- throw new RuntimeException("Dont call getValueByte() on a non BYTE ElementValue");
- ConstantInteger c = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return (byte)c.getBytes();
- }
-
- public char getValueChar() {
- if (type != PRIMITIVE_CHAR)
- throw new RuntimeException("Dont call getValueChar() on a non CHAR ElementValue");
- ConstantInteger c = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return (char)c.getBytes();
- }
-
- public long getValueLong() {
- if (type != PRIMITIVE_LONG)
- throw new RuntimeException("Dont call getValueLong() on a non LONG ElementValue");
- ConstantLong j = (ConstantLong)cpool.getConstant(idx);
- return j.getBytes();
- }
-
- public float getValueFloat() {
- if (type != PRIMITIVE_FLOAT)
- throw new RuntimeException("Dont call getValueFloat() on a non FLOAT ElementValue");
- ConstantFloat f = (ConstantFloat)cpool.getConstant(idx);
- return f.getBytes();
- }
-
-
- public double getValueDouble() {
- if (type != PRIMITIVE_DOUBLE)
- throw new RuntimeException("Dont call getValueDouble() on a non DOUBLE ElementValue");
- ConstantDouble d = (ConstantDouble)cpool.getConstant(idx);
- return d.getBytes();
- }
-
- public boolean getValueBoolean() {
- if (type != PRIMITIVE_BOOLEAN)
- throw new RuntimeException("Dont call getValueBoolean() on a non BOOLEAN ElementValue");
- ConstantInteger bo = (ConstantInteger)cpool.getConstant(idx);
- return (bo.getBytes()!=0);
- }
-
- public short getValueShort() {
- if (type != PRIMITIVE_SHORT)
- throw new RuntimeException("Dont call getValueShort() on a non SHORT ElementValue");
- ConstantInteger s = (ConstantInteger)cpool.getConstant(idx);
- return (short)s.getBytes();
- }
-
- public String toString() {
- return stringifyValue();
- }
-
- // Whatever kind of value it is, return it as a string
- public String stringifyValue() {
- switch (type) {
- case PRIMITIVE_INT:
- ConstantInteger c = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return Integer.toString(c.getBytes());
- case PRIMITIVE_LONG:
- ConstantLong j = (ConstantLong)cpool.getConstant(idx,Constants.CONSTANT_Long);
- return Long.toString(j.getBytes());
- case PRIMITIVE_DOUBLE:
- ConstantDouble d = (ConstantDouble)cpool.getConstant(idx,Constants.CONSTANT_Double);
- return Double.toString(d.getBytes());
- case PRIMITIVE_FLOAT:
- ConstantFloat f = (ConstantFloat)cpool.getConstant(idx,Constants.CONSTANT_Float);
- return Float.toString(f.getBytes());
- case PRIMITIVE_SHORT:
- ConstantInteger s = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return Integer.toString(s.getBytes());
- case PRIMITIVE_BYTE:
- ConstantInteger b = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return Integer.toString(b.getBytes());
- case PRIMITIVE_CHAR:
- ConstantInteger ch = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- return new Character((char)ch.getBytes()).toString();
- case PRIMITIVE_BOOLEAN:
- ConstantInteger bo = (ConstantInteger)cpool.getConstant(idx,Constants.CONSTANT_Integer);
- if (bo.getBytes() == 0) return "false";
- if (bo.getBytes() != 0) return "true";
- case STRING:
- ConstantUtf8 cu8 = (ConstantUtf8)cpool.getConstant(idx,Constants.CONSTANT_Utf8);
- return cu8.getBytes();
-
- default:
- throw new RuntimeException("SimpleElementValue class does not know how to stringify type "+type);
- }
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 kind of value
- switch (type) {
- case PRIMITIVE_INT:
- case PRIMITIVE_BYTE:
- case PRIMITIVE_CHAR:
- case PRIMITIVE_FLOAT:
- case PRIMITIVE_LONG:
- case PRIMITIVE_BOOLEAN:
- case PRIMITIVE_SHORT:
- case PRIMITIVE_DOUBLE:
- case STRING:
- dos.writeShort(idx);
- break;
- default:
- throw new RuntimeException("SimpleElementValue doesnt know how to write out type "+type);
- }
- }
-
-}
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:18 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-<p>
-This package contains the classes that describe the structure of a
-Java class file and a class file parser.
-</p>
-</body>
-</html>
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * AALOAD - Load reference from array
- * <PRE>Stack: ..., arrayref, index -> value</PRE>
- *
- * @version $Id: AALOAD.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class AALOAD extends ArrayInstruction implements StackProducer {
- /** Load reference from array
- */
- public AALOAD() {
- super(org.aspectj.apache.bcel.Constants.AALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitAALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * AASTORE - Store into reference array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: AASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class AASTORE extends ArrayInstruction implements StackConsumer {
- /** Store into reference array
- */
- public AASTORE() {
- super(org.aspectj.apache.bcel.Constants.AASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitAASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ACONST_NULL - Push null reference
- * <PRE>Stack: ... -> ..., null</PRE>
- *
- * @version $Id: ACONST_NULL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ACONST_NULL extends Instruction
- implements PushInstruction, TypedInstruction {
- /**
- * Push null reference
- */
- public ACONST_NULL() {
- super(org.aspectj.apache.bcel.Constants.ACONST_NULL, (short)1);
- }
-
- /** @return Type.NULL
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.NULL;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitTypedInstruction(this);
- v.visitACONST_NULL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ALOAD - Load reference from local variable
- * <PRE>Stack: ... -> ..., objectref</PRE>
- *
- * @version $Id: ALOAD.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ALOAD extends LoadInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ALOAD() {
- super(org.aspectj.apache.bcel.Constants.ALOAD, org.aspectj.apache.bcel.Constants.ALOAD_0);
- }
-
- /** Load reference from local variable
- * @param n index of local variable
- */
- public ALOAD(int n) {
- super(org.aspectj.apache.bcel.Constants.ALOAD, org.aspectj.apache.bcel.Constants.ALOAD_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * ANEWARRAY - Create new array of references
- * <PRE>Stack: ..., count -> ..., arrayref</PRE>
- *
- * @version $Id: ANEWARRAY.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ANEWARRAY extends CPInstruction
- implements LoadClass, AllocationInstruction, ExceptionThrower, StackProducer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ANEWARRAY() {}
-
- public ANEWARRAY(int index) {
- super(org.aspectj.apache.bcel.Constants.ANEWARRAY, index);
- }
-
- public Class[] getExceptions(){
- Class[] cs = new Class[1 + ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length);
- cs[ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length] =
- ExceptionConstants.NEGATIVE_ARRAY_SIZE_EXCEPTION;
- return cs;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitLoadClass(this);
- v.visitAllocationInstruction(this);
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitANEWARRAY(this);
- }
-
- public ObjectType getLoadClassType(ConstantPoolGen cpg) {
- Type t = getType(cpg);
-
- if (t instanceof ArrayType){
- t = ((ArrayType) t).getBasicType();
- }
-
- return (t instanceof ObjectType)? (ObjectType) t : null;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ARETURN - Return reference from method
- * <PRE>Stack: ..., objectref -> <empty></PRE>
- *
- * @version $Id: ARETURN.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ARETURN extends ReturnInstruction {
- /**
- * Return reference from method
- */
- public ARETURN() {
- super(org.aspectj.apache.bcel.Constants.ARETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitARETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ARRAYLENGTH - Get length of array
- * <PRE>Stack: ..., arrayref -> ..., length</PRE>
- *
- * @version $Id: ARRAYLENGTH.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ARRAYLENGTH extends Instruction
- implements ExceptionThrower, StackProducer {
- /** Get length of array
- */
- public ARRAYLENGTH() {
- super(org.aspectj.apache.bcel.Constants.ARRAYLENGTH, (short)1);
- }
-
- /** @return exceptions this instruction may cause
- */
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.NULL_POINTER_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitARRAYLENGTH(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ASTORE - Store reference into local variable
- * <PRE>Stack ..., objectref -> ... </PRE>
- *
- * @version $Id: ASTORE.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ASTORE extends StoreInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ASTORE() {
- super(org.aspectj.apache.bcel.Constants.ASTORE, org.aspectj.apache.bcel.Constants.ASTORE_0);
- }
-
- /** Store reference into local variable
- * @param n index of local variable
- */
- public ASTORE(int n) {
- super(org.aspectj.apache.bcel.Constants.ASTORE, org.aspectj.apache.bcel.Constants.ASTORE_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ATHROW - Throw exception
- * <PRE>Stack: ..., objectref -> objectref</PRE>
- *
- * @version $Id: ATHROW.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ATHROW extends Instruction implements UnconditionalBranch, ExceptionThrower {
- /**
- * Throw exception
- */
- public ATHROW() {
- super(org.aspectj.apache.bcel.Constants.ATHROW, (short)1);
- }
-
- /** @return exceptions this instruction may cause
- */
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.THROWABLE };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitUnconditionalBranch(this);
- v.visitExceptionThrower(this);
- v.visitATHROW(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denote family of instructions that allocates space in the heap.
- *
- * @version $Id: AllocationInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface AllocationInstruction {}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-/**
- * Super class for the family of arithmetic instructions.
- *
- * @version $Id: ArithmeticInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class ArithmeticInstruction extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ArithmeticInstruction() {}
-
- /**
- * @param opcode of instruction
- */
- protected ArithmeticInstruction(short opcode) {
- super(opcode, (short)1);
- }
-
- /** @return type associated with the instruction
- */
- public Type getType(ConstantPoolGen cp) {
- switch(opcode) {
- case Constants.DADD: case Constants.DDIV: case Constants.DMUL:
- case Constants.DNEG: case Constants.DREM: case Constants.DSUB:
- return Type.DOUBLE;
-
- case Constants.FADD: case Constants.FDIV: case Constants.FMUL:
- case Constants.FNEG: case Constants.FREM: case Constants.FSUB:
- return Type.FLOAT;
-
- case Constants.IADD: case Constants.IAND: case Constants.IDIV:
- case Constants.IMUL: case Constants.INEG: case Constants.IOR: case Constants.IREM:
- case Constants.ISHL: case Constants.ISHR: case Constants.ISUB:
- case Constants.IUSHR: case Constants.IXOR:
- return Type.INT;
-
- case Constants.LADD: case Constants.LAND: case Constants.LDIV:
- case Constants.LMUL: case Constants.LNEG: case Constants.LOR: case Constants.LREM:
- case Constants.LSHL: case Constants.LSHR: case Constants.LSUB:
- case Constants.LUSHR: case Constants.LXOR:
- return Type.LONG;
-
- default: // Never reached
- throw new ClassGenException("Unknown type " + opcode);
- }
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Super class for instructions dealing with array access such as IALOAD.
- *
- * @version $Id: ArrayInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class ArrayInstruction extends Instruction
- implements ExceptionThrower, TypedInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ArrayInstruction() {}
-
- /**
- * @param opcode of instruction
- */
- protected ArrayInstruction(short opcode) {
- super(opcode, (short)1);
- }
-
- public Class[] getExceptions() {
- return org.aspectj.apache.bcel.ExceptionConstants.EXCS_ARRAY_EXCEPTION;
- }
-
- /** @return type associated with the instruction
- */
- public Type getType(ConstantPoolGen cp) {
- switch(opcode) {
- case org.aspectj.apache.bcel.Constants.IALOAD: case org.aspectj.apache.bcel.Constants.IASTORE:
- return Type.INT;
- case org.aspectj.apache.bcel.Constants.CALOAD: case org.aspectj.apache.bcel.Constants.CASTORE:
- return Type.CHAR;
- case org.aspectj.apache.bcel.Constants.BALOAD: case org.aspectj.apache.bcel.Constants.BASTORE:
- return Type.BYTE;
- case org.aspectj.apache.bcel.Constants.SALOAD: case org.aspectj.apache.bcel.Constants.SASTORE:
- return Type.SHORT;
- case org.aspectj.apache.bcel.Constants.LALOAD: case org.aspectj.apache.bcel.Constants.LASTORE:
- return Type.LONG;
- case org.aspectj.apache.bcel.Constants.DALOAD: case org.aspectj.apache.bcel.Constants.DASTORE:
- return Type.DOUBLE;
- case org.aspectj.apache.bcel.Constants.FALOAD: case org.aspectj.apache.bcel.Constants.FASTORE:
- return Type.FLOAT;
- case org.aspectj.apache.bcel.Constants.AALOAD: case org.aspectj.apache.bcel.Constants.AASTORE:
- return Type.OBJECT;
-
- default: throw new ClassGenException("Oops: unknown case in switch" + opcode);
- }
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * BALOAD - Load byte or boolean from array
- * <PRE>Stack: ..., arrayref, index -> ..., value</PRE>
- *
- * @version $Id: BALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class BALOAD extends ArrayInstruction implements StackProducer {
- /** Load byte or boolean from array
- */
- public BALOAD() {
- super(org.aspectj.apache.bcel.Constants.BALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitBALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * BASTORE - Store into byte or boolean array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: BASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class BASTORE extends ArrayInstruction implements StackConsumer {
- /** Store byte or boolean into array
- */
- public BASTORE() {
- super(org.aspectj.apache.bcel.Constants.BASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitBASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * BIPUSH - Push byte on stack
- *
- * <PRE>Stack: ... -> ..., value</PRE>
- *
- * @version $Id: BIPUSH.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class BIPUSH extends Instruction implements ConstantPushInstruction {
- private byte b;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- BIPUSH() {}
-
- /** Push byte on stack
- */
- public BIPUSH(byte b) {
- super(org.aspectj.apache.bcel.Constants.BIPUSH, (short)2);
- this.b = b;
- }
-
- /**
- * Dump instruction as byte code to stream out.
- */
- public void dump(DataOutputStream out) throws IOException {
- super.dump(out);
- out.writeByte(b);
- }
-
- /**
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- return super.toString(verbose) + " " + b;
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- length = 2;
- b = bytes.readByte();
- }
-
- public Number getValue() { return new Integer(b); }
-
- /** @return Type.BYTE
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.BYTE;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitBIPUSH(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * BREAKPOINT, JVM dependent, ignored by default
- *
- * @version $Id: BREAKPOINT.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class BREAKPOINT extends Instruction {
- public BREAKPOINT() {
- super(org.aspectj.apache.bcel.Constants.BREAKPOINT, (short)1);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitBREAKPOINT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * Abstract super class for branching instructions like GOTO, IFEQ, etc..
- * Branch instructions may have a variable length, namely GOTO, JSR,
- * LOOKUPSWITCH and TABLESWITCH.
- *
- * @see InstructionList
- * @version $Id: BranchInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class BranchInstruction extends Instruction implements InstructionTargeter {
- protected int index; // Branch target relative to this instruction
- protected InstructionHandle target; // Target object in instruction list
- protected int position; // Byte code offset
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- BranchInstruction() {}
-
- /** Common super constructor
- * @param opcodee Instruction opcode
- * @param target instruction to branch to
- */
- protected BranchInstruction(short opcode, InstructionHandle target) {
- super(opcode, (short)3);
- setTarget(target);
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- out.writeByte(opcode);
-
- index = getTargetOffset();
-
- if(Math.abs(index) >= 32767) // too large for short
- throw new ClassGenException("Branch target offset too large for short");
-
- out.writeShort(index); // May be negative, i.e., point backwards
- }
-
- /**
- * @param target branch target
- * @return the offset to `target' relative to this instruction
- */
- protected int getTargetOffset(InstructionHandle target) {
- if(target == null)
- throw new ClassGenException("Target of " + super.toString(true) +
- " is invalid null handle");
-
- int t = target.getPosition();
-
- if(t < 0)
- throw new ClassGenException("Invalid branch target position offset for " +
- super.toString(true) + ":" + t + ":" + target);
-
- return t - position;
- }
-
- /**
- * @return the offset to this instruction's target
- */
- protected int getTargetOffset() { return getTargetOffset(target); }
-
- /**
- * Called by InstructionList.setPositions when setting the position for every
- * instruction. In the presence of variable length instructions `setPositions'
- * performs multiple passes over the instruction list to calculate the
- * correct (byte) positions and offsets by calling this function.
- *
- * @param offset additional offset caused by preceding (variable length) instructions
- * @param max_offset the maximum offset that may be caused by these instructions
- * @return additional offset caused by possible change of this instruction's length
- */
- protected int updatePosition(int offset, int max_offset) {
- position += offset;
- return 0;
- }
-
- /**
- * Long output format:
- *
- * <position in byte code>
- * <name of opcode> "["<opcode number>"]"
- * "("<length of instruction>")"
- * "<"<target instruction>">" "@"<branch target offset>
- *
- * @param verbose long/short format switch
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- String s = super.toString(verbose);
- String t = "null";
-
- if(verbose) {
- if(target != null) {
- if(target.getInstruction() == this)
- t = "<points to itself>";
- else if(target.getInstruction() == null)
- t = "<null instruction!!!?>";
- else
- t = target.getInstruction().toString(false); // Avoid circles
- }
- } else {
- if(target != null) {
- index = getTargetOffset();
- t = "" + (index + position);
- }
- }
-
- return s + " -> " + t;
- }
-
- /**
- * Read needed data (e.g. index) from file. Conversion to a InstructionHandle
- * is done in InstructionList(byte[]).
- *
- * @param bytes input stream
- * @param wide wide prefix?
- * @see InstructionList
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- length = 3;
- index = bytes.readShort();
- }
-
- /**
- * @return target offset in byte code
- */
- public final int getIndex() { return index; }
-
- /**
- * @return target of branch instruction
- */
- public InstructionHandle getTarget() { return target; }
-
- /**
- * Set branch target
- * @param target branch target
- */
- public void setTarget(InstructionHandle target) {
- notifyTarget(this.target, target, this);
- this.target = target;
- }
-
- /**
- * Used by BranchInstruction, LocalVariableGen, CodeExceptionGen
- */
- static final void notifyTarget(InstructionHandle old_ih, InstructionHandle new_ih,
- InstructionTargeter t) {
- if(old_ih != null)
- old_ih.removeTargeter(t);
- if(new_ih != null)
- new_ih.addTargeter(t);
- }
-
- /**
- * @param old_ih old target
- * @param new_ih new target
- */
- public void updateTarget(InstructionHandle old_ih, InstructionHandle new_ih) {
- if(target == old_ih)
- setTarget(new_ih);
- else
- throw new ClassGenException("Not targeting " + old_ih + ", but " + target);
- }
-
- /**
- * @return true, if ih is target of this instruction
- */
- public boolean containsTarget(InstructionHandle ih) {
- return (target == ih);
- }
-
- /**
- * Inform target that it's not targeted anymore.
- */
- void dispose() {
- setTarget(null);
- index=-1;
- position=-1;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * CALOAD - Load char from array
- * <PRE>Stack: ..., arrayref, index -> ..., value</PRE>
- *
- * @version $Id: CALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class CALOAD extends ArrayInstruction implements StackProducer {
- /** Load char from array
- */
- public CALOAD() {
- super(org.aspectj.apache.bcel.Constants.CALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitCALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * CASTORE - Store into char array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: CASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class CASTORE extends ArrayInstruction implements StackConsumer {
- /** Store char into array
- */
- public CASTORE() {
- super(org.aspectj.apache.bcel.Constants.CASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitCASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.ExceptionConstants;
-/**
- * CHECKCAST - Check whether object is of given type
- * <PRE>Stack: ..., objectref -> ..., objectref</PRE>
- *
- * @version $Id: CHECKCAST.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class CHECKCAST extends CPInstruction
- implements LoadClass, ExceptionThrower, StackProducer, StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- CHECKCAST() {}
-
- /** Check whether object is of given type
- * @param n index to class in constant pool
- */
- public CHECKCAST(int index) {
- super(org.aspectj.apache.bcel.Constants.CHECKCAST, index);
- }
-
- /** @return exceptions this instruction may cause
- */
- public Class[] getExceptions() {
- Class[] cs = new Class[1 + ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length);
- cs[ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length] =
- ExceptionConstants.CLASS_CAST_EXCEPTION;
- return cs;
- }
-
- public ObjectType getLoadClassType(ConstantPoolGen cpg) {
- Type t = getType(cpg);
-
- if(t instanceof ArrayType)
- t = ((ArrayType) t).getBasicType();
-
- return (t instanceof ObjectType)? (ObjectType) t : null;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitLoadClass(this);
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitCHECKCAST(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.Constant;
-import org.aspectj.apache.bcel.classfile.ConstantClass;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * Abstract super class for instructions that use an index into the
- * constant pool such as LDC, INVOKEVIRTUAL, etc.
- *
- * @see ConstantPoolGen
- * @see LDC
- * @see INVOKEVIRTUAL
- *
- * @version $Id: CPInstruction.java,v 1.4 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class CPInstruction extends Instruction
- implements TypedInstruction, IndexedInstruction
-{
- protected int index; // index to constant pool
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- CPInstruction() {}
-
- /**
- * @param index to constant pool
- */
- protected CPInstruction(short opcode, int index) {
- super(opcode, (short)3);
- setIndex(index);
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- out.writeByte(opcode);
- out.writeShort(index);
- }
-
- /**
- * Long output format:
- *
- * <name of opcode> "["<opcode number>"]"
- * "("<length of instruction>")" "<"< constant pool index>">"
- *
- * @param verbose long/short format switch
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- return super.toString(verbose) + " " + index;
- }
-
- /**
- * @return mnemonic for instruction with symbolic references resolved
- */
- public String toString(ConstantPool cp) {
- Constant c = cp.getConstant(index);
- String str = cp.constantToString(c);
-
- if(c instanceof ConstantClass)
- str = str.replace('.', '/');
-
- return org.aspectj.apache.bcel.Constants.OPCODE_NAMES[opcode] + " " + str;
- }
-
- /**
- * Read needed data (i.e., index) from file.
- * @param bytes input stream
- * @param wide wide prefix?
- */
- protected void initFromFile(ByteSequence bytes, boolean wide)
- throws IOException
- {
- setIndex(bytes.readUnsignedShort());
- length = 3;
- }
-
- /**
- * @return index in constant pool referred by this instruction.
- */
- public final int getIndex() { return index; }
-
- /**
- * Set the index to constant pool.
- * @param index in constant pool.
- */
- public void setIndex(int index) {
- if(index < 0)
- throw new ClassGenException("Negative index value: " + index);
-
- this.index = index;
- }
-
- /** @return type related with this instruction.
- */
- public Type getType(ConstantPoolGen cpg) {
- ConstantPool cp = cpg.getConstantPool();
- String name = cp.getConstantString(index, org.aspectj.apache.bcel.Constants.CONSTANT_Class);
-
- if(!name.startsWith("["))
- name = "L" + name + ";";
-
- return Type.getType(name);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Implement this interface if you're interested in changes to a ClassGen object
- * and register yourself with addObserver().
- *
- * @version $Id: ClassObserver.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface ClassObserver {
- public void notify(ClassGen clazz);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Wrapper class for `compound' operations, virtual instructions that
- * don't exist as byte code, but give a useful meaning. For example,
- * the (virtual) PUSH instruction takes an arbitray argument and produces the
- * appropiate code at dump time (ICONST, LDC, BIPUSH, ...). Also you can use the
- * SWITCH instruction as a useful template for either LOOKUPSWITCH or
- * TABLESWITCH.
- *
- * The interface provides the possibilty for the user to write
- * `templates' or `macros' for such reuseable code patterns.
- *
- * @version $Id: CompoundInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see PUSH
- * @see SWITCH
- */
-public interface CompoundInstruction {
- public InstructionList getInstructionList();
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.util.HashMap;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.Constant;
-import org.aspectj.apache.bcel.classfile.ConstantCP;
-import org.aspectj.apache.bcel.classfile.ConstantClass;
-import org.aspectj.apache.bcel.classfile.ConstantDouble;
-import org.aspectj.apache.bcel.classfile.ConstantFieldref;
-import org.aspectj.apache.bcel.classfile.ConstantFloat;
-import org.aspectj.apache.bcel.classfile.ConstantInteger;
-import org.aspectj.apache.bcel.classfile.ConstantInterfaceMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantLong;
-import org.aspectj.apache.bcel.classfile.ConstantMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantNameAndType;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantString;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-
-/**
- * This class is used to build up a constant pool. The user adds
- * constants via `addXXX' methods, `addString', `addClass',
- * etc.. These methods return an index into the constant
- * pool. Finally, `getFinalConstantPool()' returns the constant pool
- * built up. Intermediate versions of the constant pool can be
- * obtained with `getConstantPool()'. A constant pool has capacity for
- * Constants.MAX_SHORT entries. Note that the first (0) is used by the
- * JVM and that Double and Long constants need two slots.
- *
- * @version $Id: ConstantPoolGen.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see Constant
- */
-public class ConstantPoolGen implements java.io.Serializable {
- protected int size = 1024; // Inital size, sufficient in most cases
- protected Constant[] constants = new Constant[size];
- protected int index = 1; // First entry (0) used by JVM
-
- private static final String METHODREF_DELIM = ":";
- private static final String IMETHODREF_DELIM = "#";
- private static final String FIELDREF_DELIM = "&";
- private static final String NAT_DELIM = "%";
-
- private static class Index implements java.io.Serializable {
- int index;
- Index(int i) { index = i; }
- }
-
- /**
- * Initialize with given array of constants.
- *
- * @param c array of given constants, new ones will be appended
- */
- public ConstantPoolGen(Constant[] cs) {
- if(cs.length > size) {
- size = cs.length;
- constants = new Constant[size];
- }
-
- System.arraycopy(cs, 0, constants, 0, cs.length);
-
- if(cs.length > 0)
- index = cs.length;
-
- for(int i=1; i < index; i++) {
- Constant c = constants[i];
-
- if(c instanceof ConstantString) {
- ConstantString s = (ConstantString)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[s.getStringIndex()];
-
- string_table.put(u8.getBytes(), new Index(i));
- } else if(c instanceof ConstantClass) {
- ConstantClass s = (ConstantClass)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[s.getNameIndex()];
-
- class_table.put(u8.getBytes(), new Index(i));
- } else if(c instanceof ConstantNameAndType) {
- ConstantNameAndType n = (ConstantNameAndType)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[n.getNameIndex()];
- ConstantUtf8 u8_2 = (ConstantUtf8)constants[n.getSignatureIndex()];
-
- n_a_t_table.put(u8.getBytes() + NAT_DELIM + u8_2.getBytes(), new Index(i));
- } else if(c instanceof ConstantUtf8) {
- ConstantUtf8 u = (ConstantUtf8)c;
-
- utf8_table.put(u.getBytes(), new Index(i));
- } else if(c instanceof ConstantCP) {
- ConstantCP m = (ConstantCP)c;
- ConstantClass clazz = (ConstantClass)constants[m.getClassIndex()];
- ConstantNameAndType n = (ConstantNameAndType)constants[m.getNameAndTypeIndex()];
-
- ConstantUtf8 u8 = (ConstantUtf8)constants[clazz.getNameIndex()];
- String class_name = u8.getBytes().replace('/', '.');
-
- u8 = (ConstantUtf8)constants[n.getNameIndex()];
- String method_name = u8.getBytes();
-
- u8 = (ConstantUtf8)constants[n.getSignatureIndex()];
- String signature = u8.getBytes();
-
- String delim = METHODREF_DELIM;
-
- if(c instanceof ConstantInterfaceMethodref)
- delim = IMETHODREF_DELIM;
- else if(c instanceof ConstantFieldref)
- delim = FIELDREF_DELIM;
-
- cp_table.put(class_name + delim + method_name + delim + signature, new Index(i));
- }
- }
- }
-
- /**
- * Initialize with given constant pool.
- */
- public ConstantPoolGen(ConstantPool cp) {
- this(cp.getConstantPool());
- }
-
- /**
- * Create empty constant pool.
- */
- public ConstantPoolGen() {}
-
- /** Resize internal array of constants.
- */
- protected void adjustSize() {
- if(index + 3 >= size) {
- Constant[] cs = constants;
-
- size *= 2;
- constants = new Constant[size];
- System.arraycopy(cs, 0, constants, 0, index);
- }
- }
-
- private HashMap string_table = new HashMap();
-
- /**
- * Look for ConstantString in ConstantPool containing String `str'.
- *
- * @param str String to search for
- * @return index on success, -1 otherwise
- */
- public int lookupString(String str) {
- Index index = (Index)string_table.get(str);
- return (index != null)? index.index : -1;
- }
-
- /**
- * Add a new String constant to the ConstantPool, if it is not already in there.
- *
- * @param str String to add
- * @return index of entry
- */
- public int addString(String str) {
- int ret;
-
- if((ret = lookupString(str)) != -1)
- return ret; // Already in CP
-
- int utf8 = addUtf8(str);
-
- adjustSize();
-
- ConstantString s = new ConstantString(utf8);
-
- ret = index;
- constants[index++] = s;
-
- string_table.put(str, new Index(ret));
-
- return ret;
- }
-
- private HashMap class_table = new HashMap();
-
- /**
- * Look for ConstantClass in ConstantPool named `str'.
- *
- * @param str String to search for
- * @return index on success, -1 otherwise
- */
- public int lookupClass(String str) {
- Index index = (Index)class_table.get(str.replace('.', '/'));
- return (index != null)? index.index : -1;
- }
-
- private int addClass_(String clazz) {
- int ret;
-
- if((ret = lookupClass(clazz)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ConstantClass c = new ConstantClass(addUtf8(clazz));
-
- ret = index;
- constants[index++] = c;
-
- class_table.put(clazz, new Index(ret));
-
- return ret;
- }
-
- /**
- * Add a new Class reference to the ConstantPool, if it is not already in there.
- *
- * @param str Class to add
- * @return index of entry
- */
- public int addClass(String str) {
- return addClass_(str.replace('.', '/'));
- }
-
- /**
- * Add a new Class reference to the ConstantPool for a given type.
- *
- * @param str Class to add
- * @return index of entry
- */
- public int addClass(ObjectType type) {
- //BCELBUG:? Should this we getClassName() - perhaps it should be getSignature() ?!?
- return addClass(type.getClassName());
-// return addClass(type.getSignature());
- }
-
- /**
- * Add a reference to an array class (e.g. String[][]) as needed by MULTIANEWARRAY
- * instruction, e.g. to the ConstantPool.
- *
- * @param type type of array class
- * @return index of entry
- */
- public int addArrayClass(ArrayType type) {
- return addClass_(type.getSignature());
- }
-
- /**
- * Look for ConstantInteger in ConstantPool.
- *
- * @param n integer number to look for
- * @return index on success, -1 otherwise
- */
- public int lookupInteger(int n) {
- for(int i=1; i < index; i++) {
- if(constants[i] instanceof ConstantInteger) {
- ConstantInteger c = (ConstantInteger)constants[i];
-
- if(c.getBytes() == n)
- return i;
- }
- }
-
- return -1;
- }
-
- /**
- * Add a new Integer constant to the ConstantPool, if it is not already in there.
- *
- * @param n integer number to add
- * @return index of entry
- */
- public int addInteger(int n) {
- int ret;
-
- if((ret = lookupInteger(n)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ret = index;
- constants[index++] = new ConstantInteger(n);
-
- return ret;
- }
-
- /**
- * Look for ConstantFloat in ConstantPool.
- *
- * @param n Float number to look for
- * @return index on success, -1 otherwise
- */
- public int lookupFloat(float n) {
- int bits = Float.floatToIntBits(n);
-
- for(int i=1; i < index; i++) {
- if(constants[i] instanceof ConstantFloat) {
- ConstantFloat c = (ConstantFloat)constants[i];
-
- if(Float.floatToIntBits(c.getBytes()) == bits)
- return i;
- }
- }
-
- return -1;
- }
-
- /**
- * Add a new Float constant to the ConstantPool, if it is not already in there.
- *
- * @param n Float number to add
- * @return index of entry
- */
- public int addFloat(float n) {
- int ret;
-
- if((ret = lookupFloat(n)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ret = index;
- constants[index++] = new ConstantFloat(n);
-
- return ret;
- }
-
- private HashMap utf8_table = new HashMap();
-
- /**
- * Look for ConstantUtf8 in ConstantPool.
- *
- * @param n Utf8 string to look for
- * @return index on success, -1 otherwise
- */
- public int lookupUtf8(String n) {
- Index index = (Index)utf8_table.get(n);
-
- return (index != null)? index.index : -1;
- }
-
- /**
- * Add a new Utf8 constant to the ConstantPool, if it is not already in there.
- *
- * @param n Utf8 string to add
- * @return index of entry
- */
- public int addUtf8(String n) {
- int ret;
-
- if((ret = lookupUtf8(n)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ret = index;
- constants[index++] = new ConstantUtf8(n);
-
- utf8_table.put(n, new Index(ret));
-
- return ret;
- }
-
- /**
- * Look for ConstantLong in ConstantPool.
- *
- * @param n Long number to look for
- * @return index on success, -1 otherwise
- */
- public int lookupLong(long n) {
- for(int i=1; i < index; i++) {
- if(constants[i] instanceof ConstantLong) {
- ConstantLong c = (ConstantLong)constants[i];
-
- if(c.getBytes() == n)
- return i;
- }
- }
-
- return -1;
- }
-
- /**
- * Add a new long constant to the ConstantPool, if it is not already in there.
- *
- * @param n Long number to add
- * @return index of entry
- */
- public int addLong(long n) {
- int ret;
-
- if((ret = lookupLong(n)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ret = index;
- constants[index] = new ConstantLong(n);
- index += 2; // Wastes one entry according to spec
-
- return ret;
- }
-
- /**
- * Look for ConstantDouble in ConstantPool.
- *
- * @param n Double number to look for
- * @return index on success, -1 otherwise
- */
- public int lookupDouble(double n) {
- long bits = Double.doubleToLongBits(n);
-
- for(int i=1; i < index; i++) {
- if(constants[i] instanceof ConstantDouble) {
- ConstantDouble c = (ConstantDouble)constants[i];
-
- if(Double.doubleToLongBits(c.getBytes()) == bits)
- return i;
- }
- }
-
- return -1;
- }
-
- /**
- * Add a new double constant to the ConstantPool, if it is not already in there.
- *
- * @param n Double number to add
- * @return index of entry
- */
- public int addDouble(double n) {
- int ret;
-
- if((ret = lookupDouble(n)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- ret = index;
- constants[index] = new ConstantDouble(n);
- index += 2; // Wastes one entry according to spec
-
- return ret;
- }
-
- private HashMap n_a_t_table = new HashMap();
-
- /**
- * Look for ConstantNameAndType in ConstantPool.
- *
- * @param name of variable/method
- * @param signature of variable/method
- * @return index on success, -1 otherwise
- */
- public int lookupNameAndType(String name, String signature) {
- Index index = (Index)n_a_t_table.get(name + NAT_DELIM + signature);
- return (index != null)? index.index : -1;
- }
-
- /**
- * Add a new NameAndType constant to the ConstantPool if it is not already
- * in there.
- *
- * @param n NameAndType string to add
- * @return index of entry
- */
- public int addNameAndType(String name, String signature) {
- int ret;
- int name_index, signature_index;
-
- if((ret = lookupNameAndType(name, signature)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- name_index = addUtf8(name);
- signature_index = addUtf8(signature);
- ret = index;
- constants[index++] = new ConstantNameAndType(name_index, signature_index);
-
- n_a_t_table.put(name + NAT_DELIM + signature, new Index(ret));
- return ret;
- }
-
- private HashMap cp_table = new HashMap();
-
- /**
- * Look for ConstantMethodref in ConstantPool.
- *
- * @param class_name Where to find method
- * @param method_name Guess what
- * @param signature return and argument types
- * @return index on success, -1 otherwise
- */
- public int lookupMethodref(String class_name, String method_name, String signature) {
- Index index = (Index)cp_table.get(class_name + METHODREF_DELIM + method_name +
- METHODREF_DELIM + signature);
- return (index != null)? index.index : -1;
- }
-
- public int lookupMethodref(MethodGen method) {
- return lookupMethodref(method.getClassName(), method.getName(),
- method.getSignature());
- }
-
- /**
- * Add a new Methodref constant to the ConstantPool, if it is not already
- * in there.
- *
- * @param n Methodref string to add
- * @return index of entry
- */
- public int addMethodref(String class_name, String method_name, String signature) {
- int ret, class_index, name_and_type_index;
-
- if((ret = lookupMethodref(class_name, method_name, signature)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- name_and_type_index = addNameAndType(method_name, signature);
- class_index = addClass(class_name);
- ret = index;
- constants[index++] = new ConstantMethodref(class_index, name_and_type_index);
-
- cp_table.put(class_name + METHODREF_DELIM + method_name +
- METHODREF_DELIM + signature, new Index(ret));
-
- return ret;
- }
-
- public int addMethodref(MethodGen method) {
- return addMethodref(method.getClassName(), method.getName(),
- method.getSignature());
- }
-
- /**
- * Look for ConstantInterfaceMethodref in ConstantPool.
- *
- * @param class_name Where to find method
- * @param method_name Guess what
- * @param signature return and argument types
- * @return index on success, -1 otherwise
- */
- public int lookupInterfaceMethodref(String class_name, String method_name, String signature) {
- Index index = (Index)cp_table.get(class_name + IMETHODREF_DELIM + method_name +
- IMETHODREF_DELIM + signature);
- return (index != null)? index.index : -1;
- }
-
- public int lookupInterfaceMethodref(MethodGen method) {
- return lookupInterfaceMethodref(method.getClassName(), method.getName(),
- method.getSignature());
- }
-
- /**
- * Add a new InterfaceMethodref constant to the ConstantPool, if it is not already
- * in there.
- *
- * @param n InterfaceMethodref string to add
- * @return index of entry
- */
- public int addInterfaceMethodref(String class_name, String method_name, String signature) {
- int ret, class_index, name_and_type_index;
-
- if((ret = lookupInterfaceMethodref(class_name, method_name, signature)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- class_index = addClass(class_name);
- name_and_type_index = addNameAndType(method_name, signature);
- ret = index;
- constants[index++] = new ConstantInterfaceMethodref(class_index, name_and_type_index);
-
- cp_table.put(class_name + IMETHODREF_DELIM + method_name +
- IMETHODREF_DELIM + signature, new Index(ret));
-
- return ret;
- }
-
- public int addInterfaceMethodref(MethodGen method) {
- return addInterfaceMethodref(method.getClassName(), method.getName(),
- method.getSignature());
- }
-
- /**
- * Look for ConstantFieldref in ConstantPool.
- *
- * @param class_name Where to find method
- * @param field_name Guess what
- * @param signature return and argument types
- * @return index on success, -1 otherwise
- */
- public int lookupFieldref(String class_name, String field_name, String signature) {
- Index index = (Index)cp_table.get(class_name + FIELDREF_DELIM + field_name +
- FIELDREF_DELIM + signature);
- return (index != null)? index.index : -1;
- }
-
- /**
- * Add a new Fieldref constant to the ConstantPool, if it is not already
- * in there.
- *
- * @param n Fieldref string to add
- * @return index of entry
- */
- public int addFieldref(String class_name, String field_name, String signature) {
- int ret;
- int class_index, name_and_type_index;
-
- if((ret = lookupFieldref(class_name, field_name, signature)) != -1)
- return ret; // Already in CP
-
- adjustSize();
-
- class_index = addClass(class_name);
- name_and_type_index = addNameAndType(field_name, signature);
- ret = index;
- constants[index++] = new ConstantFieldref(class_index, name_and_type_index);
-
- cp_table.put(class_name + FIELDREF_DELIM + field_name + FIELDREF_DELIM + signature, new Index(ret));
-
- return ret;
- }
-
- /**
- * @param i index in constant pool
- * @return constant pool entry at index i
- */
- public Constant getConstant(int i) { return constants[i]; }
-
- /**
- * Use with care!
- *
- * @param i index in constant pool
- * @param c new constant pool entry at index i
- */
- public void setConstant(int i, Constant c) { constants[i] = c; }
-
- /**
- * @return intermediate constant pool
- */
- public ConstantPool getConstantPool() {
- return new ConstantPool(constants);
- }
-
- /**
- * @return current size of constant pool
- */
- public int getSize() {
- return index;
- }
-
- /**
- * @return constant pool with proper length
- */
- public ConstantPool getFinalConstantPool() {
- Constant[] cs = new Constant[index];
-
- System.arraycopy(constants, 0, cs, 0, index);
-
- return new ConstantPool(cs);
- }
-
- /**
- * @return String representation.
- */
- public String toString() {
- StringBuffer buf = new StringBuffer();
-
- for(int i=1; i < index; i++)
- buf.append(i + ")" + constants[i] + "\n");
-
- return buf.toString();
- }
-
- /** Import constant from another ConstantPool and return new index.
- */
- public int addConstant(Constant c, ConstantPoolGen cp) {
- Constant[] constants = cp.getConstantPool().getConstantPool();
-
- switch(c.getTag()) {
- case Constants.CONSTANT_String: {
- ConstantString s = (ConstantString)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[s.getStringIndex()];
-
- return addString(u8.getBytes());
- }
-
- case Constants.CONSTANT_Class: {
- ConstantClass s = (ConstantClass)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[s.getNameIndex()];
-
- return addClass(u8.getBytes());
- }
-
- case Constants.CONSTANT_NameAndType: {
- ConstantNameAndType n = (ConstantNameAndType)c;
- ConstantUtf8 u8 = (ConstantUtf8)constants[n.getNameIndex()];
- ConstantUtf8 u8_2 = (ConstantUtf8)constants[n.getSignatureIndex()];
-
- return addNameAndType(u8.getBytes(), u8_2.getBytes());
- }
-
- case Constants.CONSTANT_Utf8:
- return addUtf8(((ConstantUtf8)c).getBytes());
-
- case Constants.CONSTANT_Double:
- return addDouble(((ConstantDouble)c).getBytes());
-
- case Constants.CONSTANT_Float:
- return addFloat(((ConstantFloat)c).getBytes());
-
- case Constants.CONSTANT_Long:
- return addLong(((ConstantLong)c).getBytes());
-
- case Constants.CONSTANT_Integer:
- return addInteger(((ConstantInteger)c).getBytes());
-
- case Constants.CONSTANT_InterfaceMethodref: case Constants.CONSTANT_Methodref:
- case Constants.CONSTANT_Fieldref: {
- ConstantCP m = (ConstantCP)c;
- ConstantClass clazz = (ConstantClass)constants[m.getClassIndex()];
- ConstantNameAndType n = (ConstantNameAndType)constants[m.getNameAndTypeIndex()];
- ConstantUtf8 u8 = (ConstantUtf8)constants[clazz.getNameIndex()];
- String class_name = u8.getBytes().replace('/', '.');
-
- u8 = (ConstantUtf8)constants[n.getNameIndex()];
- String name = u8.getBytes();
-
- u8 = (ConstantUtf8)constants[n.getSignatureIndex()];
- String signature = u8.getBytes();
-
- switch(c.getTag()) {
- case Constants.CONSTANT_InterfaceMethodref:
- return addInterfaceMethodref(class_name, name, signature);
-
- case Constants.CONSTANT_Methodref:
- return addMethodref(class_name, name, signature);
-
- case Constants.CONSTANT_Fieldref:
- return addFieldref(class_name, name, signature);
-
- default: // Never reached
- throw new RuntimeException("Unknown constant type " + c);
- }
- }
-
- default: // Never reached
- throw new RuntimeException("Unknown constant type " + c);
- }
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes a push instruction that produces a literal on the stack
- * such as SIPUSH, BIPUSH, ICONST, etc.
- *
- * @version $Id: ConstantPushInstruction.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
-
- * @see ICONST
- * @see SIPUSH
- */
-public interface ConstantPushInstruction extends PushInstruction, TypedInstruction {
- public Number getValue();
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-/**
- * Super class for the x2y family of instructions.
- *
- * @version $Id: ConversionInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class ConversionInstruction extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ConversionInstruction() {}
-
- /**
- * @param opcode opcode of instruction
- */
- protected ConversionInstruction(short opcode) {
- super(opcode, (short)1);
- }
-
- /** @return type associated with the instruction
- */
- public Type getType(ConstantPoolGen cp) {
- switch(opcode) {
- case Constants.D2I: case Constants.F2I: case Constants.L2I:
- return Type.INT;
- case Constants.D2F: case Constants.I2F: case Constants.L2F:
- return Type.FLOAT;
- case Constants.D2L: case Constants.F2L: case Constants.I2L:
- return Type.LONG;
- case Constants.F2D: case Constants.I2D: case Constants.L2D:
- return Type.DOUBLE;
- case Constants.I2B:
- return Type.BYTE;
- case Constants.I2C:
- return Type.CHAR;
- case Constants.I2S:
- return Type.SHORT;
-
- default: // Never reached
- throw new ClassGenException("Unknown type " + opcode);
- }
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * D2F - Convert double to float
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result</PRE>
- *
- * @version $Id: D2F.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class D2F extends ConversionInstruction {
- /** Convert double to float
- */
- public D2F() {
- super(org.aspectj.apache.bcel.Constants.D2F);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitD2F(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * D2I - Convert double to int
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result</PRE>
- *
- * @version $Id: D2I.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class D2I extends ConversionInstruction {
- /** Convert double to int
- */
- public D2I() {
- super(org.aspectj.apache.bcel.Constants.D2I);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitD2I(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * D2L - Convert double to long
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: D2L.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class D2L extends ConversionInstruction {
- /** Convert double to long
- */
- public D2L() {
- super(org.aspectj.apache.bcel.Constants.D2L);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitD2L(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DADD - Add doubles
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result1.word2
- *
- * @version $Id: DADD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DADD extends ArithmeticInstruction {
- /** Add doubles
- */
- public DADD() {
- super(org.aspectj.apache.bcel.Constants.DADD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDADD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DALOAD - Load double from array
- * <PRE>Stack: ..., arrayref, index -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: DALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DALOAD extends ArrayInstruction implements StackProducer {
- /** Load double from array
- */
- public DALOAD() {
- super(org.aspectj.apache.bcel.Constants.DALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitDALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DASTORE - Store into double array
- * <PRE>Stack: ..., arrayref, index, value.word1, value.word2 -> ...</PRE>
- *
- * @version $Id: DASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DASTORE extends ArrayInstruction implements StackConsumer {
- /** Store double into array
- */
- public DASTORE() {
- super(org.aspectj.apache.bcel.Constants.DASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitDASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DCMPG - Compare doubles: value1 > value2
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result
- *
- * @version $Id: DCMPG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DCMPG extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
-
- public DCMPG() {
- super(org.aspectj.apache.bcel.Constants.DCMPG, (short)1);
- }
-
- /** @return Type.DOUBLE
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.DOUBLE;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitDCMPG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DCMPL - Compare doubles: value1 < value2
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result
- *
- * @version $Id: DCMPL.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DCMPL extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
- public DCMPL() {
- super(org.aspectj.apache.bcel.Constants.DCMPL, (short)1);
- }
-
- /** @return Type.DOUBLE
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.DOUBLE;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitDCMPL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DCONST - Push 0.0 or 1.0, other values cause an exception
- *
- * <PRE>Stack: ... -> ..., </PRE>
- *
- * @version $Id: DCONST.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DCONST extends Instruction
- implements ConstantPushInstruction, TypedInstruction {
- private double value;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- DCONST() {}
-
- public DCONST(double f) {
- super(org.aspectj.apache.bcel.Constants.DCONST_0, (short)1);
-
- if(f == 0.0)
- opcode = org.aspectj.apache.bcel.Constants.DCONST_0;
- else if(f == 1.0)
- opcode = org.aspectj.apache.bcel.Constants.DCONST_1;
- else
- throw new ClassGenException("DCONST can be used only for 0.0 and 1.0: " + f);
-
- value = f;
- }
-
- public Number getValue() { return new Double(value); }
-
- /** @return Type.DOUBLE
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.DOUBLE;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitDCONST(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DDIV - Divide doubles
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: DDIV.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DDIV extends ArithmeticInstruction {
- /** Divide doubles
- */
- public DDIV() {
- super(org.aspectj.apache.bcel.Constants.DDIV);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDDIV(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DLOAD - Load double from local variable
- * <PRE>Stack ... -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: DLOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DLOAD extends LoadInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- DLOAD() {
- super(org.aspectj.apache.bcel.Constants.DLOAD, org.aspectj.apache.bcel.Constants.DLOAD_0);
- }
-
- /** Load double from local variable
- * @param n index of local variable
- */
- public DLOAD(int n) {
- super(org.aspectj.apache.bcel.Constants.DLOAD, org.aspectj.apache.bcel.Constants.DLOAD_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitDLOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DMUL - Multiply doubles
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: DMUL.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DMUL extends ArithmeticInstruction {
- /** Multiply doubles
- */
- public DMUL() {
- super(org.aspectj.apache.bcel.Constants.DMUL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDMUL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DNEG - Negate double
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: DNEG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DNEG extends ArithmeticInstruction {
- public DNEG() {
- super(org.aspectj.apache.bcel.Constants.DNEG);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDNEG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DREM - Remainder of doubles
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: DREM.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DREM extends ArithmeticInstruction {
- /** Remainder of doubles
- */
- public DREM() {
- super(org.aspectj.apache.bcel.Constants.DREM);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDREM(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DRETURN - Return double from method
- * <PRE>Stack: ..., value.word1, value.word2 -> <empty></PRE>
- *
- * @version $Id: DRETURN.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DRETURN extends ReturnInstruction {
- /** Return double from method
- */
- public DRETURN() {
- super(org.aspectj.apache.bcel.Constants.DRETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitDRETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DSTORE - Store double into local variable
- * <pre>Stack: ..., value.word1, value.word2 -> ... </PRE>
- *
- * @version $Id: DSTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DSTORE extends StoreInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- DSTORE() {
- super(org.aspectj.apache.bcel.Constants.DSTORE, org.aspectj.apache.bcel.Constants.DSTORE_0);
- }
-
- /** Store double into local variable
- * @param n index of local variable
- */
- public DSTORE(int n) {
- super(org.aspectj.apache.bcel.Constants.DSTORE, org.aspectj.apache.bcel.Constants.DSTORE_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitDSTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DSUB - Substract doubles
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: DSUB.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DSUB extends ArithmeticInstruction {
- /** Substract doubles
- */
- public DSUB() {
- super(org.aspectj.apache.bcel.Constants.DSUB);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitDSUB(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP - Duplicate top operand stack word
- * <PRE>Stack: ..., word -> ..., word, word</PRE>
- *
- * @version $Id: DUP.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP extends StackInstruction implements PushInstruction {
- public DUP() {
- super(org.aspectj.apache.bcel.Constants.DUP);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitStackInstruction(this);
- v.visitDUP(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP2 - Duplicate two top operand stack words
- * <PRE>Stack: ..., word2, word1 -> ..., word2, word1, word2, word1</PRE>
- *
- * @version $Id: DUP2.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP2 extends StackInstruction implements PushInstruction {
- public DUP2() {
- super(org.aspectj.apache.bcel.Constants.DUP2);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitStackInstruction(this);
- v.visitDUP2(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP2_X1 - Duplicate two top operand stack words and put three down
- * <PRE>Stack: ..., word3, word2, word1 -> ..., word2, word1, word3, word2, word1</PRE>
- *
- * @version $Id: DUP2_X1.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP2_X1 extends StackInstruction {
- public DUP2_X1() {
- super(org.aspectj.apache.bcel.Constants.DUP2_X1);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackInstruction(this);
- v.visitDUP2_X1(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP2_X2 - Duplicate two top operand stack words and put four down
- * <PRE>Stack: ..., word4, word3, word2, word1 -> ..., word2, word1, word4, word3, word2, word1</PRE>
- *
- * @version $Id: DUP2_X2.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP2_X2 extends StackInstruction {
- public DUP2_X2() {
- super(org.aspectj.apache.bcel.Constants.DUP2_X2);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackInstruction(this);
- v.visitDUP2_X2(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP_X1 - Duplicate top operand stack word and put two down
- * <PRE>Stack: ..., word2, word1 -> ..., word1, word2, word1</PRE>
- *
- * @version $Id: DUP_X1.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP_X1 extends StackInstruction {
- public DUP_X1() {
- super(org.aspectj.apache.bcel.Constants.DUP_X1);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackInstruction(this);
- v.visitDUP_X1(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * DUP_X2 - Duplicate top operand stack word and put three down
- * <PRE>Stack: ..., word3, word2, word1 -> ..., word1, word3, word2, word1</PRE>
- *
- * @version $Id: DUP_X2.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class DUP_X2 extends StackInstruction {
- public DUP_X2() {
- super(org.aspectj.apache.bcel.Constants.DUP_X2);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackInstruction(this);
- v.visitDUP_X2(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denote an instruction that may throw a run-time or a linking
- * exception (or both) during execution. This is not quite the truth
- * as such; because all instructions may throw an
- * java.lang.VirtualMachineError. These exceptions are omitted.
- *
- * The Lava Language Specification specifies exactly which
- * <i>RUN-TIME</i> and which <i>LINKING</i> exceptions each
- * instruction may throw which is reflected by the implementers. Due
- * to the structure of the JVM specification, it may be possible that
- * an Instruction implementing this interface returns a Class[] of
- * size 0.
- *
- * Please note that we speak of an "exception" here when we mean any
- * "Throwable" object; so this term is equally used for "Exception"
- * and "Error" objects.
- *
- * @version $Id: ExceptionThrower.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="http://www.inf.fu-berlin.de/~ehaase">Enver Haase</A>
- */
-public interface ExceptionThrower {
- public java.lang.Class[] getExceptions();
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * F2D - Convert float to double
- * <PRE>Stack: ..., value -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: F2D.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class F2D extends ConversionInstruction {
- /** Convert float to double
- */
- public F2D() {
- super(org.aspectj.apache.bcel.Constants.F2D);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitF2D(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * F2I - Convert float to int
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: F2I.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class F2I extends ConversionInstruction {
- /** Convert float to int
- */
- public F2I() {
- super(org.aspectj.apache.bcel.Constants.F2I);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitF2I(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * F2L - Convert float to long
- * <PRE>Stack: ..., value -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: F2L.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class F2L extends ConversionInstruction {
- /** Convert float to long
- */
- public F2L() {
- super(org.aspectj.apache.bcel.Constants.F2L);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitF2L(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FADD - Add floats
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: FADD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FADD extends ArithmeticInstruction {
- /** Add floats
- */
- public FADD() {
- super(org.aspectj.apache.bcel.Constants.FADD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFADD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FALOAD - Load float from array
- * <PRE>Stack: ..., arrayref, index -> ..., value</PRE>
- *
- * @version $Id: FALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FALOAD extends ArrayInstruction implements StackProducer {
- /** Load float from array
- */
- public FALOAD() {
- super(org.aspectj.apache.bcel.Constants.FALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitFALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FASTORE - Store into float array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: FASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FASTORE extends ArrayInstruction implements StackConsumer {
- /** Store float into array
- */
- public FASTORE() {
- super(org.aspectj.apache.bcel.Constants.FASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitFASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FCMPG - Compare floats: value1 > value2
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: FCMPG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FCMPG extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
- public FCMPG() {
- super(org.aspectj.apache.bcel.Constants.FCMPG, (short)1);
- }
-
- /** @return Type.FLOAT
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.FLOAT;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitFCMPG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FCMPL - Compare floats: value1 < value2
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: FCMPL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FCMPL extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer {
- public FCMPL() {
- super(org.aspectj.apache.bcel.Constants.FCMPL, (short)1);
- }
-
- /** @return Type.FLOAT
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.FLOAT;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitFCMPL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FCONST - Push 0.0, 1.0 or 2.0, other values cause an exception
- *
- * <PRE>Stack: ... -> ..., </PRE>
- *
- * @version $Id: FCONST.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FCONST extends Instruction
- implements ConstantPushInstruction, TypedInstruction {
- private float value;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- FCONST() {}
-
- public FCONST(float f) {
- super(org.aspectj.apache.bcel.Constants.FCONST_0, (short)1);
-
- if(f == 0.0)
- opcode = org.aspectj.apache.bcel.Constants.FCONST_0;
- else if(f == 1.0)
- opcode = org.aspectj.apache.bcel.Constants.FCONST_1;
- else if(f == 2.0)
- opcode = org.aspectj.apache.bcel.Constants.FCONST_2;
- else
- throw new ClassGenException("FCONST can be used only for 0.0, 1.0 and 2.0: " + f);
-
- value = f;
- }
-
- public Number getValue() { return new Float(value); }
-
- /** @return Type.FLOAT
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.FLOAT;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitFCONST(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FDIV - Divide floats
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: FDIV.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FDIV extends ArithmeticInstruction {
- /** Divide floats
- */
- public FDIV() {
- super(org.aspectj.apache.bcel.Constants.FDIV);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFDIV(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FLOAD - Load float from local variable
- * <PRE>Stack ... -> ..., result</PRE>
- *
- * @version $Id: FLOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FLOAD extends LoadInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- FLOAD() {
- super(org.aspectj.apache.bcel.Constants.FLOAD, org.aspectj.apache.bcel.Constants.FLOAD_0);
- }
-
- /** Load float from local variable
- * @param n index of local variable
- */
- public FLOAD(int n) {
- super(org.aspectj.apache.bcel.Constants.FLOAD, org.aspectj.apache.bcel.Constants.FLOAD_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitFLOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FMUL - Multiply floats
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: FMUL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FMUL extends ArithmeticInstruction {
- /** Multiply floats
- */
- public FMUL() {
- super(org.aspectj.apache.bcel.Constants.FMUL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFMUL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FNEG - Negate float
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: FNEG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FNEG extends ArithmeticInstruction {
- public FNEG() {
- super(org.aspectj.apache.bcel.Constants.FNEG);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFNEG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FREM - Remainder of floats
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: FREM.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FREM extends ArithmeticInstruction {
- /** Remainder of floats
- */
- public FREM() {
- super(org.aspectj.apache.bcel.Constants.FREM);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFREM(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FRETURN - Return float from method
- * <PRE>Stack: ..., value -> <empty></PRE>
- *
- * @version $Id: FRETURN.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FRETURN extends ReturnInstruction {
- /** Return float from method
- */
- public FRETURN() {
- super(org.aspectj.apache.bcel.Constants.FRETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitFRETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FSTORE - Store float into local variable
- * <PRE>Stack: ..., value -> ... </PRE>
- *
- * @version $Id: FSTORE.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FSTORE extends StoreInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- FSTORE() {
- super(org.aspectj.apache.bcel.Constants.FSTORE, org.aspectj.apache.bcel.Constants.FSTORE_0);
- }
-
- /** Store float into local variable
- * @param n index of local variable
- */
- public FSTORE(int n) {
- super(org.aspectj.apache.bcel.Constants.FSTORE, org.aspectj.apache.bcel.Constants.FSTORE_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitFSTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * FSUB - Substract floats
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: FSUB.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class FSUB extends ArithmeticInstruction {
- /** Substract floats
- */
- public FSUB() {
- super(org.aspectj.apache.bcel.Constants.FSUB);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitFSUB(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Imnplement this interface if you're interested in changes to a FieldGen object
- * and register yourself with addObserver().
- *
- * @version $Id: FieldObserver.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface FieldObserver {
- public void notify(FieldGen field);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * GETFIELD - Fetch field from object
- * <PRE>Stack: ..., objectref -> ..., value</PRE>
- * OR
- * <PRE>Stack: ..., objectref -> ..., value.word1, value.word2</PRE>
- *
- * @version $Id: GETFIELD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class GETFIELD extends FieldInstruction
- implements ExceptionThrower, StackConsumer, StackProducer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- GETFIELD() {}
-
- public GETFIELD(int index) {
- super(Constants.GETFIELD, index);
- }
-
- public int produceStack(ConstantPoolGen cpg) { return getFieldSize(cpg); }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[2 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+1] =
- ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] =
- ExceptionConstants.NULL_POINTER_EXCEPTION;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackConsumer(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitFieldInstruction(this);
- v.visitGETFIELD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * GETSTATIC - Fetch static field from class
- * <PRE>Stack: ..., -> ..., value</PRE>
- * OR
- * <PRE>Stack: ..., -> ..., value.word1, value.word2</PRE>
- *
- * @version $Id: GETSTATIC.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class GETSTATIC extends FieldInstruction implements PushInstruction, ExceptionThrower {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- GETSTATIC() {}
-
- public GETSTATIC(int index) {
- super(Constants.GETSTATIC, index);
- }
-
- public int produceStack(ConstantPoolGen cpg) { return getFieldSize(cpg); }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[1 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] =
- ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitFieldInstruction(this);
- v.visitGETSTATIC(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-
-/**
- * GOTO - Branch always (to relative offset, not absolute address)
- *
- * @version $Id: GOTO.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class GOTO extends GotoInstruction implements VariableLengthInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- GOTO() {}
-
- public GOTO(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.GOTO, target);
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- index = getTargetOffset();
- if(opcode == org.aspectj.apache.bcel.Constants.GOTO)
- super.dump(out);
- else { // GOTO_W
- index = getTargetOffset();
- out.writeByte(opcode);
- out.writeInt(index);
- }
- }
-
- /** Called in pass 2 of InstructionList.setPositions() in order to update
- * the branch target, that may shift due to variable length instructions.
- */
- protected int updatePosition(int offset, int max_offset) {
- int i = getTargetOffset(); // Depending on old position value
-
- position += offset; // Position may be shifted by preceding expansions
-
- if(Math.abs(i) >= (32767 - max_offset)) { // to large for short (estimate)
- opcode = org.aspectj.apache.bcel.Constants.GOTO_W;
- length = 5;
- return 2; // 5 - 3
- }
-
- return 0;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitVariableLengthInstruction(this);
- v.visitUnconditionalBranch(this);
- v.visitBranchInstruction(this);
- v.visitGotoInstruction(this);
- v.visitGOTO(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * GOTO_W - Branch always (to relative offset, not absolute address)
- *
- * @version $Id: GOTO_W.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class GOTO_W extends GotoInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- GOTO_W() {}
-
- public GOTO_W(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.GOTO_W, target);
- length = 5;
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- index = getTargetOffset();
- out.writeByte(opcode);
- out.writeInt(index);
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- index = bytes.readInt();
- length = 5;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitUnconditionalBranch(this);
- v.visitBranchInstruction(this);
- v.visitGotoInstruction(this);
- v.visitGOTO_W(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Super class for GOTO
- *
- * @version $Id: GotoInstruction.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class GotoInstruction extends BranchInstruction
- implements UnconditionalBranch
-{
- GotoInstruction(short opcode, InstructionHandle target) {
- super(opcode, target);
- }
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- GotoInstruction(){}
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2B - Convert int to byte
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: I2B.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2B extends ConversionInstruction {
- /** Convert int to byte
- */
- public I2B() {
- super(org.aspectj.apache.bcel.Constants.I2B);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2B(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2C - Convert int to char
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: I2C.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2C extends ConversionInstruction {
- /** Convert int to char
- */
- public I2C() {
- super(org.aspectj.apache.bcel.Constants.I2C);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2C(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2D - Convert int to double
- * <PRE>Stack: ..., value -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: I2D.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2D extends ConversionInstruction {
- /** Convert int to double
- */
- public I2D() {
- super(org.aspectj.apache.bcel.Constants.I2D);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2D(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2F - Convert int to float
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: I2F.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2F extends ConversionInstruction {
- /** Convert int to float
- */
- public I2F() {
- super(org.aspectj.apache.bcel.Constants.I2F);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2F(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2L - Convert int to long
- * <PRE>Stack: ..., value -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: I2L.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2L extends ConversionInstruction {
- /** Convert int to long
- */
- public I2L() {
- super(org.aspectj.apache.bcel.Constants.I2L);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2L(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * I2S - Convert int to short
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: I2S.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class I2S extends ConversionInstruction {
- public I2S() {
- super(org.aspectj.apache.bcel.Constants.I2S);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitI2S(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IADD - Add ints
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: IADD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IADD extends ArithmeticInstruction {
- /** Add ints
- */
- public IADD() {
- super(org.aspectj.apache.bcel.Constants.IADD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIADD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IALOAD - Load int from array
- * <PRE>Stack: ..., arrayref, index -> ..., value</PRE>
- *
- * @version $Id: IALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IALOAD extends ArrayInstruction implements StackProducer {
- /**
- * Load int from array
- */
- public IALOAD() {
- super(org.aspectj.apache.bcel.Constants.IALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitIALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IAND - Bitwise AND int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: IAND.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IAND extends ArithmeticInstruction {
- public IAND() {
- super(org.aspectj.apache.bcel.Constants.IAND);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIAND(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IASTORE - Store into int array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: IASTORE.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IASTORE extends ArrayInstruction implements StackConsumer {
- /**
- * Store into int array
- */
- public IASTORE() {
- super(org.aspectj.apache.bcel.Constants.IASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitIASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ICONST - Push value between -1, ..., 5, other values cause an exception
- *
- * <PRE>Stack: ... -> ..., </PRE>
- *
- * @version $Id: ICONST.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ICONST extends Instruction
- implements ConstantPushInstruction, TypedInstruction {
- private int value;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ICONST() {}
-
- public ICONST(int i) {
- super(org.aspectj.apache.bcel.Constants.ICONST_0, (short)1);
-
- if((i >= -1) && (i <= 5))
- opcode = (short)(org.aspectj.apache.bcel.Constants.ICONST_0 + i); // Even works for i == -1
- else
- throw new ClassGenException("ICONST can be used only for value between -1 and 5: " +
- i);
- value = i;
- }
-
- public Number getValue() { return new Integer(value); }
-
- /** @return Type.INT
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.INT;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitICONST(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IDIV - Divide ints
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: IDIV.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IDIV extends ArithmeticInstruction implements ExceptionThrower {
- /** Divide ints
- */
- public IDIV() {
- super(org.aspectj.apache.bcel.Constants.IDIV);
- }
-
- /** @return exceptions this instruction may cause
- */
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.ARITHMETIC_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIDIV(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFEQ - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFEQ.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFEQ extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFEQ() {}
-
- public IFEQ(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFEQ, target);
- }
-
- /**
- * @return negation of instruction, e.g. IFEQ.negate() == IFNE
- */
- public IfInstruction negate() {
- return new IFNE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFEQ(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFGE - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFGE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFGE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFGE() {}
-
- public IFGE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFGE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFLT(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFGE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFGT - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFGT.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFGT extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFGT() {}
-
- public IFGT(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFGT, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFLE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFGT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFLE - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFLE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFLE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFLE() {}
-
- public IFLE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFLE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFGT(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFLE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFLT - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFLT.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFLT extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFLT() {}
-
- public IFLT(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFLT, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFGE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFLT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFNE - Branch if int comparison with zero succeeds
- *
- * <PRE>Stack: ..., value -> ...</PRE>
- *
- * @version $Id: IFNE.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFNE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFNE() {}
-
- public IFNE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFNE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFEQ(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFNE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFNONNULL - Branch if reference is not null
- *
- * <PRE>Stack: ..., reference -> ...</PRE>
- *
- * @version $Id: IFNONNULL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFNONNULL extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFNONNULL() {}
-
- public IFNONNULL(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFNONNULL, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFNULL(target);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFNONNULL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IFNULL - Branch if reference is not null
- *
- * <PRE>Stack: ..., reference -> ...</PRE>
- *
- * @version $Id: IFNULL.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IFNULL extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IFNULL() {}
-
- public IFNULL(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IFNULL, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IFNONNULL(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIFNULL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ACMPEQ - Branch if reference comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ACMPEQ.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ACMPEQ extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ACMPEQ() {}
-
- public IF_ACMPEQ(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ACMPEQ, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ACMPNE(target);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ACMPEQ(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ACMPNE - Branch if reference comparison doesn't succeed
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ACMPNE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ACMPNE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ACMPNE() {}
-
- public IF_ACMPNE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ACMPNE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ACMPEQ(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ACMPNE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPEQ - Branch if int comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPEQ.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPEQ extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPEQ() {}
-
- public IF_ICMPEQ(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPEQ, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPNE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPEQ(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPGE - Branch if int comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPGE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPGE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPGE() {}
-
- public IF_ICMPGE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPGE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPLT(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPGE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPGT - Branch if int comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPGT.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPGT extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPGT() {}
-
- public IF_ICMPGT(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPGT, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPLE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPGT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPLE - Branch if int comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPLE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPLE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPLE() {}
-
- public IF_ICMPLE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPLE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPGT(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPLE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPLT - Branch if int comparison succeeds
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPLT.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPLT extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPLT() {}
-
- public IF_ICMPLT(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPLT, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPGE(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPLT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IF_ICMPNE - Branch if int comparison doesn't succeed
- *
- * <PRE>Stack: ..., value1, value2 -> ...</PRE>
- *
- * @version $Id: IF_ICMPNE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IF_ICMPNE extends IfInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IF_ICMPNE() {}
-
- public IF_ICMPNE(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.IF_ICMPNE, target);
- }
-
- /**
- * @return negation of instruction
- */
- public IfInstruction negate() {
- return new IF_ICMPEQ(target);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitBranchInstruction(this);
- v.visitIfInstruction(this);
- v.visitIF_ICMPNE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ILOAD - Load int from local variable onto stack
- * <PRE>Stack: ... -> ..., result</PRE>
- *
- * @version $Id: ILOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ILOAD extends LoadInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ILOAD() {
- super(org.aspectj.apache.bcel.Constants.ILOAD, org.aspectj.apache.bcel.Constants.ILOAD_0);
- }
-
- /** Load int from local variable
- * @param n index of local variable
- */
- public ILOAD(int n) {
- super(org.aspectj.apache.bcel.Constants.ILOAD, org.aspectj.apache.bcel.Constants.ILOAD_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitILOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IMPDEP1 - Implementation dependent
- *
- * @version $Id: IMPDEP1.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IMPDEP1 extends Instruction {
- public IMPDEP1() {
- super(org.aspectj.apache.bcel.Constants.IMPDEP1, (short)1);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitIMPDEP1(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IMPDEP2 - Implementation dependent
- *
- * @version $Id: IMPDEP2.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IMPDEP2 extends Instruction {
- public IMPDEP2() {
- super(org.aspectj.apache.bcel.Constants.IMPDEP2, (short)1);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitIMPDEP2(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IMUL - Multiply ints
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: IMUL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IMUL extends ArithmeticInstruction {
- /** Multiply ints
- */
- public IMUL() {
- super(org.aspectj.apache.bcel.Constants.IMUL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIMUL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * INEG - Negate int
- * <PRE>Stack: ..., value -> ..., result</PRE>
- *
- * @version $Id: INEG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class INEG extends ArithmeticInstruction {
- public INEG() {
- super(org.aspectj.apache.bcel.Constants.INEG);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitINEG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * INSTANCEOF - Determine if object is of given type
- * <PRE>Stack: ..., objectref -> ..., result</PRE>
- *
- * @version $Id: INSTANCEOF.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class INSTANCEOF extends CPInstruction
- implements LoadClass, ExceptionThrower, StackProducer, StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- INSTANCEOF() {}
-
- public INSTANCEOF(int index) {
- super(org.aspectj.apache.bcel.Constants.INSTANCEOF, index);
- }
-
- public Class[] getExceptions() {
- return org.aspectj.apache.bcel.ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION;
- }
-
- public ObjectType getLoadClassType(ConstantPoolGen cpg) {
- Type t = getType(cpg);
-
- if(t instanceof ArrayType)
- t = ((ArrayType) t).getBasicType();
-
- return (t instanceof ObjectType)? (ObjectType) t : null;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitLoadClass(this);
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitINSTANCEOF(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * INVOKESPECIAL - Invoke instance method; special handling for superclass, private
- * and instance initialization method invocations
- *
- * <PRE>Stack: ..., objectref, [arg1, [arg2 ...]] -> ...</PRE>
- *
- * @version $Id: INVOKESPECIAL.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class INVOKESPECIAL extends InvokeInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- INVOKESPECIAL() {}
-
- public INVOKESPECIAL(int index) {
- super(Constants.INVOKESPECIAL, index);
- }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[4 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+3] = ExceptionConstants.UNSATISFIED_LINK_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+2] = ExceptionConstants.ABSTRACT_METHOD_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+1] = ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] = ExceptionConstants.NULL_POINTER_EXCEPTION;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitStackProducer(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitInvokeInstruction(this);
- v.visitINVOKESPECIAL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * INVOKESTATIC - Invoke a class (static) method
- *
- * <PRE>Stack: ..., [arg1, [arg2 ...]] -> ...</PRE>
- *
- * @version $Id: INVOKESTATIC.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class INVOKESTATIC extends InvokeInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- INVOKESTATIC() {}
-
- public INVOKESTATIC(int index) {
- super(Constants.INVOKESTATIC, index);
- }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[2 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] = ExceptionConstants.UNSATISFIED_LINK_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+1] = ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitStackProducer(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitInvokeInstruction(this);
- v.visitINVOKESTATIC(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * INVOKEVIRTUAL - Invoke instance method; dispatch based on class
- *
- * <PRE>Stack: ..., objectref, [arg1, [arg2 ...]] -> ...</PRE>
- *
- * @version $Id: INVOKEVIRTUAL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class INVOKEVIRTUAL extends InvokeInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- INVOKEVIRTUAL() {}
-
- public INVOKEVIRTUAL(int index) {
- super(Constants.INVOKEVIRTUAL, index);
- }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[4 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+3] = ExceptionConstants.UNSATISFIED_LINK_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+2] = ExceptionConstants.ABSTRACT_METHOD_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+1] = ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] = ExceptionConstants.NULL_POINTER_EXCEPTION;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitStackProducer(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitInvokeInstruction(this);
- v.visitINVOKEVIRTUAL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IOR - Bitwise OR int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: IOR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IOR extends ArithmeticInstruction {
- public IOR() {
- super(org.aspectj.apache.bcel.Constants.IOR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIOR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IREM - Remainder of int
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: IREM.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IREM extends ArithmeticInstruction implements ExceptionThrower {
- /** Remainder of ints
- */
- public IREM() {
- super(org.aspectj.apache.bcel.Constants.IREM);
- }
-
- /** @return exceptions this instruction may cause
- */
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.ARITHMETIC_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIREM(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IRETURN - Return int from method
- * <PRE>Stack: ..., value -> <empty></PRE>
- *
- * @version $Id: IRETURN.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IRETURN extends ReturnInstruction {
- /** Return int from method
- */
- public IRETURN() {
- super(org.aspectj.apache.bcel.Constants.IRETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitIRETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ISHL - Arithmetic shift left int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: ISHL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ISHL extends ArithmeticInstruction {
- public ISHL() {
- super(org.aspectj.apache.bcel.Constants.ISHL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitISHL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ISHR - Arithmetic shift right int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: ISHR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ISHR extends ArithmeticInstruction {
- public ISHR() {
- super(org.aspectj.apache.bcel.Constants.ISHR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitISHR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ISTORE - Store int from stack into local variable
- * <PRE>Stack: ..., value -> ... </PRE>
- *
- * @version $Id: ISTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ISTORE extends StoreInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ISTORE() {
- super(org.aspectj.apache.bcel.Constants.ISTORE, org.aspectj.apache.bcel.Constants.ISTORE_0);
- }
-
- /** Store int into local variable
- * @param n index of local variable
- */
- public ISTORE(int n) {
- super(org.aspectj.apache.bcel.Constants.ISTORE, org.aspectj.apache.bcel.Constants.ISTORE_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitISTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * ISUB - Substract ints
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: ISUB.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class ISUB extends ArithmeticInstruction {
- /** Substract ints
- */
- public ISUB() {
- super(org.aspectj.apache.bcel.Constants.ISUB);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitISUB(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IUSHR - Logical shift right int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: IUSHR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IUSHR extends ArithmeticInstruction {
- public IUSHR() {
- super(org.aspectj.apache.bcel.Constants.IUSHR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIUSHR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * IXOR - Bitwise XOR int
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: IXOR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class IXOR extends ArithmeticInstruction {
- public IXOR() {
- super(org.aspectj.apache.bcel.Constants.IXOR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitIXOR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Super class for the IFxxx family of instructions.
- *
- * @version $Id: IfInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class IfInstruction extends BranchInstruction implements StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- IfInstruction() {}
-
- /**
- * @param instruction Target instruction to branch to
- */
- protected IfInstruction(short opcode, InstructionHandle target) {
- super(opcode, target);
- }
-
- /**
- * @return negation of instruction, e.g. IFEQ.negate() == IFNE
- */
- public abstract IfInstruction negate();
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denote entity that refers to an index, e.g. local variable instructions,
- * RET, CPInstruction, etc.
- *
- * @version $Id: IndexedInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface IndexedInstruction {
- public int getIndex();
- public void setIndex(int index);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Implement this interface if you're interested in changes to an InstructionList object
- * and register yourself with addObserver().
- *
- * @version $Id: InstructionListObserver.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface InstructionListObserver {
- public void notify(InstructionList list);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-
-/**
- * JSR - Jump to subroutine
- *
- * @version $Id: JSR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class JSR extends JsrInstruction implements VariableLengthInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- JSR() {}
-
- public JSR(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.JSR, target);
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- index = getTargetOffset();
- if(opcode == org.aspectj.apache.bcel.Constants.JSR)
- super.dump(out);
- else { // JSR_W
- index = getTargetOffset();
- out.writeByte(opcode);
- out.writeInt(index);
- }
- }
-
- protected int updatePosition(int offset, int max_offset) {
- int i = getTargetOffset(); // Depending on old position value
-
- position += offset; // Position may be shifted by preceding expansions
-
- if(Math.abs(i) >= (32767 - max_offset)) { // to large for short (estimate)
- opcode = org.aspectj.apache.bcel.Constants.JSR_W;
- length = 5;
- return 2; // 5 - 3
- }
-
- return 0;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitVariableLengthInstruction(this);
- v.visitBranchInstruction(this);
- v.visitJsrInstruction(this);
- v.visitJSR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * JSR_W - Jump to subroutine
- *
- * @version $Id: JSR_W.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class JSR_W extends JsrInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- JSR_W() {}
-
- public JSR_W(InstructionHandle target) {
- super(org.aspectj.apache.bcel.Constants.JSR_W, target);
- length = 5;
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- index = getTargetOffset();
- out.writeByte(opcode);
- out.writeInt(index);
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- index = bytes.readInt();
- length = 5;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitBranchInstruction(this);
- v.visitJsrInstruction(this);
- v.visitJSR_W(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Super class for JSR - Jump to subroutine
- *
- * @version $Id: JsrInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class JsrInstruction extends BranchInstruction
- implements UnconditionalBranch, TypedInstruction, StackProducer
-{
- JsrInstruction(short opcode, InstructionHandle target) {
- super(opcode, target);
- }
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- JsrInstruction(){}
-
- /** @return return address type
- */
- public Type getType(ConstantPoolGen cp) {
- return new ReturnaddressType(physicalSuccessor());
- }
-
- /**
- * Returns an InstructionHandle to the physical successor
- * of this JsrInstruction. <B>For this method to work,
- * this JsrInstruction object must not be shared between
- * multiple InstructionHandle objects!</B>
- * Formally, there must not be InstructionHandle objects
- * i, j where i != j and i.getInstruction() == this ==
- * j.getInstruction().
- * @return an InstructionHandle to the "next" instruction that
- * will be executed when RETurned from a subroutine.
- */
- public InstructionHandle physicalSuccessor(){
- InstructionHandle ih = this.target;
-
- // Rewind!
- while(ih.getPrev() != null)
- ih = ih.getPrev();
-
- // Find the handle for "this" JsrInstruction object.
- while(ih.getInstruction() != this)
- ih = ih.getNext();
-
- InstructionHandle toThis = ih;
-
- while(ih != null){
- ih = ih.getNext();
- if ((ih != null) && (ih.getInstruction() == this))
- throw new RuntimeException("physicalSuccessor() called on a shared JsrInstruction.");
- }
-
- // Return the physical successor
- return toThis.getNext();
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * L2D - Convert long to double
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: L2D.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class L2D extends ConversionInstruction {
- public L2D() {
- super(org.aspectj.apache.bcel.Constants.L2D);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitL2D(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * L2F - Convert long to float
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result</PRE>
- *
- * @version $Id: L2F.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class L2F extends ConversionInstruction {
- public L2F() {
- super(org.aspectj.apache.bcel.Constants.L2F);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitL2F(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * L2I - Convert long to int
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result</PRE>
- *
- * @version $Id: L2I.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class L2I extends ConversionInstruction {
- public L2I() {
- super(org.aspectj.apache.bcel.Constants.L2I);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitConversionInstruction(this);
- v.visitL2I(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LADD - Add longs
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: LADD.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LADD extends ArithmeticInstruction {
- public LADD() {
- super(org.aspectj.apache.bcel.Constants.LADD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLADD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LALOAD - Load long from array
- * <PRE>Stack: ..., arrayref, index -> ..., value1, value2</PRE>
- *
- * @version $Id: LALOAD.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LALOAD extends ArrayInstruction implements StackProducer {
- /** Load long from array
- */
- public LALOAD() {
- super(org.aspectj.apache.bcel.Constants.LALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitLALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LAND - Bitwise AND longs
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: LAND.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LAND extends ArithmeticInstruction {
- public LAND() {
- super(org.aspectj.apache.bcel.Constants.LAND);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLAND(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LASTORE - Store into long array
- * <PRE>Stack: ..., arrayref, index, value.word1, value.word2 -> ...</PRE>
- *
- * @version $Id: LASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LASTORE extends ArrayInstruction implements StackConsumer {
- /** Store long into array
- */
- public LASTORE() {
- super(org.aspectj.apache.bcel.Constants.LASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitLASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LCMP - Compare longs:
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result <= -1, 0, 1>
- *
- * @version $Id: LCMP.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LCMP extends Instruction
- implements TypedInstruction, StackProducer, StackConsumer
-{
- public LCMP() {
- super(org.aspectj.apache.bcel.Constants.LCMP, (short)1);
- }
-
- /** @return Type.LONG
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.LONG;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitLCMP(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LCONST - Push 0 or 1, other values cause an exception
- *
- * <PRE>Stack: ... -> ..., </PRE>
- *
- * @version $Id: LCONST.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LCONST extends Instruction
- implements ConstantPushInstruction, TypedInstruction {
- private long value;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LCONST() {}
-
- public LCONST(long l) {
- super(org.aspectj.apache.bcel.Constants.LCONST_0, (short)1);
-
- if(l == 0)
- opcode = org.aspectj.apache.bcel.Constants.LCONST_0;
- else if(l == 1)
- opcode = org.aspectj.apache.bcel.Constants.LCONST_1;
- else
- throw new ClassGenException("LCONST can be used only for 0 and 1: " + l);
-
- value = l;
- }
-
- public Number getValue() { return new Long(value); }
-
- /** @return Type.LONG
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.LONG;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitLCONST(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * LDC - Push item from constant pool.
- *
- * <PRE>Stack: ... -> ..., item</PRE>
- *
- * @version $Id: LDC.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LDC extends CPInstruction
- implements PushInstruction, ExceptionThrower, TypedInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LDC() {}
-
- public LDC(int index) {
- super(org.aspectj.apache.bcel.Constants.LDC_W, index);
- setSize();
- }
-
- // Adjust to proper size
- protected final void setSize() {
- if(index <= org.aspectj.apache.bcel.Constants.MAX_BYTE) { // Fits in one byte?
- opcode = org.aspectj.apache.bcel.Constants.LDC;
- length = 2;
- } else {
- opcode = org.aspectj.apache.bcel.Constants.LDC_W;
- length = 3;
- }
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- out.writeByte(opcode);
-
- if(length == 2)
- out.writeByte(index);
- else // Applies for LDC_W
- out.writeShort(index);
- }
-
- /**
- * Set the index to constant pool and adjust size.
- */
- public final void setIndex(int index) {
- super.setIndex(index);
- setSize();
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide)
- throws IOException
- {
- length = 2;
- index = bytes.readUnsignedByte();
- }
-
- public Object getValue(ConstantPoolGen cpg) {
- org.aspectj.apache.bcel.classfile.Constant c = cpg.getConstantPool().getConstant(index);
-
- switch(c.getTag()) {
- case org.aspectj.apache.bcel.Constants.CONSTANT_String:
- int i = ((org.aspectj.apache.bcel.classfile.ConstantString)c).getStringIndex();
- c = cpg.getConstantPool().getConstant(i);
- return ((org.aspectj.apache.bcel.classfile.ConstantUtf8)c).getBytes();
-
- case org.aspectj.apache.bcel.Constants.CONSTANT_Float:
- return new Float(((org.aspectj.apache.bcel.classfile.ConstantFloat)c).getBytes());
-
- case org.aspectj.apache.bcel.Constants.CONSTANT_Integer:
- return new Integer(((org.aspectj.apache.bcel.classfile.ConstantInteger)c).getBytes());
-
- default: // Never reached
- throw new RuntimeException("Unknown or invalid constant type at " + index);
- }
- }
-
- public Type getType(ConstantPoolGen cpg) {
- switch(cpg.getConstantPool().getConstant(index).getTag()) {
- case org.aspectj.apache.bcel.Constants.CONSTANT_String: return Type.STRING;
- case org.aspectj.apache.bcel.Constants.CONSTANT_Float: return Type.FLOAT;
- case org.aspectj.apache.bcel.Constants.CONSTANT_Integer: return Type.INT;
- default: // Never reached
- throw new RuntimeException("Unknown or invalid constant type at " + index);
- }
- }
-
- public Class[] getExceptions() {
- return org.aspectj.apache.bcel.ExceptionConstants.EXCS_STRING_RESOLUTION;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitLDC(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LDC2_W - Push long or double from constant pool
- *
- * <PRE>Stack: ... -> ..., item.word1, item.word2</PRE>
- *
- * @version $Id: LDC2_W.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LDC2_W extends CPInstruction
- implements PushInstruction, TypedInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LDC2_W() {}
-
- public LDC2_W(int index) {
- super(org.aspectj.apache.bcel.Constants.LDC2_W, index);
- }
-
- public Type getType(ConstantPoolGen cpg) {
- switch(cpg.getConstantPool().getConstant(index).getTag()) {
- case org.aspectj.apache.bcel.Constants.CONSTANT_Long: return Type.LONG;
- case org.aspectj.apache.bcel.Constants.CONSTANT_Double: return Type.DOUBLE;
- default: // Never reached
- throw new RuntimeException("Unknown constant type " + opcode);
- }
- }
-
- public Number getValue(ConstantPoolGen cpg) {
- org.aspectj.apache.bcel.classfile.Constant c = cpg.getConstantPool().getConstant(index);
-
- switch(c.getTag()) {
- case org.aspectj.apache.bcel.Constants.CONSTANT_Long:
- return new Long(((org.aspectj.apache.bcel.classfile.ConstantLong)c).getBytes());
-
- case org.aspectj.apache.bcel.Constants.CONSTANT_Double:
- return new Double(((org.aspectj.apache.bcel.classfile.ConstantDouble)c).getBytes());
-
- default: // Never reached
- throw new RuntimeException("Unknown or invalid constant type at " + index);
- }
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitLDC2_W(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.IOException;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * LDC_W - Push item from constant pool (wide index)
- *
- * <PRE>Stack: ... -> ..., item.word1, item.word2</PRE>
- *
- * @version $Id: LDC_W.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LDC_W extends LDC {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LDC_W() {}
-
- public LDC_W(int index) {
- super(index);
- }
-
- /**
- * Read needed data (i.e., index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide)
- throws IOException
- {
- setIndex(bytes.readUnsignedShort());
- // Override just in case it has been changed
- // opcode = org.aspectj.apache.bcel.Constants.LDC_W;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LDIV - Divide longs
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: LDIV.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LDIV extends ArithmeticInstruction implements ExceptionThrower {
- public LDIV() {
- super(org.aspectj.apache.bcel.Constants.LDIV);
- }
-
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.ARITHMETIC_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLDIV(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LLOAD - Load long from local variable
- *<PRE>Stack ... -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: LLOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LLOAD extends LoadInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LLOAD() {
- super(org.aspectj.apache.bcel.Constants.LLOAD, org.aspectj.apache.bcel.Constants.LLOAD_0);
- }
-
- public LLOAD(int n) {
- super(org.aspectj.apache.bcel.Constants.LLOAD, org.aspectj.apache.bcel.Constants.LLOAD_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitLLOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LMUL - Multiply longs
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: LMUL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LMUL extends ArithmeticInstruction {
- public LMUL() {
- super(org.aspectj.apache.bcel.Constants.LMUL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLMUL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LNEG - Negate long
- * <PRE>Stack: ..., value.word1, value.word2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: LNEG.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LNEG extends ArithmeticInstruction {
- public LNEG() {
- super(org.aspectj.apache.bcel.Constants.LNEG);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLNEG(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LOR - Bitwise OR long
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: LOR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LOR extends ArithmeticInstruction {
- public LOR() {
- super(org.aspectj.apache.bcel.Constants.LOR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLOR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LREM - Remainder of long
- * <PRE>Stack: ..., value1, value2 -> result</PRE>
- *
- * @version $Id: LREM.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LREM extends ArithmeticInstruction implements ExceptionThrower {
- public LREM() {
- super(org.aspectj.apache.bcel.Constants.LREM);
- }
-
- public Class[] getExceptions() { return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.ARITHMETIC_EXCEPTION }; }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLREM(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LRETURN - Return long from method
- * <PRE>Stack: ..., value.word1, value.word2 -> <empty></PRE>
- *
- * @version $Id: LRETURN.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LRETURN extends ReturnInstruction {
- public LRETURN() {
- super(org.aspectj.apache.bcel.Constants.LRETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitLRETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LSHL - Arithmetic shift left long
- * <PRE>Stack: ..., value1.word1, value1.word2, value2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: LSHL.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LSHL extends ArithmeticInstruction {
- public LSHL() {
- super(org.aspectj.apache.bcel.Constants.LSHL);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLSHL(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LSHR - Arithmetic shift right long
- * <PRE>Stack: ..., value1.word1, value1.word2, value2 -> ..., result.word1, result.word2</PRE>
- *
- * @version $Id: LSHR.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LSHR extends ArithmeticInstruction {
- public LSHR() {
- super(org.aspectj.apache.bcel.Constants.LSHR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLSHR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LSTORE - Store long into local variable
- * <PRE>Stack: ..., value.word1, value.word2 -> ... </PRE>
- *
- * @version $Id: LSTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LSTORE extends StoreInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- LSTORE() {
- super(org.aspectj.apache.bcel.Constants.LSTORE, org.aspectj.apache.bcel.Constants.LSTORE_0);
- }
-
- public LSTORE(int n) {
- super(org.aspectj.apache.bcel.Constants.LSTORE, org.aspectj.apache.bcel.Constants.LSTORE_0, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- super.accept(v);
- v.visitLSTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LSUB - Substract longs
- * <PRE>Stack: ..., value1.word1, value1.word2, value2.word1, value2.word2 -></PRE>
- * ..., result.word1, result.word2
- *
- * @version $Id: LSUB.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LSUB extends ArithmeticInstruction {
- public LSUB() {
- super(org.aspectj.apache.bcel.Constants.LSUB);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLSUB(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LUSHR - Logical shift right long
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: LUSHR.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LUSHR extends ArithmeticInstruction {
- public LUSHR() {
- super(org.aspectj.apache.bcel.Constants.LUSHR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLUSHR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * LXOR - Bitwise XOR long
- * <PRE>Stack: ..., value1, value2 -> ..., result</PRE>
- *
- * @version $Id: LXOR.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class LXOR extends ArithmeticInstruction {
- public LXOR() {
- super(org.aspectj.apache.bcel.Constants.LXOR);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitTypedInstruction(this);
- v.visitStackProducer(this);
- v.visitStackConsumer(this);
- v.visitArithmeticInstruction(this);
- v.visitLXOR(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes that an instruction may start the process of loading and resolving
- * the referenced class in the Virtual Machine.
- *
- * @version $Id: LoadClass.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface LoadClass {
- /**
- * Returns the ObjectType of the referenced class or interface
- * that may be loaded and resolved.
- * @return object type that may be loaded or null if a primitive is
- * referenced
- */
- public ObjectType getLoadClassType(ConstantPoolGen cpg);
-
- /**
- * Returns the type associated with this instruction.
- * LoadClass instances are always typed, but this type
- * does not always refer to the type of the class or interface
- * that it possibly forces to load. For example, GETFIELD would
- * return the type of the field and not the type of the class
- * where the field is defined.
- * If no class is forced to be loaded, <B>null</B> is returned.
- * An example for this is an ANEWARRAY instruction that creates
- * an int[][].
- * @see #getLoadClassType(ConstantPoolGen)
- */
- public Type getType(ConstantPoolGen cpg);
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an unparameterized instruction to load a value from a local
- * variable, e.g. ILOAD.
- *
- * @version $Id: LoadInstruction.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class LoadInstruction extends LocalVariableInstruction
- implements PushInstruction
-{
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- * tag and length are defined in readInstruction and initFromFile, respectively.
- */
- LoadInstruction(short canon_tag, short c_tag) {
- super(canon_tag, c_tag);
- }
-
- /**
- * @param opcode Instruction opcode
- * @param c_tag Instruction number for compact version, ALOAD_0, e.g.
- * @param n local variable index (unsigned short)
- */
- protected LoadInstruction(short opcode, short c_tag, int n) {
- super(opcode, c_tag, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitPushInstruction(this);
- v.visitTypedInstruction(this);
- v.visitLocalVariableInstruction(this);
- v.visitLoadInstruction(this);
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * Abstract super class for instructions dealing with local variables.
- *
- * @version $Id: LocalVariableInstruction.java,v 1.5 2006/11/29 13:43:01 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class LocalVariableInstruction extends Instruction
- implements TypedInstruction, IndexedInstruction {
- protected int n = -1; // index of referenced variable
- private short c_tag = -1; // compact version, such as ILOAD_0
- private short canon_tag = -1; // canonical tag such as ILOAD
-
- private final boolean wide() { return n > Constants.MAX_BYTE; }
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- * tag and length are defined in readInstruction and initFromFile, respectively.
- */
- LocalVariableInstruction(short canon_tag, short c_tag) {
- super();
- this.canon_tag = canon_tag;
- this.c_tag = c_tag;
- }
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Also used by IINC()!
- */
- LocalVariableInstruction() {
- }
-
- /**
- * @param opcode Instruction opcode
- * @param c_tag Instruction number for compact version, ALOAD_0, e.g.
- * @param n local variable index (unsigned short)
- */
- protected LocalVariableInstruction(short opcode, short c_tag, int n) {
- super(opcode, (short)2);
-
- this.c_tag = c_tag;
- canon_tag = opcode;
-
- setIndex(n);
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- if(wide()) // Need WIDE prefix ?
- out.writeByte(Constants.WIDE);
-
- out.writeByte(opcode);
-
- if(length > 1) { // Otherwise ILOAD_n, instruction, e.g.
- if(wide())
- out.writeShort(n);
- else
- out.writeByte(n);
- }
- }
-
- /**
- * Long output format:
- *
- * <name of opcode> "["<opcode number>"]"
- * "("<length of instruction>")" "<"< local variable index>">"
- *
- * @param verbose long/short format switch
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- if(((opcode >= Constants.ILOAD_0) &&
- (opcode <= Constants.ALOAD_3)) ||
- ((opcode >= Constants.ISTORE_0) &&
- (opcode <= Constants.ASTORE_3)))
- return super.toString(verbose);
- else
- return super.toString(verbose) + " " + n;
- }
-
- /**
- * Read needed data (e.g. index) from file.
- * PRE: (ILOAD <= tag <= ALOAD_3) || (ISTORE <= tag <= ASTORE_3)
- */
- protected void initFromFile(ByteSequence bytes, boolean wide)
- throws IOException
- {
- if(wide) {
- n = bytes.readUnsignedShort();
- } else if(((opcode >= Constants.ILOAD) &&
- (opcode <= Constants.ALOAD)) ||
- ((opcode >= Constants.ISTORE) &&
- (opcode <= Constants.ASTORE))) {
- n = bytes.readUnsignedByte();
- } else if(opcode <= Constants.ALOAD_3) { // compact load instruction such as ILOAD_2
- n = (opcode - Constants.ILOAD_0) % 4;
- } else { // Assert ISTORE_0 <= tag <= ASTORE_3
- n = (opcode - Constants.ISTORE_0) % 4;
- }
- workOutLength();
- }
-
- private void workOutLength() {
- if(n >= 0 && n <= 3) { // Use more compact instruction xLOAD_n
- opcode = (short)(c_tag + n);
- length = 1;
- } else {
- opcode = canon_tag;
- if(wide()) length = 4;
- else length = 2;
- }
- }
-
- /**
- * @return local variable index referred by this instruction.
- */
- public final int getIndex() { return n; }
-
- /**
- * Set the local variable index
- */
- public void setIndex(int n) {
- if((n < 0) || (n > Constants.MAX_SHORT))
- throw new ClassGenException("Illegal value: " + n);
-
- this.n = n;
- workOutLength();
- }
-
- /** @return canonical tag for instruction, e.g., ALOAD for ALOAD_0
- */
- public short getCanonicalTag() {
- return canon_tag;
- }
-
- /**
- * Returns the type associated with the instruction -
- * in case of ALOAD or ASTORE Type.OBJECT is returned.
- * This is just a bit incorrect, because ALOAD and ASTORE
- * may work on every ReferenceType (including Type.NULL) and
- * ASTORE may even work on a ReturnaddressType .
- * @return type associated with the instruction
- */
- public Type getType(ConstantPoolGen cp) {
- switch(canon_tag) {
- case Constants.ILOAD: case Constants.ISTORE:
- return Type.INT;
- case Constants.LLOAD: case Constants.LSTORE:
- return Type.LONG;
- case Constants.DLOAD: case Constants.DSTORE:
- return Type.DOUBLE;
- case Constants.FLOAD: case Constants.FSTORE:
- return Type.FLOAT;
- case Constants.ALOAD: case Constants.ASTORE:
- return Type.OBJECT;
-
- default: throw new ClassGenException("Oops: unknown case in switch" + canon_tag);
- }
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * MONITORENTER - Enter monitor for object
- * <PRE>Stack: ..., objectref -> ...</PRE>
- *
- * @version $Id: MONITORENTER.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class MONITORENTER extends Instruction
- implements ExceptionThrower, StackConsumer {
- public MONITORENTER() {
- super(org.aspectj.apache.bcel.Constants.MONITORENTER, (short)1);
- }
-
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.NULL_POINTER_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackConsumer(this);
- v.visitMONITORENTER(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * MONITOREXIT - Exit monitor for object
- * <PRE>Stack: ..., objectref -> ...</PRE>
- *
- * @version $Id: MONITOREXIT.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class MONITOREXIT extends Instruction
- implements ExceptionThrower, StackConsumer {
- public MONITOREXIT() {
- super(org.aspectj.apache.bcel.Constants.MONITOREXIT, (short)1);
- }
-
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.NULL_POINTER_EXCEPTION };
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackConsumer(this);
- v.visitMONITOREXIT(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Implement this interface if you're interested in changes to a MethodGen object
- * and register yourself with addObserver().
- *
- * @version $Id: MethodObserver.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface MethodObserver {
- public void notify(MethodGen method);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * NEW - Create new object
- * <PRE>Stack: ... -> ..., objectref</PRE>
- *
- * @version $Id: NEW.java,v 1.4 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class NEW extends CPInstruction
- implements LoadClass, AllocationInstruction, ExceptionThrower, StackProducer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- NEW() {}
-
- public NEW(int index) {
- super(org.aspectj.apache.bcel.Constants.NEW, index);
- }
-
- public Class[] getExceptions(){
- Class[] cs = new Class[2 + ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length+1] = ExceptionConstants.INSTANTIATION_ERROR;
- cs[ExceptionConstants.EXCS_CLASS_AND_INTERFACE_RESOLUTION.length] = ExceptionConstants.ILLEGAL_ACCESS_ERROR;
-
- return cs;
- }
-
- public ObjectType getLoadClassType(ConstantPoolGen cpg) {
- return (ObjectType)getType(cpg);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitLoadClass(this);
- v.visitAllocationInstruction(this);
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitCPInstruction(this);
- v.visitNEW(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * NEWARRAY - Create new array of basic type (int, short, ...)
- * <PRE>Stack: ..., count -> ..., arrayref</PRE>
- * type must be one of T_INT, T_SHORT, ...
- *
- * @version $Id: NEWARRAY.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class NEWARRAY extends Instruction
- implements AllocationInstruction, ExceptionThrower, StackProducer {
- private byte type;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- NEWARRAY() {}
-
- public NEWARRAY(byte type) {
- super(org.aspectj.apache.bcel.Constants.NEWARRAY, (short)2);
- this.type = type;
- }
-
- public NEWARRAY(BasicType type) {
- this(type.getType());
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- out.writeByte(opcode);
- out.writeByte(type);
- }
-
- /**
- * @return numeric code for basic element type
- */
- public final byte getTypecode() { return type; }
-
- /**
- * @return type of constructed array
- */
- public final Type getType() {
- return new ArrayType(BasicType.getType(type), 1);
- }
-
- /**
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- return super.toString(verbose) + " " + org.aspectj.apache.bcel.Constants.TYPE_NAMES[type];
- }
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- type = bytes.readByte();
- length = 2;
- }
-
- public Class[] getExceptions() {
- return new Class[] { org.aspectj.apache.bcel.ExceptionConstants.NEGATIVE_ARRAY_SIZE_EXCEPTION };
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitAllocationInstruction(this);
- v.visitExceptionThrower(this);
- v.visitStackProducer(this);
- v.visitNEWARRAY(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * NOP - Do nothing
- *
- * @version $Id: NOP.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class NOP extends Instruction {
- public NOP() {
- super(org.aspectj.apache.bcel.Constants.NOP, (short)1);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitNOP(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * POP - Pop top operand stack word
- *
- * <PRE>Stack: ..., word -> ...</PRE>
- *
- * @version $Id: POP.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class POP extends StackInstruction implements PopInstruction {
- public POP() {
- super(org.aspectj.apache.bcel.Constants.POP);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitPopInstruction(this);
- v.visitStackInstruction(this);
- v.visitPOP(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * POP2 - Pop two top operand stack words
- *
- * <PRE>Stack: ..., word2, word1 -> ...</PRE>
- *
- * @version $Id: POP2.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class POP2 extends StackInstruction implements PopInstruction {
- public POP2() {
- super(org.aspectj.apache.bcel.Constants.POP2);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitPopInstruction(this);
- v.visitStackInstruction(this);
- v.visitPOP2(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-
-/**
- * Wrapper class for push operations, which are implemented either as BIPUSH,
- * LDC or xCONST_n instructions.
- *
- * @version $Id: PUSH.java,v 1.5 2005/01/31 11:32:21 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public final class PUSH
- implements CompoundInstruction, VariableLengthInstruction, InstructionConstants
-{
- private Instruction instruction;
-
- /**
- * This constructor also applies for values of type short, char, byte
- *
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, int value) {
- if((value >= -1) && (value <= 5)) // Use ICONST_n
- instruction = INSTRUCTIONS[Constants.ICONST_0 + value];
- else if((value >= -128) && (value <= 127)) // Use BIPUSH
- instruction = new BIPUSH((byte)value);
- else if((value >= -32768) && (value <= 32767)) // Use SIPUSH
- instruction = new SIPUSH((short)value);
- else // If everything fails create a Constant pool entry
- instruction = new LDC(cp.addInteger(value));
- }
-
- public PUSH(ConstantPoolGen cp, ObjectType t) {
- instruction = new LDC_W(cp.addClass(t));
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, boolean value) {
- instruction = INSTRUCTIONS[Constants.ICONST_0 + (value? 1 : 0)];
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, float value) {
- if(value == 0.0)
- instruction = FCONST_0;
- else if(value == 1.0)
- instruction = FCONST_1;
- else if(value == 2.0)
- instruction = FCONST_2;
- else // Create a Constant pool entry
- instruction = new LDC(cp.addFloat(value));
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, long value) {
- if(value == 0)
- instruction = LCONST_0;
- else if(value == 1)
- instruction = LCONST_1;
- else // Create a Constant pool entry
- instruction = new LDC2_W(cp.addLong(value));
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, double value) {
- if(value == 0.0)
- instruction = DCONST_0;
- else if(value == 1.0)
- instruction = DCONST_1;
- else // Create a Constant pool entry
- instruction = new LDC2_W(cp.addDouble(value));
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, String value) {
- if(value == null)
- instruction = ACONST_NULL;
- else // Create a Constant pool entry
- instruction = new LDC(cp.addString(value));
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, Number value) {
- if((value instanceof Integer) || (value instanceof Short) || (value instanceof Byte))
- instruction = new PUSH(cp, value.intValue()).instruction;
- else if(value instanceof Double)
- instruction = new PUSH(cp, value.doubleValue()).instruction;
- else if(value instanceof Float)
- instruction = new PUSH(cp, value.floatValue()).instruction;
- else if(value instanceof Long)
- instruction = new PUSH(cp, value.longValue()).instruction;
- else
- throw new ClassGenException("What's this: " + value);
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, Character value) {
- this(cp, (int)value.charValue());
- }
-
- /**
- * @param cp Constant pool
- * @param value to be pushed
- */
- public PUSH(ConstantPoolGen cp, Boolean value) {
- this(cp, value.booleanValue());
- }
-
- public final InstructionList getInstructionList() {
- return new InstructionList(instruction);
- }
-
- public final Instruction getInstruction() {
- return instruction;
- }
-
- /**
- * @return mnemonic for instruction
- */
- public String toString() {
- return instruction.toString() + " (PUSH)";
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * PUTFIELD - Put field in object
- * <PRE>Stack: ..., objectref, value -> ...</PRE>
- * OR
- * <PRE>Stack: ..., objectref, value.word1, value.word2 -> ...</PRE>
- *
- * @version $Id: PUTFIELD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class PUTFIELD
- extends FieldInstruction
- implements PopInstruction,ExceptionThrower{
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- PUTFIELD() {}
-
- public PUTFIELD(int index) {
- super(Constants.PUTFIELD, index);
- }
-
- public int consumeStack(ConstantPoolGen cpg) { return getFieldSize(cpg) + 1; }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[2 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
-
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length+1] =
- ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] =
- ExceptionConstants.NULL_POINTER_EXCEPTION;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackConsumer(this);
- v.visitPopInstruction(this);
- v.visitTypedInstruction(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitFieldInstruction(this);
- v.visitPUTFIELD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * PUTSTATIC - Put static field in class
- * <PRE>Stack: ..., value -> ...</PRE>
- * OR
- * <PRE>Stack: ..., value.word1, value.word2 -> ...</PRE>
- *
- * @version $Id: PUTSTATIC.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class PUTSTATIC extends FieldInstruction
- implements ExceptionThrower, PopInstruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- PUTSTATIC() {}
-
- public PUTSTATIC(int index) {
- super(Constants.PUTSTATIC, index);
- }
-
- public int consumeStack(ConstantPoolGen cpg) { return getFieldSize(cpg); }
-
- public Class[] getExceptions() {
- Class[] cs = new Class[1 + ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length];
-
- System.arraycopy(ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION, 0,
- cs, 0, ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length);
- cs[ExceptionConstants.EXCS_FIELD_AND_METHOD_RESOLUTION.length] =
- ExceptionConstants.INCOMPATIBLE_CLASS_CHANGE_ERROR;
-
- return cs;
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitStackConsumer(this);
- v.visitPopInstruction(this);
- v.visitTypedInstruction(this);
- v.visitLoadClass(this);
- v.visitCPInstruction(this);
- v.visitFieldOrMethod(this);
- v.visitFieldInstruction(this);
- v.visitPUTSTATIC(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an unparameterized instruction to pop a value on top from the stack,
- * such as ISTORE, POP, PUTSTATIC.
- *
- * @version $Id: PopInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see ISTORE
- * @see POP
- */
-public interface PopInstruction extends StackConsumer {
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an unparameterized instruction to produce a value on top of the stack,
- * such as ILOAD, LDC, SIPUSH, DUP, ICONST, etc.
- *
- * @version $Id: PushInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
-
- * @see ILOAD
- * @see ICONST
- * @see LDC
- * @see DUP
- * @see SIPUSH
- * @see GETSTATIC
- */
-public interface PushInstruction extends StackProducer {
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * RETURN - Return from void method
- * <PRE>Stack: ... -> <empty></PRE>
- *
- * @version $Id: RETURN.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class RETURN extends ReturnInstruction {
- public RETURN() {
- super(org.aspectj.apache.bcel.Constants.RETURN);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitStackConsumer(this);
- v.visitReturnInstruction(this);
- v.visitRETURN(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.ExceptionConstants;
-
-/**
- * Super class for the xRETURN family of instructions.
- *
- * @version $Id: ReturnInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class ReturnInstruction extends Instruction
- implements ExceptionThrower, TypedInstruction, StackConsumer {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- ReturnInstruction() {}
-
- /**
- * @param opcode of instruction
- */
- protected ReturnInstruction(short opcode) {
- super(opcode, (short)1);
- }
-
- public Type getType() {
- switch(opcode) {
- case Constants.IRETURN: return Type.INT;
- case Constants.LRETURN: return Type.LONG;
- case Constants.FRETURN: return Type.FLOAT;
- case Constants.DRETURN: return Type.DOUBLE;
- case Constants.ARETURN: return Type.OBJECT;
- case Constants.RETURN: return Type.VOID;
-
- default: // Never reached
- throw new ClassGenException("Unknown type " + opcode);
- }
- }
-
- public Class[] getExceptions() {
- return new Class[] { ExceptionConstants.ILLEGAL_MONITOR_STATE };
- }
-
- /** @return type associated with the instruction
- */
- public Type getType(ConstantPoolGen cp) {
- return getType();
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * SALOAD - Load short from array
- * <PRE>Stack: ..., arrayref, index -> ..., value</PRE>
- *
- * @version $Id: SALOAD.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class SALOAD extends ArrayInstruction implements StackProducer {
- public SALOAD() {
- super(org.aspectj.apache.bcel.Constants.SALOAD);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackProducer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitSALOAD(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * SASTORE - Store into short array
- * <PRE>Stack: ..., arrayref, index, value -> ...</PRE>
- *
- * @version $Id: SASTORE.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class SASTORE extends ArrayInstruction implements StackConsumer {
- public SASTORE() {
- super(org.aspectj.apache.bcel.Constants.SASTORE);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitExceptionThrower(this);
- v.visitTypedInstruction(this);
- v.visitArrayInstruction(this);
- v.visitSASTORE(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * SIPUSH - Push short
- *
- * <PRE>Stack: ... -> ..., value</PRE>
- *
- * @version $Id: SIPUSH.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class SIPUSH extends Instruction implements ConstantPushInstruction {
- private short b;
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- SIPUSH() {}
-
- public SIPUSH(short b) {
- super(org.aspectj.apache.bcel.Constants.SIPUSH, (short)3);
- this.b = b;
- }
-
- /**
- * Dump instruction as short code to stream out.
- */
- public void dump(DataOutputStream out) throws IOException {
- super.dump(out);
- out.writeShort(b);
- }
-
- /**
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- return super.toString(verbose) + " " + b;
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- length = 3;
- b = bytes.readShort();
- }
-
- public Number getValue() { return new Integer(b); }
-
- /** @return Type.SHORT
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.SHORT;
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitPushInstruction(this);
- v.visitStackProducer(this);
- v.visitTypedInstruction(this);
- v.visitConstantPushInstruction(this);
- v.visitSIPUSH(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * SWAP - Swa top operand stack word
- * <PRE>Stack: ..., word2, word1 -> ..., word1, word2</PRE>
- *
- * @version $Id: SWAP.java,v 1.2 2004/11/19 16:45:18 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public class SWAP extends StackInstruction implements StackConsumer, StackProducer {
- public SWAP() {
- super(org.aspectj.apache.bcel.Constants.SWAP);
- }
-
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitStackProducer(this);
- v.visitStackInstruction(this);
- v.visitSWAP(this);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * SWITCH - Branch depending on int value, generates either LOOKUPSWITCH or
- * TABLESWITCH instruction, depending on whether the match values (int[]) can be
- * sorted with no gaps between the numbers.
- *
- * @version $Id: SWITCH.java,v 1.4 2005/12/06 11:28:24 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public final class SWITCH implements CompoundInstruction {
- private int[] match;
- private InstructionHandle[] targets;
- private Select instruction;
- private int match_length;
-
- /**
- * Template for switch() constructs. If the match array can be
- * sorted in ascending order with gaps no larger than max_gap
- * between the numbers, a TABLESWITCH instruction is generated, and
- * a LOOKUPSWITCH otherwise. The former may be more efficient, but
- * needs more space.
- *
- * Note, that the key array always will be sorted, though we leave
- * the original arrays unaltered.
- *
- * @param match array of match values (case 2: ... case 7: ..., etc.)
- * @param targets the instructions to be branched to for each case
- * @param target the default target
- * @param max_gap maximum gap that may between case branches
- */
- public SWITCH(int[] match, InstructionHandle[] targets,
- InstructionHandle target, int max_gap) {
- this.match = (int[])match.clone();
- this.targets = (InstructionHandle[])targets.clone();
-
- if((match_length = match.length) < 2) // (almost) empty switch, or just default
- if (match.length==0) {
- instruction = new LOOKUPSWITCH(match,targets,target);
- } else {
- instruction = new TABLESWITCH(match,targets,target);
- }
- else {
- sort(0, match_length - 1);
-
- if(matchIsOrdered(max_gap)) {
- fillup(max_gap, target);
-
- instruction = new TABLESWITCH(this.match, this.targets, target);
- }
- else
- instruction = new LOOKUPSWITCH(this.match, this.targets, target);
- }
- }
-
- public SWITCH(int[] match, InstructionHandle[] targets,
- InstructionHandle target) {
- this(match, targets, target, 1);
- }
-
- private final void fillup(int max_gap, InstructionHandle target) {
- int max_size = match_length + match_length * max_gap;
- int[] m_vec = new int[max_size];
- InstructionHandle[] t_vec = new InstructionHandle[max_size];
- int count = 1;
-
- m_vec[0] = match[0];
- t_vec[0] = targets[0];
-
- for(int i=1; i < match_length; i++) {
- int prev = match[i-1];
- int gap = match[i] - prev;
-
- for(int j=1; j < gap; j++) {
- m_vec[count] = prev + j;
- t_vec[count] = target;
- count++;
- }
-
- m_vec[count] = match[i];
- t_vec[count] = targets[i];
- count++;
- }
-
- match = new int[count];
- targets = new InstructionHandle[count];
-
- System.arraycopy(m_vec, 0, match, 0, count);
- System.arraycopy(t_vec, 0, targets, 0, count);
- }
-
- /**
- * Sort match and targets array with QuickSort.
- */
- private final void sort(int l, int r) {
- int i = l, j = r;
- int h, m = match[(l + r) / 2];
- InstructionHandle h2;
-
- do {
- while(match[i] < m) i++;
- while(m < match[j]) j--;
-
- if(i <= j) {
- h=match[i]; match[i]=match[j]; match[j]=h; // Swap elements
- h2=targets[i]; targets[i]=targets[j]; targets[j]=h2; // Swap instructions, too
- i++; j--;
- }
- } while(i <= j);
-
- if(l < j) sort(l, j);
- if(i < r) sort(i, r);
- }
-
- /**
- * @return match is sorted in ascending order with no gap bigger than max_gap?
- */
- private final boolean matchIsOrdered(int max_gap) {
- for(int i=1; i < match_length; i++) {
- int diff = (match[i]-match[i-1]);
- if(diff > max_gap || diff<0) return false;
- }
- return true;
- }
-
- public final InstructionList getInstructionList() {
- return new InstructionList(instruction);
- }
-
- public final Instruction getInstruction() {
- return instruction;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.io.*;
-import org.aspectj.apache.bcel.util.ByteSequence;
-
-/**
- * Select - Abstract super class for LOOKUPSWITCH and TABLESWITCH instructions.
- *
- * @version $Id: Select.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see LOOKUPSWITCH
- * @see TABLESWITCH
- * @see InstructionList
- */
-public abstract class Select extends BranchInstruction
- implements VariableLengthInstruction, StackProducer
-{
- protected int[] match; // matches, i.e., case 1: ...
- protected int[] indices; // target offsets
- protected InstructionHandle[] targets; // target objects in instruction list
- protected int fixed_length; // fixed length defined by subclasses
- protected int match_length; // number of cases
- protected int padding = 0; // number of pad bytes for alignment
-
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- Select() {}
-
- /**
- * (Match, target) pairs for switch.
- * `Match' and `targets' must have the same length of course.
- *
- * @param match array of matching values
- * @param targets instruction targets
- * @param target default instruction target
- */
- Select(short opcode, int[] match, InstructionHandle[] targets,
- InstructionHandle target) {
- super(opcode, target);
-
- this.targets = targets;
- for(int i=0; i < targets.length; i++)
- notifyTarget(null, targets[i], this);
-
- this.match = match;
-
- if((match_length = match.length) != targets.length)
- throw new ClassGenException("Match and target array have not the same length");
-
- indices = new int[match_length];
- }
-
- /**
- * Since this is a variable length instruction, it may shift the following
- * instructions which then need to update their position.
- *
- * Called by InstructionList.setPositions when setting the position for every
- * instruction. In the presence of variable length instructions `setPositions'
- * performs multiple passes over the instruction list to calculate the
- * correct (byte) positions and offsets by calling this function.
- *
- * @param offset additional offset caused by preceding (variable length) instructions
- * @param max_offset the maximum offset that may be caused by these instructions
- * @return additional offset caused by possible change of this instruction's length
- */
- protected int updatePosition(int offset, int max_offset) {
- position += offset; // Additional offset caused by preceding SWITCHs, GOTOs, etc.
-
- short old_length = length;
-
- /* Alignment on 4-byte-boundary, + 1, because of tag byte.
- */
- padding = (4 - ((position + 1) % 4)) % 4;
- length = (short)(fixed_length + padding); // Update length
-
- return length - old_length;
- }
-
- /**
- * Dump instruction as byte code to stream out.
- * @param out Output stream
- */
- public void dump(DataOutputStream out) throws IOException {
- out.writeByte(opcode);
-
- for(int i=0; i < padding; i++) // Padding bytes
- out.writeByte(0);
-
- index = getTargetOffset(); // Write default target offset
- out.writeInt(index);
- }
-
- /**
- * Read needed data (e.g. index) from file.
- */
- protected void initFromFile(ByteSequence bytes, boolean wide) throws IOException
- {
- padding = (4 - (bytes.getIndex() % 4)) % 4; // Compute number of pad bytes
-
- for(int i=0; i < padding; i++) {
- bytes.readByte();
- }
-
- // Default branch target common for both cases (TABLESWITCH, LOOKUPSWITCH)
- index = bytes.readInt();
- }
-
- /**
- * @return mnemonic for instruction
- */
- public String toString(boolean verbose) {
- StringBuffer buf = new StringBuffer(super.toString(verbose));
-
- if(verbose) {
- for(int i=0; i < match_length; i++) {
- String s = "null";
-
- if(targets[i] != null)
- s = targets[i].getInstruction().toString();
-
- buf.append("(" + match[i] + ", " + s + " = {" + indices[i] + "})");
- }
- }
- else
- buf.append(" ...");
-
- return buf.toString();
- }
-
- /**
- * Set branch target for `i'th case
- */
- public void setTarget(int i, InstructionHandle target) {
- notifyTarget(targets[i], target, this);
- targets[i] = target;
- }
-
- /**
- * @param old_ih old target
- * @param new_ih new target
- */
- public void updateTarget(InstructionHandle old_ih, InstructionHandle new_ih) {
- boolean targeted = false;
-
- if(target == old_ih) {
- targeted = true;
- setTarget(new_ih);
- }
-
- for(int i=0; i < targets.length; i++) {
- if(targets[i] == old_ih) {
- targeted = true;
- setTarget(i, new_ih);
- }
- }
-
- if(!targeted)
- throw new ClassGenException("Not targeting " + old_ih);
- }
-
- /**
- * @return true, if ih is target of this instruction
- */
- public boolean containsTarget(InstructionHandle ih) {
- if(target == ih)
- return true;
-
- for(int i=0; i < targets.length; i++)
- if(targets[i] == ih)
- return true;
-
- return false;
- }
-
- /**
- * Inform targets that they're not targeted anymore.
- */
- void dispose() {
- super.dispose();
-
- for(int i=0; i < targets.length; i++)
- targets[i].removeTargeter(this);
- }
-
- /**
- * @return array of match indices
- */
- public int[] getMatchs() { return match; }
-
- /**
- * @return array of match target offsets
- */
- public int[] getIndices() { return indices; }
-
- /**
- * @return array of match targets
- */
- public InstructionHandle[] getTargets() { return targets; }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denote an instruction that may consume a value from the stack.
- *
- * @version $Id: StackConsumer.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface StackConsumer {
- /** @return how many words are consumed from stack
- */
- public int consumeStack(ConstantPoolGen cpg);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Super class for stack operations like DUP and POP.
- *
- * @version $Id: StackInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class StackInstruction extends Instruction {
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- */
- StackInstruction() {}
-
- /**
- * @param opcode instruction opcode
- */
- protected StackInstruction(short opcode) {
- super(opcode, (short)1);
- }
-
- /** @return Type.UNKNOWN
- */
- public Type getType(ConstantPoolGen cp) {
- return Type.UNKNOWN;
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denote an instruction that may produce a value on top of the stack
- * (this excludes DUP_X1, e.g.)
- *
- * @version $Id: StackProducer.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface StackProducer {
- /** @return how many words are produced on stack
- */
- public int produceStack(ConstantPoolGen cpg);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an unparameterized instruction to store a value into a local variable,
- * e.g. ISTORE.
- *
- * @version $Id: StoreInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public abstract class StoreInstruction extends LocalVariableInstruction
- implements PopInstruction
-{
- /**
- * Empty constructor needed for the Class.newInstance() statement in
- * Instruction.readInstruction(). Not to be used otherwise.
- * tag and length are defined in readInstruction and initFromFile, respectively.
- */
- StoreInstruction(short canon_tag, short c_tag) {
- super(canon_tag, c_tag);
- }
-
- /**
- * @param opcode Instruction opcode
- * @param c_tag Instruction number for compact version, ASTORE_0, e.g.
- * @param n local variable index (unsigned short)
- */
- protected StoreInstruction(short opcode, short c_tag, int n) {
- super(opcode, c_tag, n);
- }
-
- /**
- * Call corresponding visitor method(s). The order is:
- * Call visitor methods of implemented interfaces first, then
- * call methods according to the class hierarchy in descending order,
- * i.e., the most specific visitXXX() call comes last.
- *
- * @param v Visitor object
- */
- public void accept(Visitor v) {
- v.visitStackConsumer(this);
- v.visitPopInstruction(this);
- v.visitTypedInstruction(this);
- v.visitLocalVariableInstruction(this);
- v.visitStoreInstruction(this);
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Get the type associated with an instruction, int for ILOAD, or the type
- * of the field of a PUTFIELD instruction, e.g..
- *
- * @version $Id: TypedInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- */
-public interface TypedInstruction {
- public Type getType(ConstantPoolGen cpg);
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an instruction to perform an unconditional branch, i.e., GOTO, JSR.
- *
- * @version $Id: UnconditionalBranch.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
-
- * @see GOTO
- * @see JSR
- */
-public interface UnconditionalBranch {}
-
+++ /dev/null
-package org.aspectj.apache.bcel.generic;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-/**
- * Denotes an instruction to be a variable length instruction, such as
- * GOTO, JSR, LOOKUPSWITCH and TABLESWITCH.
- *
- * @version $Id: VariableLengthInstruction.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
-
- * @see GOTO
- * @see JSR
- * @see LOOKUPSWITCH
- * @see TABLESWITCH
- */
-public interface VariableLengthInstruction {}
-
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.annotation.AnnotationElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-
-
-public class AnnotationElementValueGen extends ElementValueGen {
-
- // For annotation element values, this is the annotation
- private AnnotationGen a;
-
- public AnnotationElementValueGen(AnnotationGen a,ConstantPoolGen cpool) {
- super(ANNOTATION,cpool);
- this.a = a;
- }
-
- public AnnotationElementValueGen(int type, AnnotationGen annotation, ConstantPoolGen cpool) {
- super(type,cpool);
- if (type != ANNOTATION)
- throw new RuntimeException("Only element values of type annotation can be built with this ctor");
- this.a = annotation;
- }
-
- public AnnotationElementValueGen(AnnotationElementValue value, ConstantPoolGen cpool,boolean copyPoolEntries) {
- super(ANNOTATION,cpool);
- a = new AnnotationGen(value.getAnnotation(),cpool,copyPoolEntries);
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ANNOTATION == '@')
- a.dump(dos);
- }
-
- public String stringifyValue() {
- throw new RuntimeException("Not implemented yet");
- }
-
- /**
- * Return immutable variant of this AnnotationElementValueGen
- */
- public ElementValue getElementValue() {
- return new AnnotationElementValue(this.type,a.getAnnotation(),cpGen.getConstantPool());
- }
-
- public AnnotationGen getAnnotation() { return a;}
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM Corporation
- *
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement initial implementation
- * ******************************************************************/
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.annotation.Annotation;
-import org.aspectj.apache.bcel.classfile.annotation.ElementNameValuePair;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-import org.aspectj.apache.bcel.generic.ObjectType;
-
-public class AnnotationGen {
- private int typeIndex;
- private List /* ElementNameValuePairGen */ evs;
- private ConstantPoolGen cpool;
- private boolean isRuntimeVisible = false;
-
- /**
- * Here we are taking a fixed annotation of type Annotation and building a
- * modifiable AnnotationGen object. If the pool passed in is for a different
- * class file, then copyPoolEntries should have been passed as true as that
- * will force us to do a deep copy of the annotation and move the cpool entries
- * across.
- * We need to copy the type and the element name value pairs and the visibility.
- */
- public AnnotationGen(Annotation a,ConstantPoolGen cpool,boolean copyPoolEntries) {
- this.cpool = cpool;
-
- if (copyPoolEntries) {
- typeIndex = cpool.addUtf8(a.getTypeSignature());
- } else {
- typeIndex = a.getTypeIndex();
- }
-
- isRuntimeVisible = a.isRuntimeVisible();
-
- evs = copyValues(a.getValues(),cpool,copyPoolEntries);
- }
-
- private List copyValues(List in,ConstantPoolGen cpool,boolean copyPoolEntries) {
- List out = new ArrayList();
- for (Iterator iter = in.iterator(); iter.hasNext();) {
- ElementNameValuePair nvp = (ElementNameValuePair) iter.next();
- out.add(new ElementNameValuePairGen(nvp,cpool,copyPoolEntries));
- }
- return out;
- }
-
- private AnnotationGen(ConstantPoolGen cpool) {
- this.cpool = cpool;
- }
-
- /**
- * Retrieve an immutable version of this AnnotationGen
- */
- public Annotation getAnnotation() {
- Annotation a = new Annotation(typeIndex,cpool.getConstantPool(),isRuntimeVisible);
- for (Iterator iter = evs.iterator(); iter.hasNext();) {
- ElementNameValuePairGen element = (ElementNameValuePairGen) iter.next();
- a.addElementNameValuePair(element.getElementNameValuePair());
- }
- return a;
- }
-
- public AnnotationGen(ObjectType type,List /*ElementNameValuePairGen*/ elements,boolean vis,ConstantPoolGen cpool) {
- this.cpool = cpool;
- this.typeIndex = cpool.addUtf8(type.getSignature());
- evs = elements;
- isRuntimeVisible = vis;
- }
-
- public static AnnotationGen read(DataInputStream dis,ConstantPoolGen cpool,boolean b) throws IOException {
- AnnotationGen a = new AnnotationGen(cpool);
- a.typeIndex = dis.readUnsignedShort();
- int elemValuePairCount = dis.readUnsignedShort();
- for (int i=0;i<elemValuePairCount;i++) {
- int nidx = dis.readUnsignedShort();
- a.addElementNameValuePair(
- new ElementNameValuePairGen(nidx,ElementValueGen.readElementValue(dis,cpool),cpool));
- }
- a.isRuntimeVisible(b);
- return a;
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeShort(typeIndex); // u2 index of type name in cpool
- dos.writeShort(evs.size()); // u2 element_value pair count
- for (int i = 0 ; i<evs.size();i++) {
- ElementNameValuePairGen envp = (ElementNameValuePairGen) evs.get(i);
- envp.dump(dos);
- }
- }
-
- public void addElementNameValuePair(ElementNameValuePairGen evp) {
- if (evs == null) evs = new ArrayList();
- evs.add(evp);
- }
-
-
- public int getTypeIndex() {
- return typeIndex;
- }
-
- public final String getTypeSignature() {
-// ConstantClass c = (ConstantClass)cpool.getConstant(typeIndex);
- ConstantUtf8 utf8 = (ConstantUtf8)cpool.getConstant(typeIndex/*c.getNameIndex()*/);
- return utf8.getBytes();
- }
-
- public final String getTypeName() {
- return getTypeSignature();// BCELBUG: Should I use this instead? Utility.signatureToString(getTypeSignature());
- }
-
- /**
- * Returns list of ElementNameValuePair objects
- */
- public List getValues() {
- return evs;
- }
-
- public String toString() {
- StringBuffer s = new StringBuffer();
- s.append("AnnotationGen:["+getTypeName()+" #"+evs.size()+" {");
- for (int i = 0; i<evs.size();i++) {
- s.append(evs.get(i));
- if (i+1<evs.size()) s.append(",");
- }
- s.append("}]");
- return s.toString();
- }
-
- public String toShortString() {
- StringBuffer s = new StringBuffer();
- s.append("@"+getTypeName()+"(");
- for (int i = 0; i<evs.size();i++) {
- s.append(evs.get(i));
- if (i+1<evs.size()) s.append(",");
- }
- s.append(")");
- return s.toString();
- }
-
- private void isRuntimeVisible(boolean b) {
- isRuntimeVisible = b;
- }
-
- public boolean isRuntimeVisible() {
- return isRuntimeVisible;
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import org.aspectj.apache.bcel.classfile.annotation.ArrayElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-
-
-public class ArrayElementValueGen extends ElementValueGen {
-
- // J5TODO: Should we make this an array or a list? A list would be easier to modify ...
- private List /*ElementValueGen*/ evalues;
-
- public ArrayElementValueGen(ConstantPoolGen cp) {
- super(ARRAY,cp);
- evalues = new ArrayList();
- }
-
- public ArrayElementValueGen(int type, ElementValueGen[] datums, ConstantPoolGen cpool) {
- super(type,cpool);
- if (type != ARRAY)
- throw new RuntimeException("Only element values of type array can be built with this ctor");
- this.evalues = new ArrayList();
- for (int i = 0; i < datums.length; i++) {
- evalues.add(datums[i]);
- }
- }
-
- /**
- * Return immutable variant of this ArrayElementValueGen
- */
- public ElementValue getElementValue() {
- ElementValue[] immutableData = new ElementValue[evalues.size()];
- int i =0;
- for (Iterator iter = evalues.iterator(); iter.hasNext();) {
- ElementValueGen element = (ElementValueGen) iter.next();
- immutableData[i++] = element.getElementValue();
- }
- return new ArrayElementValue(type,immutableData,cpGen.getConstantPool());
- }
-
- /**
- * @param value
- * @param cpool
- */
- public ArrayElementValueGen(ArrayElementValue value, ConstantPoolGen cpool,boolean copyPoolEntries) {
- super(ARRAY,cpool);
- evalues = new ArrayList();
- ElementValue[] in = value.getElementValuesArray();
- for (int i = 0; i < in.length; i++) {
- evalues.add(ElementValueGen.copy(in[i],cpool,copyPoolEntries));
- }
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ARRAY == '[')
- dos.writeShort(evalues.size());
- for (Iterator iter = evalues.iterator(); iter.hasNext();) {
- ElementValueGen element = (ElementValueGen) iter.next();
- element.dump(dos);
- }
- }
-
- public String stringifyValue() {
- StringBuffer sb = new StringBuffer();
- sb.append("[");
- for (Iterator iter = evalues.iterator(); iter.hasNext();) {
- ElementValueGen element = (ElementValueGen) iter.next();
- sb.append(element.stringifyValue());
- if (iter.hasNext()) sb.append(",");
- }
- sb.append("]");
- return sb.toString();
- }
-
- public List getElementValues() { return evalues;}
- public int getElementValuesSize() { return evalues.size();}
-
- public void addElement(ElementValueGen gen) {
- evalues.add(gen);
- }
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.annotation.ClassElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-import org.aspectj.apache.bcel.generic.ObjectType;
-
-
-public class ClassElementValueGen extends ElementValueGen {
-
- // For primitive types and string type, this points to the value entry in the cpool
- // For 'class' this points to the class entry in the cpool
- private int idx;
-
- protected ClassElementValueGen(int typeIdx,ConstantPoolGen cpool) {
- super(ElementValueGen.CLASS,cpool);
- this.idx = typeIdx;
- }
-
- public ClassElementValueGen(ObjectType t,ConstantPoolGen cpool) {
- super(ElementValueGen.CLASS,cpool);
- //this.idx = cpool.addClass(t);
- idx = cpool.addUtf8(t.getSignature());
- }
-
- /**
- * Return immutable variant of this ClassElementValueGen
- */
- public ElementValue getElementValue() {
- return new ClassElementValue(type,idx,cpGen.getConstantPool());
- }
-
- public ClassElementValueGen(ClassElementValue value, ConstantPoolGen cpool,boolean copyPoolEntries) {
- super(CLASS,cpool);
- if (copyPoolEntries) {
- //idx = cpool.addClass(value.getClassString());
- idx = cpool.addUtf8(value.getClassString());
- } else {
- idx = value.getIndex();
-
- }
- }
-
- public int getIndex() {
- return idx;
- }
-
- public String getClassString() {
- ConstantUtf8 cu8 = (ConstantUtf8)getConstantPool().getConstant(idx);
- return cu8.getBytes();
-// ConstantClass c = (ConstantClass)getConstantPool().getConstant(idx);
-// ConstantUtf8 utf8 = (ConstantUtf8)getConstantPool().getConstant(c.getNameIndex());
-// return utf8.getBytes();
- }
-
- public String stringifyValue() {
- return getClassString();
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 kind of value
- dos.writeShort(idx);
- }
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.annotation.ElementNameValuePair;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-
-
-public class ElementNameValuePairGen {
- private int nameIdx;
- private ElementValueGen value;
- private ConstantPoolGen cpool;
-
- public ElementNameValuePairGen(ElementNameValuePair nvp, ConstantPoolGen cpool, boolean copyPoolEntries) {
- this.cpool = cpool;
- // J5ASSERT:
- // Could assert nvp.getNameString() points to the same thing as cpool.getConstant(nvp.getNameIndex())
-// if (!nvp.getNameString().equals(((ConstantUtf8)cpool.getConstant(nvp.getNameIndex())).getBytes())) {
-// throw new RuntimeException("envp buggered");
-// }
- if (copyPoolEntries) {
- nameIdx = cpool.addUtf8(nvp.getNameString());
- } else {
- nameIdx = nvp.getNameIndex();
- }
- value = ElementValueGen.copy(nvp.getValue(),cpool,copyPoolEntries);
- }
-
- /**
- * Retrieve an immutable version of this ElementNameValuePairGen
- */
- public ElementNameValuePair getElementNameValuePair() {
- ElementValue immutableValue = value.getElementValue();
- return new ElementNameValuePair(nameIdx,immutableValue,cpool.getConstantPool());
- }
-
-
- protected ElementNameValuePairGen(int idx,ElementValueGen value,ConstantPoolGen cpool) {
- this.nameIdx = idx;
- this.value = value;
- this.cpool = cpool;
- }
-
- public ElementNameValuePairGen(String name,ElementValueGen value,ConstantPoolGen cpool) {
- this.nameIdx = cpool.addUtf8(name);
- this.value = value;
- this.cpool = cpool;
- }
-
- protected void dump(DataOutputStream dos) throws IOException {
- dos.writeShort(nameIdx); // u2 name of the element
- value.dump(dos);
- }
-
- public int getNameIndex() {
- return nameIdx;
- }
-
- public final String getNameString() {
-// ConstantString cu8 = (ConstantString)cpool.getConstant(nameIdx);
- return ((ConstantUtf8)cpool.getConstant(nameIdx)).getBytes();
- }
-
- public final ElementValueGen getValue() {
- return value;
- }
-
- public String toString() {
- return "ElementNameValuePair:["+getNameString()+"="+value.stringifyValue()+"]";
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.annotation.AnnotationElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ArrayElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ClassElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.EnumElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.SimpleElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-
-public abstract class ElementValueGen {
-
- protected int type;
- protected ConstantPoolGen cpGen;
-
-
- protected ElementValueGen(int type,ConstantPoolGen cpGen) {
- this.type = type;
- this.cpGen = cpGen;
- }
-
- /**
- * Subtypes return an immutable variant of the ElementValueGen
- */
- public abstract ElementValue getElementValue();
-
- public int getElementValueType() {
- return type;
- }
-
- public abstract String stringifyValue();
- public abstract void dump(DataOutputStream dos) throws IOException;
-
- public static final int STRING = 's';
- public static final int ENUM_CONSTANT = 'e';
- public static final int CLASS = 'c';
- public static final int ANNOTATION = '@';
- public static final int ARRAY = '[';
-
- public static final int PRIMITIVE_INT = 'I';
- public static final int PRIMITIVE_BYTE = 'B';
- public static final int PRIMITIVE_CHAR = 'C';
- public static final int PRIMITIVE_DOUBLE = 'D';
- public static final int PRIMITIVE_FLOAT = 'F';
- public static final int PRIMITIVE_LONG = 'J';
- public static final int PRIMITIVE_SHORT = 'S';
- public static final int PRIMITIVE_BOOLEAN= 'Z';
-
- public static ElementValueGen readElementValue(DataInputStream dis,ConstantPoolGen cpGen) throws IOException {
- int type= dis.readUnsignedByte();
- switch (type) {
- case 'B': // byte
- return new SimpleElementValueGen(PRIMITIVE_BYTE,dis.readUnsignedShort(),cpGen);
- case 'C': // char
- return new SimpleElementValueGen(PRIMITIVE_CHAR,dis.readUnsignedShort(),cpGen);
- case 'D': // double
- return new SimpleElementValueGen(PRIMITIVE_DOUBLE,dis.readUnsignedShort(),cpGen);
- case 'F': // float
- return new SimpleElementValueGen(PRIMITIVE_FLOAT,dis.readUnsignedShort(),cpGen);
- case 'I': // int
- return new SimpleElementValueGen(PRIMITIVE_INT,dis.readUnsignedShort(),cpGen);
- case 'J': // long
- return new SimpleElementValueGen(PRIMITIVE_LONG,dis.readUnsignedShort(),cpGen);
- case 'S': // short
- return new SimpleElementValueGen(PRIMITIVE_SHORT,dis.readUnsignedShort(),cpGen);
- case 'Z': // boolean
- return new SimpleElementValueGen(PRIMITIVE_BOOLEAN,dis.readUnsignedShort(),cpGen);
- case 's': // String
- return new SimpleElementValueGen(STRING,dis.readUnsignedShort(),cpGen);
-
- case 'e': // Enum constant
- return new EnumElementValueGen(dis.readUnsignedShort(),dis.readUnsignedShort(),cpGen);
-
- case 'c': // Class
- return new ClassElementValueGen(dis.readUnsignedShort(),cpGen);
-//
-// case '@': // Annotation
-// return new AnnotationElementValueGen(ANNOTATION,Annotation.read(dis,cpGen),cpGen);
-//
-// case '[': // Array
-// int numArrayVals = dis.readUnsignedShort();
-// List arrayVals = new ArrayList();
-// ElementValue[] evalues = new ElementValue[numArrayVals];
-// for (int j=0;j<numArrayVals;j++) {
-// evalues[j] = ElementValue.readElementValue(dis,cpGen);
-// }
-// return new ArrayElementValue(ARRAY,evalues,cpGen);
-
- default:
- throw new RuntimeException("Unexpected element value kind in annotation: "+type);
- }
- }
-
- protected ConstantPoolGen getConstantPool() {
- return cpGen;
- }
-
- /**
- * Creates an (modifiable) ElementValueGen copy of an (immutable) ElementValue - constant pool is assumed correct.
- */
- public static ElementValueGen copy(ElementValue value,ConstantPoolGen cpool,boolean copyPoolEntries) {
- switch (value.getElementValueType()) {
- case 'B': // byte
- case 'C': // char
- case 'D': // double
- case 'F': // float
- case 'I': // int
- case 'J': // long
- case 'S': // short
- case 'Z': // boolean
- case 's': // String
- return new SimpleElementValueGen((SimpleElementValue)value,cpool,copyPoolEntries);
-
- case 'e': // Enum constant
- return new EnumElementValueGen((EnumElementValue)value,cpool,copyPoolEntries);
-
- case '@': // Annotation
- return new AnnotationElementValueGen((AnnotationElementValue)value,cpool,copyPoolEntries);
-
- case '[': // Array
- return new ArrayElementValueGen((ArrayElementValue)value,cpool,copyPoolEntries);
-
- case 'c': // Class
- return new ClassElementValueGen((ClassElementValue)value,cpool,copyPoolEntries);
-
- default:
- throw new RuntimeException("Not implemented yet! ("+value.getElementValueType()+")");
- }
- }
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.EnumElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-import org.aspectj.apache.bcel.generic.ObjectType;
-
-
-public class EnumElementValueGen extends ElementValueGen {
-
- // For enum types, these two indices point to the type and value
- private int typeIdx;
- private int valueIdx;
-
- /**
- * This ctor assumes the constant pool already contains the right type and value -
- * as indicated by typeIdx and valueIdx. This ctor is used for deserialization
- */
- protected EnumElementValueGen(int typeIdx,int valueIdx,ConstantPoolGen cpool) {
- super(ElementValueGen.ENUM_CONSTANT,cpool);
- if (type != ENUM_CONSTANT)
- throw new RuntimeException("Only element values of type enum can be built with this ctor");
- this.typeIdx = typeIdx;
- this.valueIdx= valueIdx;
- }
-
- /**
- * Return immutable variant of this EnumElementValue
- */
- public ElementValue getElementValue() {
- System.err.println("Duplicating value: "+getEnumTypeString()+":"+getEnumValueString());
- return new EnumElementValue(type,typeIdx,valueIdx,cpGen.getConstantPool());
- }
-
- public EnumElementValueGen(ObjectType t,String value,ConstantPoolGen cpool) {
- super(ElementValueGen.ENUM_CONSTANT,cpool);
- typeIdx = cpool.addUtf8(t.getSignature());// was addClass(t);
- valueIdx= cpool.addUtf8(value);// was addString(value);
- }
-
- public EnumElementValueGen(EnumElementValue value, ConstantPoolGen cpool, boolean copyPoolEntries) {
- super(ENUM_CONSTANT,cpool);
- if (copyPoolEntries) {
- typeIdx = cpool.addUtf8(value.getEnumTypeString());// was addClass(value.getEnumTypeString());
- valueIdx = cpool.addUtf8(value.getEnumValueString()); // was addString(value.getEnumValueString());
- } else {
- typeIdx = value.getTypeIndex();
- valueIdx = value.getValueIndex();
- }
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 type of value (ENUM_CONSTANT == 'e')
- dos.writeShort(typeIdx); // u2
- dos.writeShort(valueIdx); // u2
- }
-
- public String stringifyValue() {
- ConstantUtf8 cu8 = (ConstantUtf8)getConstantPool().getConstant(valueIdx);
- return cu8.getBytes();
-// ConstantString cu8 = (ConstantString)getConstantPool().getConstant(valueIdx);
-// return ((ConstantUtf8)getConstantPool().getConstant(cu8.getStringIndex())).getBytes();
- }
-
-
- // BCELBUG: Should we need to call utility.signatureToString() on the output here?
- public String getEnumTypeString() {
-// Constant cc = getConstantPool().getConstant(typeIdx);
-// ConstantClass cu8 = (ConstantClass)getConstantPool().getConstant(typeIdx);
-// return ((ConstantUtf8)getConstantPool().getConstant(cu8.getNameIndex())).getBytes();
- return ((ConstantUtf8)getConstantPool().getConstant(typeIdx)).getBytes();
- // return Utility.signatureToString(cu8.getBytes());
- }
-
- public String getEnumValueString() {
- return ((ConstantUtf8)getConstantPool().getConstant(valueIdx)).getBytes();
-// ConstantString cu8 = (ConstantString)getConstantPool().getConstant(valueIdx);
-// return ((ConstantUtf8)getConstantPool().getConstant(cu8.getStringIndex())).getBytes();
- }
-
- public int getValueIndex() { return valueIdx;}
- public int getTypeIndex() { return typeIdx; }
-
-
-}
+++ /dev/null
-/* *******************************************************************
- * Copyright (c) 2004 IBM
- * All rights reserved.
- * This program and the accompanying materials are made available
- * under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Andy Clement - initial implementation {date}
- * ******************************************************************/
-
-package org.aspectj.apache.bcel.generic.annotation;
-
-import java.io.DataOutputStream;
-import java.io.IOException;
-
-import org.aspectj.apache.bcel.classfile.ConstantDouble;
-import org.aspectj.apache.bcel.classfile.ConstantFloat;
-import org.aspectj.apache.bcel.classfile.ConstantInteger;
-import org.aspectj.apache.bcel.classfile.ConstantLong;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.annotation.ElementValue;
-import org.aspectj.apache.bcel.classfile.annotation.SimpleElementValue;
-import org.aspectj.apache.bcel.generic.ConstantPoolGen;
-
-
-public class SimpleElementValueGen extends ElementValueGen {
-
- // For primitive types and string type, this points to the value entry in the cpGen
- // For 'class' this points to the class entry in the cpGen
- private int idx;
-
-
- // ctors for each supported type... type could be inferred but for now lets
- // force it to be passed
-
- /**
- * Protected ctor used for deserialization, doesn't *put* an entry in the constant pool,
- * assumes the one at the supplied index is correct.
- */
- protected SimpleElementValueGen(int type,int idx,ConstantPoolGen cpGen) {
- super(type,cpGen);
- this.idx = idx;
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,int value) {
- super(type,cpGen);
- idx = cpGen.addInteger(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,long value) {
- super(type,cpGen);
- idx = cpGen.addLong(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,double value) {
- super(type,cpGen);
- idx = cpGen.addDouble(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,float value) {
- super(type,cpGen);
- idx = cpGen.addFloat(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,short value) {
- super(type,cpGen);
- idx = cpGen.addInteger(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,byte value) {
- super(type,cpGen);
- idx = cpGen.addInteger(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,char value) {
- super(type,cpGen);
- idx = cpGen.addInteger(value);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,boolean value) {
- super(type,cpGen);
- if (value) idx = cpGen.addInteger(1);
- else idx = cpGen.addInteger(0);
- }
-
- public SimpleElementValueGen(int type,ConstantPoolGen cpGen,String value) {
- super(type,cpGen);
- idx = cpGen.addUtf8(value);
- }
-
- /**
- * The boolean controls whether we copy info from the 'old' constant pool
- * to the 'new'. You need to use this ctor if the annotation is
- * being copied from one file to another.
- */
- public SimpleElementValueGen(SimpleElementValue value,ConstantPoolGen cpool,boolean copyPoolEntries) {
- super(value.getElementValueType(),cpool);
- if (!copyPoolEntries) {
- // J5ASSERT: Could assert value.stringifyValue() is the same as
- // cpool.getConstant(SimpleElementValuevalue.getIndex())
- idx = value.getIndex();
- } else {
- switch (value.getElementValueType()) {
- case STRING: idx = cpool.addUtf8(value.getValueString()); break;
- case PRIMITIVE_INT: idx = cpool.addInteger(value.getValueInt()); break;
- case PRIMITIVE_BYTE: idx = cpool.addInteger(value.getValueByte()); break;
- case PRIMITIVE_CHAR: idx = cpool.addInteger(value.getValueChar()); break;
- case PRIMITIVE_LONG: idx = cpool.addLong(value.getValueLong()); break;
- case PRIMITIVE_FLOAT: idx = cpool.addFloat(value.getValueFloat());break;
- case PRIMITIVE_DOUBLE:idx = cpool.addDouble(value.getValueDouble());break;
- case PRIMITIVE_BOOLEAN:
- if (value.getValueBoolean()) { idx = cpool.addInteger(1);
- } else { idx = cpool.addInteger(0);}
- break;
- case PRIMITIVE_SHORT: idx = cpool.addInteger(value.getValueShort());break;
- default:
- throw new RuntimeException("SimpleElementValueGen class does not know how "+
- "to copy this type "+type);
- }
- }
- }
-
- /**
- * Return immutable variant
- */
- public ElementValue getElementValue() {
- return new SimpleElementValue(type,idx,cpGen.getConstantPool());
- }
-
- public int getIndex() {
- return idx;
- }
-
- public String getValueString() {
- if (type != STRING)
- throw new RuntimeException("Dont call getValueString() on a non STRING ElementValue");
- ConstantUtf8 c = (ConstantUtf8)cpGen.getConstant(idx);
- return c.getBytes();
- }
-
- public int getValueInt() {
- if (type != PRIMITIVE_INT)
- throw new RuntimeException("Dont call getValueString() on a non STRING ElementValue");
- ConstantInteger c = (ConstantInteger)cpGen.getConstant(idx);
- return c.getBytes();
- }
-
- // Whatever kind of value it is, return it as a string
- public String stringifyValue() {
- switch (type) {
- case PRIMITIVE_INT:
- ConstantInteger c = (ConstantInteger)cpGen.getConstant(idx);
- return Integer.toString(c.getBytes());
- case PRIMITIVE_LONG:
- ConstantLong j = (ConstantLong)cpGen.getConstant(idx);
- return Long.toString(j.getBytes());
- case PRIMITIVE_DOUBLE:
- ConstantDouble d = (ConstantDouble)cpGen.getConstant(idx);
- return Double.toString(d.getBytes());
- case PRIMITIVE_FLOAT:
- ConstantFloat f = (ConstantFloat)cpGen.getConstant(idx);
- return Float.toString(f.getBytes());
- case PRIMITIVE_SHORT:
- ConstantInteger s = (ConstantInteger)cpGen.getConstant(idx);
- return Integer.toString(s.getBytes());
- case PRIMITIVE_BYTE:
- ConstantInteger b = (ConstantInteger)cpGen.getConstant(idx);
- return Integer.toString(b.getBytes());
- case PRIMITIVE_CHAR:
- ConstantInteger ch = (ConstantInteger)cpGen.getConstant(idx);
- return Integer.toString(ch.getBytes());
- case PRIMITIVE_BOOLEAN:
- ConstantInteger bo = (ConstantInteger)cpGen.getConstant(idx);
- if (bo.getBytes() == 0) return "false";
- if (bo.getBytes() != 0) return "true";
- case STRING:
- ConstantUtf8 cu8 = (ConstantUtf8)cpGen.getConstant(idx);
- return cu8.getBytes();
-
- default:
- throw new RuntimeException("SimpleElementValueGen class does not know how to stringify type "+type);
- }
- }
-
- public void dump(DataOutputStream dos) throws IOException {
- dos.writeByte(type); // u1 kind of value
- switch (type) {
- case PRIMITIVE_INT:
- case PRIMITIVE_BYTE:
- case PRIMITIVE_CHAR:
- case PRIMITIVE_FLOAT:
- case PRIMITIVE_LONG:
- case PRIMITIVE_BOOLEAN:
- case PRIMITIVE_SHORT:
- case PRIMITIVE_DOUBLE:
- case STRING:
- dos.writeShort(idx);
- break;
- default:
- throw new RuntimeException("SimpleElementValueGen doesnt know how to write out type "+type);
- }
- }
-
-}
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:19 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-<p>
-This package contains the "generic" part of the
-<a href="http://jakarta.apache.org/bcel/">Byte Code Engineering
-Library</a>, i.e., classes to dynamically modify class objects and
-byte code instructions.
-</p>
-</body>
-</html>
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:19 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-<p>
-This package contains basic classes for the
-<a href="http://jakarta.apache.org/bcel/">Byte Code Engineering Library</a>
- and constants defined by the
-<a href="http://www.javasoft.com/docs/books/vmspec/index.html">
- JVM specification</a>.
-</p>
-</body>
-</html>
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintWriter;
-
-import org.aspectj.apache.bcel.classfile.Attribute;
-import org.aspectj.apache.bcel.classfile.Code;
-import org.aspectj.apache.bcel.classfile.CodeException;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.ConstantValue;
-import org.aspectj.apache.bcel.classfile.ExceptionTable;
-import org.aspectj.apache.bcel.classfile.InnerClass;
-import org.aspectj.apache.bcel.classfile.InnerClasses;
-import org.aspectj.apache.bcel.classfile.LineNumber;
-import org.aspectj.apache.bcel.classfile.LineNumberTable;
-import org.aspectj.apache.bcel.classfile.LocalVariable;
-import org.aspectj.apache.bcel.classfile.LocalVariableTable;
-import org.aspectj.apache.bcel.classfile.SourceFile;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * Convert found attributes into HTML file.
- *
- * @version $Id: AttributeHTML.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- *
- */
-final class AttributeHTML implements org.aspectj.apache.bcel.Constants {
- private String class_name; // name of current class
- private PrintWriter file; // file to write to
- private int attr_count = 0;
- private ConstantHTML constant_html;
- private ConstantPool constant_pool;
-
- AttributeHTML(String dir, String class_name, ConstantPool constant_pool,
- ConstantHTML constant_html) throws IOException
- {
- this.class_name = class_name;
- this.constant_pool = constant_pool;
- this.constant_html = constant_html;
-
- file = new PrintWriter(new FileOutputStream(dir + class_name + "_attributes.html"));
- file.println("<HTML><BODY BGCOLOR=\"#C0C0C0\"><TABLE BORDER=0>");
- }
-
- private final String codeLink(int link, int method_number) {
- return "<A HREF=\"" + class_name + "_code.html#code" +
- method_number + "@" + link + "\" TARGET=Code>" +
- link + "</A>";
- }
-
- final void close() {
- file.println("</TABLE></BODY></HTML>");
- file.close();
- }
-
- final void writeAttribute(Attribute attribute, String anchor) throws IOException {
- writeAttribute(attribute, anchor, 0);
- }
-
- final void writeAttribute(Attribute attribute, String anchor, int method_number) throws IOException {
- byte tag = attribute.getTag();
- int index;
-
- if(tag == ATTR_UNKNOWN) // Don't know what to do about this one
- return;
-
- attr_count++; // Increment number of attributes found so far
-
- if(attr_count % 2 == 0)
- file.print("<TR BGCOLOR=\"#C0C0C0\"><TD>");
- else
- file.print("<TR BGCOLOR=\"#A0A0A0\"><TD>");
-
- file.println("<H4><A NAME=\"" + anchor + "\">" + attr_count + " " + ATTRIBUTE_NAMES[tag] + "</A></H4>");
-
- /* Handle different attributes
- */
- switch(tag) {
- case ATTR_CODE:
- Code c = (Code)attribute;
-
- // Some directly printable values
- file.print("<UL><LI>Maximum stack size = " + c.getMaxStack() +
- "</LI>\n<LI>Number of local variables = " +
- c.getMaxLocals() + "</LI>\n<LI><A HREF=\"" + class_name +
- "_code.html#method" + method_number + "\" TARGET=Code>Byte code</A></LI></UL>\n");
-
- // Get handled exceptions and list them
- CodeException[] ce = c.getExceptionTable();
- int len = ce.length;
-
- if(len > 0) {
- file.print("<P><B>Exceptions handled</B><UL>");
-
- for(int i=0; i < len; i++) {
- int catch_type = ce[i].getCatchType(); // Index in constant pool
-
- file.print("<LI>");
-
- if(catch_type != 0)
- file.print(constant_html.referenceConstant(catch_type)); // Create Link to _cp.html
- else
- file.print("Any Exception");
-
- file.print("<BR>(Ranging from lines " + codeLink(ce[i].getStartPC(), method_number) +
- " to " + codeLink(ce[i].getEndPC(), method_number) + ", handled at line " +
- codeLink(ce[i].getHandlerPC(), method_number) + ")</LI>");
- }
- file.print("</UL>");
- }
- break;
-
- case ATTR_CONSTANT_VALUE:
- index = ((ConstantValue)attribute).getConstantValueIndex();
-
- // Reference _cp.html
- file.print("<UL><LI><A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=\"ConstantPool\">Constant value index(" + index +")</A></UL>\n");
- break;
-
- case ATTR_SOURCE_FILE:
- index = ((SourceFile)attribute).getSourceFileIndex();
-
- // Reference _cp.html
- file.print("<UL><LI><A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=\"ConstantPool\">Source file index(" + index +")</A></UL>\n");
- break;
-
- case ATTR_EXCEPTIONS:
- // List thrown exceptions
- int[] indices = ((ExceptionTable)attribute).getExceptionIndexTable();
-
- file.print("<UL>");
-
- for(int i=0; i < indices.length; i++)
- file.print("<LI><A HREF=\"" + class_name + "_cp.html#cp" + indices[i] +
- "\" TARGET=\"ConstantPool\">Exception class index(" + indices[i] + ")</A>\n");
-
- file.print("</UL>\n");
- break;
-
- case ATTR_LINE_NUMBER_TABLE:
- LineNumber[] line_numbers =((LineNumberTable)attribute).getLineNumberTable();
-
- // List line number pairs
- file.print("<P>");
-
- for(int i=0; i < line_numbers.length; i++) {
- file.print("(" + line_numbers[i].getStartPC() + ", " + line_numbers[i].getLineNumber() + ")");
-
- if(i < line_numbers.length - 1)
- file.print(", "); // breakable
- }
- break;
-
- case ATTR_LOCAL_VARIABLE_TABLE:
- LocalVariable[] vars = ((LocalVariableTable)attribute).getLocalVariableTable();
-
- // List name, range and type
- file.print("<UL>");
-
- for(int i=0; i < vars.length; i++) {
- index = vars[i].getSignatureIndex();
- String signature = ((ConstantUtf8)constant_pool.getConstant(index, CONSTANT_Utf8)).getBytes();
- signature = Utility.signatureToString(signature, false);
- int start = vars[i].getStartPC();
- int end = (start + vars[i].getLength());
-
- file.println("<LI>" + Class2HTML.referenceType(signature) +
- " <B>" + vars[i].getName() + "</B> in slot %" + vars[i].getIndex() +
- "<BR>Valid from lines " +
- "<A HREF=\"" + class_name + "_code.html#code" + method_number + "@" + start + "\" TARGET=Code>" +
- start + "</A> to " +
- "<A HREF=\"" + class_name + "_code.html#code" + method_number + "@" + end + "\" TARGET=Code>" +
- end + "</A></LI>");
- }
- file.print("</UL>\n");
-
- break;
-
- case ATTR_INNER_CLASSES:
- InnerClass[] classes = ((InnerClasses)attribute).getInnerClasses();
-
- // List inner classes
- file.print("<UL>");
-
- for(int i=0; i < classes.length; i++) {
- String name, access;
-
- index = classes[i].getInnerNameIndex();
- if(index > 0)
- name =((ConstantUtf8)constant_pool.getConstant(index, CONSTANT_Utf8)).getBytes();
- else
- name = "<anonymous>";
-
- access = Utility.accessToString(classes[i].getInnerAccessFlags());
-
- file.print("<LI><FONT COLOR=\"#FF0000\">" + access + "</FONT> "+
- constant_html.referenceConstant(classes[i].getInnerClassIndex()) +
- " in class " +
- constant_html.referenceConstant(classes[i].getOuterClassIndex()) +
- " named " + name + "</LI>\n");
- }
-
- file.print("</UL>\n");
- break;
-
- default: // Such as Unknown attribute or Deprecated
- file.print("<P>" + attribute.toString());
- }
-
- file.println("</TD></TR>");
- file.flush();
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintWriter;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.Attribute;
-import org.aspectj.apache.bcel.classfile.ClassParser;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.JavaClass;
-import org.aspectj.apache.bcel.classfile.Method;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * Read class file(s) and convert them into HTML files.
- *
- * Given a JavaClass object "class" that is in package "package" five files
- * will be created in the specified directory.
- *
- * <OL>
- * <LI> "package"."class".html as the main file which defines the frames for
- * the following subfiles.
- * <LI> "package"."class"_attributes.html contains all (known) attributes found in the file
- * <LI> "package"."class"_cp.html contains the constant pool
- * <LI> "package"."class"_code.html contains the byte code
- * <LI> "package"."class"_methods.html contains references to all methods and fields of the class
- * </OL>
- *
- * All subfiles reference each other appropiately, e.g. clicking on a
- * method in the Method's frame will jump to the appropiate method in
- * the Code frame.
- *
- * @version $Id: Class2HTML.java,v 1.4 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
-*/
-public class Class2HTML implements Constants
-{
- private JavaClass java_class; // current class object
- private String dir;
-
- private static String class_package; // name of package, unclean to make it static, but ...
- private static String class_name; // name of current class, dito
- private static ConstantPool constant_pool;
-
- /**
- * Write contents of the given JavaClass into HTML files.
- *
- * @param java_class The class to write
- * @param dir The directory to put the files in
- */
- public Class2HTML(JavaClass java_class, String dir) throws IOException {
- Method[] methods = java_class.getMethods();
-
- this.java_class = java_class;
- this.dir = dir;
- class_name = java_class.getClassName(); // Remember full name
- constant_pool = java_class.getConstantPool();
-
- // Get package name by tacking off everything after the last `.'
- int index = class_name.lastIndexOf('.');
- if(index > -1)
- class_package = class_name.substring(0, index);
- else
- class_package = ""; // default package
-
- ConstantHTML constant_html = new ConstantHTML(dir, class_name, class_package, methods,
- constant_pool);
-
- /* Attributes can't be written in one step, so we just open a file
- * which will be written consequently.
- */
- AttributeHTML attribute_html = new AttributeHTML(dir, class_name, constant_pool, constant_html);
-
- MethodHTML method_html = new MethodHTML(dir, class_name, methods, java_class.getFields(),
- constant_html, attribute_html);
- // Write main file (with frames, yuk)
- writeMainHTML(attribute_html);
- new CodeHTML(dir, class_name, methods, constant_pool, constant_html);
- attribute_html.close();
- }
-
- public static void main(String argv[])
- {
- String[] file_name = new String[argv.length];
- int files=0;
- ClassParser parser=null;
- JavaClass java_class=null;
- String zip_file = null;
- char sep = System.getProperty("file.separator").toCharArray()[0];
- String dir = "." + sep; // Where to store HTML files
-
- try {
- /* Parse command line arguments.
- */
- for(int i=0; i < argv.length; i++) {
- if(argv[i].charAt(0) == '-') { // command line switch
- if(argv[i].equals("-d")) { // Specify target directory, default `.´
- dir = argv[++i];
-
- if(!dir.endsWith("" + sep))
- dir = dir + sep;
-
- new File(dir).mkdirs(); // Create target directory if necessary
- }
- else if(argv[i].equals("-zip"))
- zip_file = argv[++i];
- else
- System.out.println("Unknown option " + argv[i]);
- }
- else // add file name to list */
- file_name[files++] = argv[i];
- }
-
- if(files == 0)
- System.err.println("Class2HTML: No input files specified.");
- else { // Loop through files ...
- for(int i=0; i < files; i++) {
- System.out.print("Processing " + file_name[i] + "...");
- if(zip_file == null)
- parser = new ClassParser(file_name[i]); // Create parser object from file
- else
- parser = new ClassParser(zip_file, file_name[i]); // Create parser object from zip file
-
- java_class = parser.parse();
- new Class2HTML(java_class, dir);
- System.out.println("Done.");
- }
- }
- } catch(Exception e) {
- System.out.println(e);
- e.printStackTrace(System.out);
- }
- }
-
- /**
- * Utility method that converts a class reference in the constant pool,
- * i.e., an index to a string.
- */
- static String referenceClass(int index) {
- String str = constant_pool.getConstantString(index, CONSTANT_Class);
- str = Utility.compactClassName(str);
- str = Utility.compactClassName(str, class_package + ".", true);
-
- return "<A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=ConstantPool>" + str + "</A>";
- }
-
- static final String referenceType(String type) {
- String short_type = Utility.compactClassName(type);
- short_type = Utility.compactClassName(short_type, class_package + ".", true);
-
- int index = type.indexOf('['); // Type is an array?
- if(index > -1)
- type = type.substring(0, index); // Tack of the `['
-
- // test for basic type
- if(type.equals("int") || type.equals("short") || type.equals("boolean") || type.equals("void") ||
- type.equals("char") || type.equals("byte") || type.equals("long") || type.equals("double") ||
- type.equals("float"))
- return "<FONT COLOR=\"#00FF00\">" + type + "</FONT>";
- else
- return "<A HREF=\"" + type + ".html\" TARGET=_top>" + short_type + "</A>";
- }
-
- static String toHTML(String str) {
- StringBuffer buf = new StringBuffer();
-
- try { // Filter any characters HTML doesn't like such as < and > in particular
- for(int i=0; i < str.length(); i++) {
- char ch;
-
- switch(ch=str.charAt(i)) {
- case '<': buf.append("<"); break;
- case '>': buf.append(">"); break;
- case '\n': buf.append("\\n"); break;
- case '\r': buf.append("\\r"); break;
- default: buf.append(ch);
- }
- }
- } catch(StringIndexOutOfBoundsException e) {} // Never occurs
-
- return buf.toString();
- }
-
- private void writeMainHTML(AttributeHTML attribute_html) throws IOException {
- PrintWriter file = new PrintWriter(new FileOutputStream(dir + class_name + ".html"));
- Attribute[] attributes = java_class.getAttributes();
-
- file.println("<HTML>\n" + "<HEAD><TITLE>Documentation for " + class_name + "</TITLE>" +
- "</HEAD>\n" +
- "<FRAMESET BORDER=1 cols=\"30%,*\">\n" +
- "<FRAMESET BORDER=1 rows=\"80%,*\">\n" +
-
- "<FRAME NAME=\"ConstantPool\" SRC=\"" + class_name + "_cp.html" + "\"\n MARGINWIDTH=\"0\" " +
- "MARGINHEIGHT=\"0\" FRAMEBORDER=\"1\" SCROLLING=\"AUTO\">\n" +
- "<FRAME NAME=\"Attributes\" SRC=\"" + class_name + "_attributes.html" +
- "\"\n MARGINWIDTH=\"0\" " +
- "MARGINHEIGHT=\"0\" FRAMEBORDER=\"1\" SCROLLING=\"AUTO\">\n" +
- "</FRAMESET>\n" +
-
- "<FRAMESET BORDER=1 rows=\"80%,*\">\n" +
- "<FRAME NAME=\"Code\" SRC=\"" + class_name + "_code.html\"\n MARGINWIDTH=0 " +
- "MARGINHEIGHT=0 FRAMEBORDER=1 SCROLLING=\"AUTO\">\n" +
- "<FRAME NAME=\"Methods\" SRC=\"" + class_name + "_methods.html\"\n MARGINWIDTH=0 " +
- "MARGINHEIGHT=0 FRAMEBORDER=1 SCROLLING=\"AUTO\">\n" +
- "</FRAMESET></FRAMESET></HTML>"
- );
-
- file.close();
-
- for(int i=0; i < attributes.length; i++)
- attribute_html.writeAttribute(attributes[i], "class" + i);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.ByteArrayInputStream;
-import java.util.Hashtable;
-
-import org.aspectj.apache.bcel.Constants;
-import org.aspectj.apache.bcel.classfile.ClassParser;
-import org.aspectj.apache.bcel.classfile.ConstantClass;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantUtf8;
-import org.aspectj.apache.bcel.classfile.JavaClass;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * <p>Drop in replacement for the standard class loader of the JVM. You can use it
- * in conjunction with the JavaWrapper to dynamically modify/create classes
- * as they're requested.</p>
- *
- * <p>This class loader recognizes special requests in a distinct
- * format, i.e., when the name of the requested class contains with
- * "$$BCEL$$" it calls the createClass() method with that name
- * (everything bevor the $$BCEL$$ is considered to be the package
- * name. You can subclass the class loader and override that
- * method. "Normal" classes class can be modified by overriding the
- * modifyClass() method which is called just before defineClass().</p>
- *
- * <p>There may be a number of packages where you have to use the default
- * class loader (which may also be faster). You can define the set of packages
- * where to use the system class loader in the constructor. The default value contains
- * "java.", "sun.", "javax."</p>
- *
- * @version $Id: ClassLoader.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see JavaWrapper
- * @see ClassPath
- */
-public class ClassLoader extends java.lang.ClassLoader {
- private Hashtable classes = new Hashtable(); // Hashtable is synchronized thus thread-safe
- private String[] ignored_packages = {
- "java.", "javax.", "sun."
- };
- private Repository repository = SyntheticRepository.getInstance();
- private java.lang.ClassLoader deferTo = ClassLoader.getSystemClassLoader();
-
- public ClassLoader() {
- }
-
- public ClassLoader(java.lang.ClassLoader deferTo) {
- this.deferTo = deferTo;
- this.repository = new ClassLoaderRepository(deferTo);
- }
-
- /** @param ignored_packages classes contained in these packages will be loaded
- * with the system class loader
- */
- public ClassLoader(String[] ignored_packages) {
- addIgnoredPkgs(ignored_packages);
- }
-
- public ClassLoader(java.lang.ClassLoader deferTo, String [] ignored_packages) {
- this.deferTo = deferTo;
- this.repository = new ClassLoaderRepository(deferTo);
-
- addIgnoredPkgs(ignored_packages);
- }
-
- private void addIgnoredPkgs(String[] ignored_packages) {
- String[] new_p = new String[ignored_packages.length + this.ignored_packages.length];
-
- System.arraycopy(this.ignored_packages, 0, new_p, 0, this.ignored_packages.length);
- System.arraycopy(ignored_packages, 0, new_p, this.ignored_packages.length,
- ignored_packages.length);
-
- this.ignored_packages = new_p;
- }
-
- protected Class loadClass(String class_name, boolean resolve)
- throws ClassNotFoundException
- {
- Class cl = null;
-
- /* First try: lookup hash table.
- */
- if((cl=(Class)classes.get(class_name)) == null) {
- /* Second try: Load system class using system class loader. You better
- * don't mess around with them.
- */
- for(int i=0; i < ignored_packages.length; i++) {
- if(class_name.startsWith(ignored_packages[i])) {
- cl = deferTo.loadClass(class_name);
- break;
- }
- }
-
- if(cl == null) {
- JavaClass clazz = null;
-
- /* Third try: Special request?
- */
- if(class_name.indexOf("$$BCEL$$") >= 0)
- clazz = createClass(class_name);
- else { // Fourth try: Load classes via repository
- if ((clazz = repository.loadClass(class_name)) != null) {
- clazz = modifyClass(clazz);
- }
- else
- throw new ClassNotFoundException(class_name);
- }
-
- if(clazz != null) {
- byte[] bytes = clazz.getBytes();
- cl = defineClass(class_name, bytes, 0, bytes.length);
- } else // Fourth try: Use default class loader
- cl = Class.forName(class_name);
- }
-
- if(resolve)
- resolveClass(cl);
- }
-
- classes.put(class_name, cl);
-
- return cl;
- }
-
- /** Override this method if you want to alter a class before it gets actually
- * loaded. Does nothing by default.
- */
- protected JavaClass modifyClass(JavaClass clazz) {
- return clazz;
- }
-
- /**
- * Override this method to create you own classes on the fly. The
- * name contains the special token $$BCEL$$. Everything before that
- * token is consddered to be a package name. You can encode you own
- * arguments into the subsequent string. You must regard however not
- * to use any "illegal" characters, i.e., characters that may not
- * appear in a Java class name too<br>
- *
- * The default implementation interprets the string as a encoded compressed
- * Java class, unpacks and decodes it with the Utility.decode() method, and
- * parses the resulting byte array and returns the resulting JavaClass object.
- *
- * @param class_name compressed byte code with "$$BCEL$$" in it
- */
- protected JavaClass createClass(String class_name) {
- int index = class_name.indexOf("$$BCEL$$");
- String real_name = class_name.substring(index + 8);
-
- JavaClass clazz = null;
- try {
- byte[] bytes = Utility.decode(real_name, true);
- ClassParser parser = new ClassParser(new ByteArrayInputStream(bytes), "foo");
-
- clazz = parser.parse();
- } catch(Throwable e) {
- e.printStackTrace();
- return null;
- }
-
- // Adapt the class name to the passed value
- ConstantPool cp = clazz.getConstantPool();
-
- ConstantClass cl = (ConstantClass)cp.getConstant(clazz.getClassNameIndex(),
- Constants.CONSTANT_Class);
- ConstantUtf8 name = (ConstantUtf8)cp.getConstant(cl.getNameIndex(),
- Constants.CONSTANT_Utf8);
- name.setBytes(class_name.replace('.', '/'));
-
- return clazz;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.util.HashMap;
-import java.util.Collection;
-import org.aspectj.apache.bcel.classfile.JavaClass;
-
-/**
- * Utility class implementing a (typesafe) set of JavaClass objects.
- * Since JavaClass has no equals() method, the name of the class is
- * used for comparison.
- *
- * @version $Id: ClassSet.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see ClassStack
-*/
-public class ClassSet implements java.io.Serializable {
- private HashMap _map = new HashMap();
-
- public boolean add(JavaClass clazz) {
- boolean result = false;
-
- if(!_map.containsKey(clazz.getClassName())) {
- result = true;
- _map.put(clazz.getClassName(), clazz);
- }
-
- return result;
- }
-
- public void remove(JavaClass clazz) { _map.remove(clazz.getClassName()); }
- public boolean empty() { return _map.isEmpty(); }
-
- public JavaClass[] toArray() {
- Collection values = _map.values();
- JavaClass[] classes = new JavaClass[values.size()];
- values.toArray(classes);
- return classes;
- }
-
- public String[] getClassNames() {
- return (String[])_map.keySet().toArray(new String[_map.keySet().size()]);
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-import java.util.Stack;
-import org.aspectj.apache.bcel.classfile.JavaClass;
-
-/**
- * Utility class implementing a (typesafe) stack of JavaClass objects.
- *
- * @version $Id: ClassStack.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see Stack
-*/
-public class ClassStack implements java.io.Serializable {
- private Stack stack = new Stack();
-
- public void push(JavaClass clazz) { stack.push(clazz); }
- public JavaClass pop() { return (JavaClass)stack.pop(); }
- public JavaClass top() { return (JavaClass)stack.peek(); }
- public boolean empty() { return stack.empty(); }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintWriter;
-import java.util.BitSet;
-
-import org.aspectj.apache.bcel.classfile.Attribute;
-import org.aspectj.apache.bcel.classfile.Code;
-import org.aspectj.apache.bcel.classfile.CodeException;
-import org.aspectj.apache.bcel.classfile.ConstantFieldref;
-import org.aspectj.apache.bcel.classfile.ConstantInterfaceMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantNameAndType;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.LocalVariable;
-import org.aspectj.apache.bcel.classfile.LocalVariableTable;
-import org.aspectj.apache.bcel.classfile.Method;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * Convert code into HTML file.
- *
- * @version $Id: CodeHTML.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- *
- */
-final class CodeHTML implements org.aspectj.apache.bcel.Constants {
- private String class_name; // name of current class
- private Method[] methods; // Methods to print
- private PrintWriter file; // file to write to
- private BitSet goto_set;
- private ConstantPool constant_pool;
- private ConstantHTML constant_html;
- private static boolean wide=false;
-
- CodeHTML(String dir, String class_name,
- Method[] methods, ConstantPool constant_pool,
- ConstantHTML constant_html) throws IOException
- {
- this.class_name = class_name;
- this.methods = methods;
- this.constant_pool = constant_pool;
- this.constant_html = constant_html;
-
- file = new PrintWriter(new FileOutputStream(dir + class_name + "_code.html"));
- file.println("<HTML><BODY BGCOLOR=\"#C0C0C0\">");
-
- for(int i=0; i < methods.length; i++)
- writeMethod(methods[i], i);
-
- file.println("</BODY></HTML>");
- file.close();
- }
-
- /**
- * Disassemble a stream of byte codes and return the
- * string representation.
- *
- * @param stream data input stream
- * @return String representation of byte code
- */
- private final String codeToHTML(ByteSequence bytes, int method_number)
- throws IOException
- {
- short opcode = (short)bytes.readUnsignedByte();
- StringBuffer buf;
- String name, signature;
- int default_offset=0, low, high;
- int index, class_index, vindex, constant;
- int[] jump_table;
- int no_pad_bytes=0, offset;
-
- buf = new StringBuffer("<TT>" + OPCODE_NAMES[opcode] + "</TT></TD><TD>");
-
- /* Special case: Skip (0-3) padding bytes, i.e., the
- * following bytes are 4-byte-aligned
- */
- if((opcode == TABLESWITCH) || (opcode == LOOKUPSWITCH)) {
- int remainder = bytes.getIndex() % 4;
- no_pad_bytes = (remainder == 0)? 0 : 4 - remainder;
-
- for(int i=0; i < no_pad_bytes; i++)
- bytes.readByte();
-
- // Both cases have a field default_offset in common
- default_offset = bytes.readInt();
- }
-
- switch(opcode) {
- case TABLESWITCH:
- low = bytes.readInt();
- high = bytes.readInt();
-
- offset = bytes.getIndex() - 12 - no_pad_bytes - 1;
- default_offset += offset;
-
- buf.append("<TABLE BORDER=1><TR>");
-
- // Print switch indices in first row (and default)
- jump_table = new int[high - low + 1];
- for(int i=0; i < jump_table.length; i++) {
- jump_table[i] = offset + bytes.readInt();
-
- buf.append("<TH>" + (low + i) + "</TH>");
- }
- buf.append("<TH>default</TH></TR>\n<TR>");
-
- // Print target and default indices in second row
- for(int i=0; i < jump_table.length; i++)
- buf.append("<TD><A HREF=\"#code" + method_number + "@" +
- jump_table[i] + "\">" + jump_table[i] + "</A></TD>");
- buf.append("<TD><A HREF=\"#code" + method_number + "@" +
- default_offset + "\">" + default_offset + "</A></TD></TR>\n</TABLE>\n");
-
- break;
-
- /* Lookup switch has variable length arguments.
- */
- case LOOKUPSWITCH:
- int npairs = bytes.readInt();
- offset = bytes.getIndex() - 8 - no_pad_bytes - 1;
- jump_table = new int[npairs];
- default_offset += offset;
-
- buf.append("<TABLE BORDER=1><TR>");
-
- // Print switch indices in first row (and default)
- for(int i=0; i < npairs; i++) {
- int match = bytes.readInt();
-
- jump_table[i] = offset + bytes.readInt();
- buf.append("<TH>" + match + "</TH>");
- }
- buf.append("<TH>default</TH></TR>\n<TR>");
-
- // Print target and default indices in second row
- for(int i=0; i < npairs; i++)
- buf.append("<TD><A HREF=\"#code" + method_number + "@" +
- jump_table[i] + "\">" + jump_table[i] + "</A></TD>");
- buf.append("<TD><A HREF=\"#code" + method_number + "@" +
- default_offset + "\">" + default_offset + "</A></TD></TR>\n</TABLE>\n");
- break;
-
- /* Two address bytes + offset from start of byte stream form the
- * jump target.
- */
- case GOTO: case IFEQ: case IFGE: case IFGT:
- case IFLE: case IFLT:
- case IFNE: case IFNONNULL: case IFNULL: case IF_ACMPEQ:
- case IF_ACMPNE: case IF_ICMPEQ: case IF_ICMPGE: case IF_ICMPGT:
- case IF_ICMPLE: case IF_ICMPLT: case IF_ICMPNE: case JSR:
-
- index = (int)(bytes.getIndex() + bytes.readShort() - 1);
-
- buf.append("<A HREF=\"#code" + method_number + "@" + index + "\">" + index + "</A>");
- break;
-
- /* Same for 32-bit wide jumps
- */
- case GOTO_W: case JSR_W:
- int windex = bytes.getIndex() + bytes.readInt() - 1;
- buf.append("<A HREF=\"#code" + method_number + "@" + windex + "\">" +
- windex + "</A>");
- break;
-
- /* Index byte references local variable (register)
- */
- case ALOAD: case ASTORE: case DLOAD: case DSTORE: case FLOAD:
- case FSTORE: case ILOAD: case ISTORE: case LLOAD: case LSTORE:
- case RET:
- if(wide) {
- vindex = bytes.readShort();
- wide=false; // Clear flag
- }
- else
- vindex = bytes.readUnsignedByte();
-
- buf.append("%" + vindex);
- break;
-
- /*
- * Remember wide byte which is used to form a 16-bit address in the
- * following instruction. Relies on that the method is called again with
- * the following opcode.
- */
- case WIDE:
- wide = true;
- buf.append("(wide)");
- break;
-
- /* Array of basic type.
- */
- case NEWARRAY:
- buf.append("<FONT COLOR=\"#00FF00\">" + TYPE_NAMES[bytes.readByte()] + "</FONT>");
- break;
-
- /* Access object/class fields.
- */
- case GETFIELD: case GETSTATIC: case PUTFIELD: case PUTSTATIC:
- index = bytes.readShort();
- ConstantFieldref c1 = (ConstantFieldref)constant_pool.getConstant(index, CONSTANT_Fieldref);
-
- class_index = c1.getClassIndex();
- name = constant_pool.getConstantString(class_index, CONSTANT_Class);
- name = Utility.compactClassName(name, false);
-
- index = c1.getNameAndTypeIndex();
- String field_name = constant_pool.constantToString(index, CONSTANT_NameAndType);
-
- if(name.equals(class_name)) { // Local field
- buf.append("<A HREF=\"" + class_name + "_methods.html#field" + field_name +
- "\" TARGET=Methods>" + field_name + "</A>\n");
- }
- else
- buf.append(constant_html.referenceConstant(class_index) + "." + field_name);
-
- break;
-
- /* Operands are references to classes in constant pool
- */
- case CHECKCAST: case INSTANCEOF: case NEW:
- index = bytes.readShort();
- buf.append(constant_html.referenceConstant(index));
- break;
-
- /* Operands are references to methods in constant pool
- */
- case INVOKESPECIAL: case INVOKESTATIC: case INVOKEVIRTUAL: case INVOKEINTERFACE:
- int m_index = bytes.readShort();
- String str;
-
- if(opcode == INVOKEINTERFACE) { // Special treatment needed
- int nargs = bytes.readUnsignedByte(); // Redundant
- int reserved = bytes.readUnsignedByte(); // Reserved
-
- ConstantInterfaceMethodref c=(ConstantInterfaceMethodref)constant_pool.getConstant(m_index, CONSTANT_InterfaceMethodref);
-
- class_index = c.getClassIndex();
- str = constant_pool.constantToString(c);
- index = c.getNameAndTypeIndex();
- }
- else {
- ConstantMethodref c = (ConstantMethodref)constant_pool.getConstant(m_index, CONSTANT_Methodref);
- class_index = c.getClassIndex();
-
- str = constant_pool.constantToString(c);
- index = c.getNameAndTypeIndex();
- }
-
- name = Class2HTML.referenceClass(class_index);
- str = Class2HTML.toHTML(constant_pool.constantToString(constant_pool.getConstant(index, CONSTANT_NameAndType)));
-
- // Get signature, i.e., types
- ConstantNameAndType c2 = (ConstantNameAndType)constant_pool.
- getConstant(index, CONSTANT_NameAndType);
- signature = constant_pool.constantToString(c2.getSignatureIndex(),
- CONSTANT_Utf8);
- String[] args = Utility.methodSignatureArgumentTypes(signature, false);
- String type = Utility.methodSignatureReturnType(signature, false);
-
- buf.append(name + ".<A HREF=\"" + class_name + "_cp.html#cp" + m_index +
- "\" TARGET=ConstantPool>" + str + "</A>" + "(");
-
- // List arguments
- for(int i=0; i < args.length; i++) {
- buf.append(Class2HTML.referenceType(args[i]));
-
- if(i < args.length - 1)
- buf.append(", ");
- }
- // Attach return type
- buf.append("):" + Class2HTML.referenceType(type));
-
- break;
-
- /* Operands are references to items in constant pool
- */
- case LDC_W: case LDC2_W:
- index = bytes.readShort();
-
- buf.append("<A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=\"ConstantPool\">" +
- Class2HTML.toHTML(constant_pool.constantToString(index,
- constant_pool.
- getConstant(index).getTag()))+
- "</a>");
- break;
-
- case LDC:
- index = bytes.readUnsignedByte();
- buf.append("<A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=\"ConstantPool\">" +
- Class2HTML.toHTML(constant_pool.constantToString(index,
- constant_pool.
- getConstant(index).getTag()))+
- "</a>");
- break;
-
- /* Array of references.
- */
- case ANEWARRAY:
- index = bytes.readShort();
-
- buf.append(constant_html.referenceConstant(index));
- break;
-
- /* Multidimensional array of references.
- */
- case MULTIANEWARRAY:
- index = bytes.readShort();
- int dimensions = bytes.readByte();
- buf.append(constant_html.referenceConstant(index) + ":" + dimensions + "-dimensional");
- break;
-
- /* Increment local variable.
- */
- case IINC:
- if(wide) {
- vindex = bytes.readShort();
- constant = bytes.readShort();
- wide = false;
- }
- else {
- vindex = bytes.readUnsignedByte();
- constant = bytes.readByte();
- }
- buf.append("%" + vindex + " " + constant);
- break;
-
- default:
- if(NO_OF_OPERANDS[opcode] > 0) {
- for(int i=0; i < TYPE_OF_OPERANDS[opcode].length; i++) {
- switch(TYPE_OF_OPERANDS[opcode][i]) {
- case T_BYTE:
- buf.append(bytes.readUnsignedByte());
- break;
-
- case T_SHORT: // Either branch or index
- buf.append(bytes.readShort());
- break;
-
- case T_INT:
- buf.append(bytes.readInt());
- break;
-
- default: // Never reached
- System.err.println("Unreachable default case reached!");
- System.exit(-1);
- }
- buf.append(" ");
- }
- }
- }
-
- buf.append("</TD>");
- return buf.toString();
- }
-
- /**
- * Find all target addresses in code, so that they can be marked
- * with <A NAME = ...>. Target addresses are kept in an BitSet object.
- */
- private final void findGotos(ByteSequence bytes, Method method, Code code)
- throws IOException
- {
- int index;
- goto_set = new BitSet(bytes.available());
- int opcode;
-
- /* First get Code attribute from method and the exceptions handled
- * (try .. catch) in this method. We only need the line number here.
- */
-
- if(code != null) {
- CodeException[] ce = code.getExceptionTable();
- int len = ce.length;
-
- for(int i=0; i < len; i++) {
- goto_set.set(ce[i].getStartPC());
- goto_set.set(ce[i].getEndPC());
- goto_set.set(ce[i].getHandlerPC());
- }
-
- // Look for local variables and their range
- Attribute[] attributes = code.getAttributes();
- for(int i=0; i < attributes.length; i++) {
- if(attributes[i].getTag() == ATTR_LOCAL_VARIABLE_TABLE) {
- LocalVariable[] vars = ((LocalVariableTable)attributes[i]).getLocalVariableTable();
-
- for(int j=0; j < vars.length; j++) {
- int start = vars[j].getStartPC();
- int end = (int)(start + vars[j].getLength());
- goto_set.set(start);
- goto_set.set(end);
- }
- break;
- }
- }
- }
-
- // Get target addresses from GOTO, JSR, TABLESWITCH, etc.
- for(int i=0; bytes.available() > 0; i++) {
- opcode = bytes.readUnsignedByte();
- //System.out.println(OPCODE_NAMES[opcode]);
- switch(opcode) {
- case TABLESWITCH: case LOOKUPSWITCH:
- //bytes.readByte(); // Skip already read byte
-
- int remainder = bytes.getIndex() % 4;
- int no_pad_bytes = (remainder == 0)? 0 : 4 - remainder;
- int default_offset, offset;
-
- for(int j=0; j < no_pad_bytes; j++)
- bytes.readByte();
-
- // Both cases have a field default_offset in common
- default_offset = bytes.readInt();
-
- if(opcode == TABLESWITCH) {
- int low = bytes.readInt();
- int high = bytes.readInt();
-
- offset = bytes.getIndex() - 12 - no_pad_bytes - 1;
- default_offset += offset;
- goto_set.set(default_offset);
-
- for(int j=0; j < (high - low + 1); j++) {
- index = offset + bytes.readInt();
- goto_set.set(index);
- }
- }
- else { // LOOKUPSWITCH
- int npairs = bytes.readInt();
-
- offset = bytes.getIndex() - 8 - no_pad_bytes - 1;
- default_offset += offset;
- goto_set.set(default_offset);
-
- for(int j=0; j < npairs; j++) {
- int match = bytes.readInt();
-
- index = offset + bytes.readInt();
- goto_set.set(index);
- }
- }
- break;
-
- case GOTO: case IFEQ: case IFGE: case IFGT:
- case IFLE: case IFLT:
- case IFNE: case IFNONNULL: case IFNULL: case IF_ACMPEQ:
- case IF_ACMPNE: case IF_ICMPEQ: case IF_ICMPGE: case IF_ICMPGT:
- case IF_ICMPLE: case IF_ICMPLT: case IF_ICMPNE: case JSR:
- //bytes.readByte(); // Skip already read byte
- index = bytes.getIndex() + bytes.readShort() - 1;
-
- goto_set.set(index);
- break;
-
- case GOTO_W: case JSR_W:
- //bytes.readByte(); // Skip already read byte
- index = bytes.getIndex() + bytes.readInt() - 1;
- goto_set.set(index);
- break;
-
- default:
- bytes.unreadByte();
- codeToHTML(bytes, 0); // Ignore output
- }
- }
- }
-
- /**
- * Write a single method with the byte code associated with it.
- */
- private void writeMethod(Method method, int method_number)
- throws IOException
- {
- // Get raw signature
- String signature = method.getSignature();
- // Get array of strings containing the argument types
- String[] args = Utility.methodSignatureArgumentTypes(signature, false);
- // Get return type string
- String type = Utility.methodSignatureReturnType(signature, false);
- // Get method name
- String name = method.getName();
- String html_name = Class2HTML.toHTML(name);
- // Get method's access flags
- String access = Utility.accessToString(method.getAccessFlags());
- access = Utility.replace(access, " ", " ");
- // Get the method's attributes, the Code Attribute in particular
- Attribute[] attributes= method.getAttributes();
-
- file.print("<P><B><FONT COLOR=\"#FF0000\">" + access + "</FONT> " +
- "<A NAME=method" + method_number + ">" + Class2HTML.referenceType(type) +
- "</A> <A HREF=\"" + class_name + "_methods.html#method" + method_number +
- "\" TARGET=Methods>" + html_name + "</A>(");
-
- for(int i=0; i < args.length; i++) {
- file.print(Class2HTML.referenceType(args[i]));
- if(i < args.length - 1)
- file.print(", ");
- }
-
- file.println(")</B></P>");
-
- Code c=null;
- byte[] code=null;
-
- if(attributes.length > 0) {
- file.print("<H4>Attributes</H4><UL>\n");
- for(int i=0; i < attributes.length; i++) {
- byte tag = attributes[i].getTag();
-
- if(tag != ATTR_UNKNOWN)
- file.print("<LI><A HREF=\"" + class_name + "_attributes.html#method" + method_number + "@" + i +
- "\" TARGET=Attributes>" + ATTRIBUTE_NAMES[tag] + "</A></LI>\n");
- else
- file.print("<LI>" + attributes[i] + "</LI>");
-
- if(tag == ATTR_CODE) {
- c = (Code)attributes[i];
- Attribute[] attributes2 = c.getAttributes();
- code = c.getCode();
-
- file.print("<UL>");
- for(int j=0; j < attributes2.length; j++) {
- tag = attributes2[j].getTag();
- file.print("<LI><A HREF=\"" + class_name + "_attributes.html#" +
- "method" + method_number + "@" + i + "@" + j + "\" TARGET=Attributes>" +
- ATTRIBUTE_NAMES[tag] + "</A></LI>\n");
-
- }
- file.print("</UL>");
- }
- }
- file.println("</UL>");
- }
-
- if(code != null) { // No code, an abstract method, e.g.
- //System.out.println(name + "\n" + Utility.codeToString(code, constant_pool, 0, -1));
-
- // Print the byte code
- ByteSequence stream = new ByteSequence(code);
- stream.mark(stream.available());
- findGotos(stream, method, c);
- stream.reset();
-
- file.println("<TABLE BORDER=0><TR><TH ALIGN=LEFT>Byte<BR>offset</TH>" +
- "<TH ALIGN=LEFT>Instruction</TH><TH ALIGN=LEFT>Argument</TH>");
-
- for(int i=0; stream.available() > 0; i++) {
- int offset = stream.getIndex();
- String str = codeToHTML(stream, method_number);
- String anchor = "";
-
- /* Set an anchor mark if this line is targetted by a goto, jsr, etc.
- * Defining an anchor for every line is very inefficient!
- */
- if(goto_set.get(offset))
- anchor = "<A NAME=code" + method_number + "@" + offset + "></A>";
-
- String anchor2;
- if(stream.getIndex() == code.length) // last loop
- anchor2 = "<A NAME=code" + method_number + "@" + code.length + ">" + offset + "</A>";
- else
- anchor2 = "" + offset;
-
- file.println("<TR VALIGN=TOP><TD>" + anchor2 + "</TD><TD>" + anchor + str + "</TR>");
- }
-
- // Mark last line, may be targetted from Attributes window
- file.println("<TR><TD> </A></TD></TR>");
- file.println("</TABLE>");
- }
-
- }
-}
+++ /dev/null
-
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintWriter;
-
-import org.aspectj.apache.bcel.classfile.Constant;
-import org.aspectj.apache.bcel.classfile.ConstantClass;
-import org.aspectj.apache.bcel.classfile.ConstantFieldref;
-import org.aspectj.apache.bcel.classfile.ConstantInterfaceMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantMethodref;
-import org.aspectj.apache.bcel.classfile.ConstantNameAndType;
-import org.aspectj.apache.bcel.classfile.ConstantPool;
-import org.aspectj.apache.bcel.classfile.ConstantString;
-import org.aspectj.apache.bcel.classfile.Method;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * Convert constant pool into HTML file.
- *
- * @version $Id: ConstantHTML.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- *
- */
-final class ConstantHTML implements org.aspectj.apache.bcel.Constants {
- private String class_name; // name of current class
- private String class_package; // name of package
- private ConstantPool constant_pool; // reference to constant pool
- private PrintWriter file; // file to write to
- private String[] constant_ref; // String to return for cp[i]
- private Constant[] constants; // The constants in the cp
- private Method[] methods;
-
- ConstantHTML(String dir, String class_name, String class_package, Method[] methods,
- ConstantPool constant_pool) throws IOException
- {
- this.class_name = class_name;
- this.class_package = class_package;
- this.constant_pool = constant_pool;
- this.methods = methods;
- constants = constant_pool.getConstantPool();
- file = new PrintWriter(new FileOutputStream(dir + class_name + "_cp.html"));
- constant_ref = new String[constants.length];
- constant_ref[0] = "<unknown>";
-
- file.println("<HTML><BODY BGCOLOR=\"#C0C0C0\"><TABLE BORDER=0>");
-
- // Loop through constants, constants[0] is reserved
- for(int i=1; i < constants.length; i++) {
- if(i % 2 == 0)
- file.print("<TR BGCOLOR=\"#C0C0C0\"><TD>");
- else
- file.print("<TR BGCOLOR=\"#A0A0A0\"><TD>");
-
- if(constants[i] != null)
- writeConstant(i);
-
- file.print("</TD></TR>\n");
- }
-
- file.println("</TABLE></BODY></HTML>");
- file.close();
- }
-
- String referenceConstant(int index) {
- return constant_ref[index];
- }
-
- private void writeConstant(int index) {
- byte tag = constants[index].getTag();
- int class_index, name_index;
- String ref;
-
- // The header is always the same
- file.println("<H4> <A NAME=cp" + index + ">" + index + "</A> " + CONSTANT_NAMES[tag] + "</H4>");
-
- /* For every constant type get the needed parameters and print them appropiately
- */
- switch(tag) {
- case CONSTANT_InterfaceMethodref:
- case CONSTANT_Methodref:
- // Get class_index and name_and_type_index, depending on type
- if(tag == CONSTANT_Methodref) {
- ConstantMethodref c = (ConstantMethodref)constant_pool.getConstant(index, CONSTANT_Methodref);
- class_index = c.getClassIndex();
- name_index = c.getNameAndTypeIndex();
- }
- else {
- ConstantInterfaceMethodref c1 = (ConstantInterfaceMethodref)constant_pool.getConstant(index, CONSTANT_InterfaceMethodref);
- class_index = c1.getClassIndex();
- name_index = c1.getNameAndTypeIndex();
- }
-
- // Get method name and its class
- String method_name = constant_pool.constantToString(name_index, CONSTANT_NameAndType);
- String html_method_name = Class2HTML.toHTML(method_name);
-
- // Partially compacted class name, i.e., / -> .
- String method_class = constant_pool.constantToString(class_index, CONSTANT_Class);
- String short_method_class = Utility.compactClassName(method_class); // I.e., remove java.lang.
- short_method_class = Utility.compactClassName(method_class); // I.e., remove java.lang.
- short_method_class = Utility.compactClassName(short_method_class, class_package + ".", true); // Remove class package prefix
-
- // Get method signature
- ConstantNameAndType c2 = (ConstantNameAndType)constant_pool.getConstant(name_index, CONSTANT_NameAndType);
- String signature = constant_pool.constantToString(c2.getSignatureIndex(), CONSTANT_Utf8);
- // Get array of strings containing the argument types
- String[] args = Utility.methodSignatureArgumentTypes(signature, false);
-
- // Get return type string
- String type = Utility.methodSignatureReturnType(signature, false);
- String ret_type = Class2HTML.referenceType(type);
-
- StringBuffer buf = new StringBuffer("(");
- for(int i=0; i < args.length; i++) {
- buf.append(Class2HTML.referenceType(args[i]));
- if(i < args.length - 1)
- buf.append(", ");
- }
- buf.append(")");
-
- String arg_types = buf.toString();
-
- if(method_class.equals(class_name)) // Method is local to class
- ref = "<A HREF=\"" + class_name + "_code.html#method" + getMethodNumber(method_name + signature) +
- "\" TARGET=Code>" + html_method_name + "</A>";
- else
- ref = "<A HREF=\"" + method_class + ".html" + "\" TARGET=_top>" + short_method_class +
- "</A>." + html_method_name;
-
- constant_ref[index] = ret_type + " <A HREF=\"" + class_name + "_cp.html#cp" + class_index +
- "\" TARGET=Constants>" +
- short_method_class + "</A>.<A HREF=\"" + class_name + "_cp.html#cp" +
- index + "\" TARGET=ConstantPool>" + html_method_name + "</A> " + arg_types;
-
- file.println("<P><TT>" + ret_type + " " + ref + arg_types + " </TT>\n<UL>" +
- "<LI><A HREF=\"#cp" + class_index + "\">Class index(" + class_index + ")</A>\n" +
- "<LI><A HREF=\"#cp" + name_index + "\">NameAndType index(" + name_index + ")</A></UL>");
- break;
-
- case CONSTANT_Fieldref:
- // Get class_index and name_and_type_index
- ConstantFieldref c3 = (ConstantFieldref)constant_pool.getConstant(index, CONSTANT_Fieldref);
- class_index = c3.getClassIndex();
- name_index = c3.getNameAndTypeIndex();
-
- // Get method name and its class (compacted)
- String field_class = constant_pool.constantToString(class_index, CONSTANT_Class);
- String short_field_class = Utility.compactClassName(field_class); // I.e., remove java.lang.
- short_field_class = Utility.compactClassName(short_field_class, class_package + ".", true); // Remove class package prefix
-
- String field_name = constant_pool.constantToString(name_index, CONSTANT_NameAndType);
-
- if(field_class.equals(class_name)) // Field is local to class
- ref = "<A HREF=\"" + field_class + "_methods.html#field" +
- field_name + "\" TARGET=Methods>" + field_name + "</A>";
- else
- ref = "<A HREF=\"" + field_class + ".html\" TARGET=_top>" +
- short_field_class + "</A>." + field_name + "\n";
-
- constant_ref[index] = "<A HREF=\"" + class_name + "_cp.html#cp" + class_index + "\" TARGET=Constants>" +
- short_field_class + "</A>.<A HREF=\"" + class_name + "_cp.html#cp" +
- index + "\" TARGET=ConstantPool>" + field_name + "</A>";
-
- file.println("<P><TT>" + ref + "</TT><BR>\n" + "<UL>" +
- "<LI><A HREF=\"#cp" + class_index + "\">Class(" + class_index + ")</A><BR>\n" +
- "<LI><A HREF=\"#cp" + name_index + "\">NameAndType(" + name_index + ")</A></UL>");
- break;
-
- case CONSTANT_Class:
- ConstantClass c4 = (ConstantClass)constant_pool.getConstant(index, CONSTANT_Class);
- name_index = c4.getNameIndex();
- String class_name2 = constant_pool.constantToString(index, tag); // / -> .
- String short_class_name = Utility.compactClassName(class_name2); // I.e., remove java.lang.
- short_class_name = Utility.compactClassName(short_class_name, class_package + ".", true); // Remove class package prefix
-
- ref = "<A HREF=\"" + class_name2 + ".html\" TARGET=_top>" + short_class_name + "</A>";
- constant_ref[index] = "<A HREF=\"" + class_name + "_cp.html#cp" + index +
- "\" TARGET=ConstantPool>" + short_class_name + "</A>";
-
- file.println("<P><TT>" + ref + "</TT><UL>" +
- "<LI><A HREF=\"#cp" + name_index + "\">Name index(" + name_index + ")</A></UL>\n");
- break;
-
- case CONSTANT_String:
- ConstantString c5 = (ConstantString)constant_pool.getConstant(index, CONSTANT_String);
- name_index = c5.getStringIndex();
-
- String str = Class2HTML.toHTML(constant_pool.constantToString(index, tag));
-
- file.println("<P><TT>" + str + "</TT><UL>" +
- "<LI><A HREF=\"#cp" + name_index + "\">Name index(" + name_index + ")</A></UL>\n");
- break;
-
- case CONSTANT_NameAndType:
- ConstantNameAndType c6 = (ConstantNameAndType)constant_pool.getConstant(index, CONSTANT_NameAndType);
- name_index = c6.getNameIndex();
- int signature_index = c6.getSignatureIndex();
-
- file.println("<P><TT>" + Class2HTML.toHTML(constant_pool.constantToString(index, tag)) + "</TT><UL>" +
- "<LI><A HREF=\"#cp" + name_index + "\">Name index(" + name_index + ")</A>\n" +
- "<LI><A HREF=\"#cp" + signature_index + "\">Signature index(" +
- signature_index + ")</A></UL>\n");
- break;
-
- default:
- file.println("<P><TT>" + Class2HTML.toHTML(constant_pool.constantToString(index, tag)) + "</TT>\n");
- } // switch
- }
-
- private final int getMethodNumber(String str) {
- for(int i=0; i < methods.length; i++) {
- String cmp = methods[i].getName() + methods[i].getSignature();
- if(cmp.equals(str))
- return i;
- }
- return -1;
- }
-}
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.lang.reflect.*;
-
-/**
- * Java interpreter replacement, i.e., wrapper that uses its own ClassLoader
- * to modify/generate classes as they're requested. You can take this as a template
- * for your own applications.<br>
- * Call this wrapper with
- * <pre>java org.aspectj.apache.bcel.util.JavaWrapper <real.class.name> [arguments]</pre>
- * <p>
- * To use your own class loader you can set the "bcel.classloader" system property
- * which defaults to "org.aspectj.apache.bcel.util.ClassLoader", e.g., with
- * <pre>java org.aspectj.apache.bcel.util.JavaWrapper -Dbcel.classloader=foo.MyLoader <real.class.name> [arguments]</pre>
- * </p>
- *
- * @version $Id: JavaWrapper.java,v 1.2 2004/11/19 16:45:19 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- * @see ClassLoader
- */
-public class JavaWrapper {
- private java.lang.ClassLoader loader;
-
- private static java.lang.ClassLoader getClassLoader() {
- String s = System.getProperty("bcel.classloader");
-
- if((s == null) || "".equals(s))
- s = "org.aspectj.apache.bcel.util.ClassLoader";
-
- try {
- return (java.lang.ClassLoader)Class.forName(s).newInstance();
- } catch(Exception e) {
- throw new RuntimeException(e.toString());
- }
- }
-
- public JavaWrapper(java.lang.ClassLoader loader) {
- this.loader = loader;
- }
-
- public JavaWrapper() {
- this(getClassLoader());
- }
-
- /** Runs the main method of the given class with the arguments passed in argv
- *
- * @param class_name the fully qualified class name
- * @param argv the arguments just as you would pass them directly
- */
- public void runMain(String class_name, String[] argv) throws ClassNotFoundException
- {
- Class cl = loader.loadClass(class_name);
- Method method = null;
-
- try {
- method = cl.getMethod("main", new Class[] { argv.getClass() });
-
- /* Method main is sane ?
- */
- int m = method.getModifiers();
- Class r = method.getReturnType();
-
- if(!(Modifier.isPublic(m) && Modifier.isStatic(m)) ||
- Modifier.isAbstract(m) || (r != Void.TYPE))
- throw new NoSuchMethodException();
- } catch(NoSuchMethodException no) {
- System.out.println("In class " + class_name +
- ": public static void main(String[] argv) is not defined");
- return;
- }
-
- try {
- method.invoke(null, new Object[] { argv });
- } catch(Exception ex) {
- ex.printStackTrace();
- }
- }
-
- /** Default main method used as wrapper, expects the fully qualified class name
- * of the real class as the first argument.
- */
- public static void main(String[] argv) throws Exception {
- /* Expects class name as first argument, other arguments are by-passed.
- */
- if(argv.length == 0) {
- System.out.println("Missing class name.");
- return;
- }
-
- String class_name = argv[0];
- String[] new_argv = new String[argv.length - 1];
- System.arraycopy(argv, 1, new_argv, 0, new_argv.length);
-
- JavaWrapper wrapper = new JavaWrapper();
- wrapper.runMain(class_name, new_argv);
- }
-}
-
+++ /dev/null
-package org.aspectj.apache.bcel.util;
-
-/* ====================================================================
- * The Apache Software License, Version 1.1
- *
- * Copyright (c) 2001 The Apache Software Foundation. All rights
- * reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. The end-user documentation included with the redistribution,
- * if any, must include the following acknowledgment:
- * "This product includes software developed by the
- * Apache Software Foundation (http://www.apache.org/)."
- * Alternately, this acknowledgment may appear in the software itself,
- * if and wherever such third-party acknowledgments normally appear.
- *
- * 4. The names "Apache" and "Apache Software Foundation" and
- * "Apache BCEL" must not be used to endorse or promote products
- * derived from this software without prior written permission. For
- * written permission, please contact apache@apache.org.
- *
- * 5. Products derived from this software may not be called "Apache",
- * "Apache BCEL", nor may "Apache" appear in their name, without
- * prior written permission of the Apache Software Foundation.
- *
- * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * ====================================================================
- *
- * This software consists of voluntary contributions made by many
- * individuals on behalf of the Apache Software Foundation. For more
- * information on the Apache Software Foundation, please see
- * <http://www.apache.org/>.
- */
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.PrintWriter;
-
-import org.aspectj.apache.bcel.classfile.Attribute;
-import org.aspectj.apache.bcel.classfile.Code;
-import org.aspectj.apache.bcel.classfile.ConstantValue;
-import org.aspectj.apache.bcel.classfile.ExceptionTable;
-import org.aspectj.apache.bcel.classfile.Field;
-import org.aspectj.apache.bcel.classfile.Method;
-import org.aspectj.apache.bcel.classfile.Utility;
-
-/**
- * Convert methods and fields into HTML file.
- *
- * @version $Id: MethodHTML.java,v 1.3 2004/11/22 08:31:27 aclement Exp $
- * @author <A HREF="mailto:markus.dahm@berlin.de">M. Dahm</A>
- *
- */
-final class MethodHTML implements org.aspectj.apache.bcel.Constants {
- private String class_name; // name of current class
- private PrintWriter file; // file to write to
- private ConstantHTML constant_html;
- private AttributeHTML attribute_html;
-
- MethodHTML(String dir, String class_name,
- Method[] methods, Field[] fields,
- ConstantHTML constant_html, AttributeHTML attribute_html) throws IOException
- {
- this.class_name = class_name;
- this.attribute_html = attribute_html;
- this.constant_html = constant_html;
-
- file = new PrintWriter(new FileOutputStream(dir + class_name + "_methods.html"));
-
- file.println("<HTML><BODY BGCOLOR=\"#C0C0C0\"><TABLE BORDER=0>");
- file.println("<TR><TH ALIGN=LEFT>Access flags</TH><TH ALIGN=LEFT>Type</TH>" +
- "<TH ALIGN=LEFT>Field name</TH></TR>");
- for(int i=0; i < fields.length; i++)
- writeField(fields[i]);
- file.println("</TABLE>");
-
- file.println("<TABLE BORDER=0><TR><TH ALIGN=LEFT>Access flags</TH>" +
- "<TH ALIGN=LEFT>Return type</TH><TH ALIGN=LEFT>Method name</TH>" +
- "<TH ALIGN=LEFT>Arguments</TH></TR>");
- for(int i=0; i < methods.length; i++)
- writeMethod(methods[i], i);
-
- file.println("</TABLE></BODY></HTML>");
- file.close();
- }
-
- /**
- * Print field of class.
- *
- * @param field field to print
- * @exception java.io.IOException
- */
- private void writeField(Field field) throws IOException {
- String type = Utility.signatureToString(field.getSignature());
- String name = field.getName();
- String access = Utility.accessToString(field.getAccessFlags());
- Attribute[] attributes;
-
- access = Utility.replace(access, " ", " ");
-
- file.print("<TR><TD><FONT COLOR=\"#FF0000\">" + access + "</FONT></TD>\n<TD>" +
- Class2HTML.referenceType(type) + "</TD><TD><A NAME=\"field" + name + "\">" +
- name + "</A></TD>");
-
- attributes = field.getAttributes();
-
- // Write them to the Attributes.html file with anchor "<name>[<i>]"
- for(int i=0; i < attributes.length; i++)
- attribute_html.writeAttribute(attributes[i], name + "@" + i);
-
- for(int i=0; i < attributes.length; i++) {
- if(attributes[i].getTag() == ATTR_CONSTANT_VALUE) { // Default value
- String str = ((ConstantValue)attributes[i]).toString();
-
- // Reference attribute in _attributes.html
- file.print("<TD>= <A HREF=\"" + class_name + "_attributes.html#" +
- name + "@" + i + "\" TARGET=\"Attributes\">" + str + "</TD>\n");
- break;
- }
- }
-
- file.println("</TR>");
- }
-
- private final void writeMethod(Method method, int method_number) throws IOException {
- // Get raw signature
- String signature = method.getSignature();
- // Get array of strings containing the argument types
- String[] args = Utility.methodSignatureArgumentTypes(signature, false);
- // Get return type string
- String type = Utility.methodSignatureReturnType(signature, false);
- // Get method name
- String name = method.getName(), html_name;
- // Get method's access flags
- String access = Utility.accessToString(method.getAccessFlags());
- // Get the method's attributes, the Code Attribute in particular
- Attribute[] attributes = method.getAttributes();
-
- /* HTML doesn't like names like <clinit> and spaces are places to break
- * lines. Both we don't want...
- */
- access = Utility.replace(access, " ", " ");
- html_name = Class2HTML.toHTML(name);
-
- file.print("<TR VALIGN=TOP><TD><FONT COLOR=\"#FF0000\"><A NAME=method" + method_number + ">" +
- access + "</A></FONT></TD>");
-
- file.print("<TD>" + Class2HTML.referenceType(type) + "</TD><TD>" +
- "<A HREF=" + class_name + "_code.html#method" + method_number +
- " TARGET=Code>" + html_name + "</A></TD>\n<TD>(");
-
- for(int i=0; i < args.length; i++) {
- file.print(Class2HTML.referenceType(args[i]));
- if(i < args.length - 1)
- file.print(", ");
- }
-
- file.print(")</TD></TR>");
-
- // Check for thrown exceptions
- for(int i=0; i < attributes.length; i++) {
- attribute_html.writeAttribute(attributes[i], "method" + method_number + "@" + i,
- method_number);
-
- byte tag = attributes[i].getTag();
- if(tag == ATTR_EXCEPTIONS) {
- file.print("<TR VALIGN=TOP><TD COLSPAN=2></TD><TH ALIGN=LEFT>throws</TH><TD>");
- int[] exceptions = ((ExceptionTable)attributes[i]).getExceptionIndexTable();
-
- for(int j=0; j < exceptions.length; j++) {
- file.print(constant_html.referenceConstant(exceptions[j]));
-
- if(j < exceptions.length - 1)
- file.print(", ");
- }
- file.println("</TD></TR>");
- } else if(tag == ATTR_CODE) {
- Attribute[] c_a = ((Code)attributes[i]).getAttributes();
-
- for(int j=0; j < c_a.length; j++)
- attribute_html.writeAttribute(c_a[j], "method" + method_number + "@" + i + "@" + j,
- method_number);
- }
- }
- }
-}
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:19 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-<p>
-This package contains utility classes for the
-<a href="http://jakarta.apache.org/bcel/">Byte Code Engineering
-Library</a>, namely:
-</p>
-<p>
-<ul>
-<li>Collection classes for JavaClass objects</li>
-<li>A converter for class files to HTML</li>
-<li>A tool to find instructions patterns via regular expressions</li>
-<li>A class to find classes as defined in the CLASSPATH</li>
-<li>A class loader that allows to create clases at run time</li>
-</ul>
-
-</p>
-</body>
-</html>
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:19 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-
-Exception classes used by JustIce, mostly used internally. You don't need to bother with them.
-
-<h2>Package Specification</h2>
-
-Contained in this package are Exception classes for use with the JustIce verifier.
-
-<h2>Related Documentation</h2>
-
-For a simple demonstration of JustIce working, please see:
-<ul>
- <li><a href="http://www.inf.fu-berlin.de/~ehaase/cgi-html/Verifier.html">A WWW front-end for JustIce.</a>
-</ul>
-
-</body>
-</html>
+++ /dev/null
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-<!--
-$Id: package.html,v 1.2 2004/11/19 16:45:19 aclement Exp $
--->
-</head>
-<body bgcolor="white">
-
-Provides a PassVerifier class mostly used internally by JustIce, yielding a control flow graph for public use as
-a nice side effect.
-
-<h2>Package Specification</h2>
-
-Contained in this package is a PassVerifier class for use with the JustIce verifier and its utility classes.
-Only the pass performing what Sun calls "Structural Constraints on Java Virtual Machine Code"
-has a PassVerifier class here. JustIce calls this pass "Pass 3b".
-
-<h2>Related Documentation</h2>
-
-For a simple demonstration of JustIce working, please see:
-<ul>
- <li><a href="http://www.inf.fu-berlin.de/~ehaase/cgi-html/Verifier.html">A WWW front-end for JustIce.</a>
-</ul>
-
-</body>
-</html>