Examples of addMethodrefInfo()


Examples of javassist.bytecode.ConstPool.addMethodrefInfo()

            );
            itr.writeByte( Opcode.INVOKESPECIAL, index );
            itr.write16bit( readMethodIndex, index+1 );
          }
          else {
            final int writeMethodIndex = constPool.addMethodrefInfo(
                constPool.getThisClassInfo(),
                attributeDescriptor.getWriter().getName(),
                attributeDescriptor.getWriter().getSignature()
            );
            itr.writeByte( Opcode.INVOKESPECIAL, index );
View Full Code Here

Examples of javassist.bytecode.ConstPool.addMethodrefInfo()

    String className = cp.getFieldrefClassName(index);
    if ( !filter.handleReadAccess( className, fieldName ) ) {
      return pos;
    }
    String desc = "()" + cp.getFieldrefType( index );
    int read_method_index = cp.addMethodrefInfo(
        cp.getThisClassInfo(),
        EACH_READ_METHOD_PREFIX + fieldName,
        desc
    );
    iter.writeByte(Opcode.INVOKEVIRTUAL, pos);
View Full Code Here

Examples of javassist.bytecode.ConstPool.addMethodrefInfo()

    String className = cp.getFieldrefClassName(index);
    if ( !filter.handleWriteAccess( className, fieldName ) ) {
      return pos;
    }
    String desc = "(" + cp.getFieldrefType( index ) + ")V";
    int write_method_index = cp.addMethodrefInfo(
        cp.getThisClassInfo(),
        EACH_WRITE_METHOD_PREFIX + fieldName,
        desc
    );
    iter.writeByte(Opcode.INVOKEVIRTUAL, pos);
View Full Code Here

Examples of javassist.bytecode.ConstPool.addMethodrefInfo()

          CodeIterator iterator = codeAttribute.iterator();
          int pos = iterator.skipSuperConstructor();
          if (pos >= 0) {
            int mref = iterator.u16bitAt(pos + 1);
            ConstPool constPool = codeAttribute.getConstPool();
            iterator.write16bit(constPool.addMethodrefInfo(constPool.addClassInfo("java.lang.Object"), "<init>", "()V"), pos + 1);
            String desc = constPool.getMethodrefType(mref);
            int num = Descriptor.numOfParameters(desc) + 1;
            pos = iterator.insertGapAt(pos, num, false).position;
            Descriptor.Iterator i$ = new Descriptor.Iterator(desc);
            for (i$.next(); i$.isParameter(); i$.next()) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.