Examples of addAload()


Examples of javassist.bytecode.Bytecode.addAload()

    );

    /* local variables | target obj | each oldvalue | */
    final Bytecode code = new Bytecode(constPool, 5, 3);
    // aload_0
    code.addAload( 0 );
    // getfield // get each field
    code.addOpcode( Opcode.GETFIELD );
    final int baseFieldIndex = constPool.addFieldrefInfo( thisClassInfo, finfo.getName(), finfo.getDescriptor() );
    code.addIndex( baseFieldIndex );
    // aload_0
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

    // getfield // get each field
    code.addOpcode( Opcode.GETFIELD );
    final int baseFieldIndex = constPool.addFieldrefInfo( thisClassInfo, finfo.getName(), finfo.getDescriptor() );
    code.addIndex( baseFieldIndex );
    // aload_0
    code.addAload( 0 );
    // invokeinterface : invoke Enabled.getInterceptFieldCallback()
    final int enabledClassIndex = constPool.addClassInfo( FIELD_HANDLED_TYPE_NAME );
    code.addInvokeinterface(
        enabledClassIndex,
        GETFIELDHANDLER_METHOD_NAME,
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

    String cons_desc = "()V";
    MethodInfo mi = new MethodInfo( cp, MethodInfo.nameInit, cons_desc );

    Bytecode code = new Bytecode( cp, 0, 1 );
    // aload_0
    code.addAload( 0 );
    // invokespecial
    code.addInvokespecial( BulkAccessor.class.getName(), MethodInfo.nameInit, cons_desc );
    // return
    code.addOpcode( Opcode.RETURN );
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

    Bytecode code = new Bytecode( cp, 6, 4 );
    /* | this | bean | args | raw bean | */
    if ( getters.length >= 0 ) {
      // aload_1 // load bean
      code.addAload( 1 );
      // checkcast // cast bean
      code.addCheckcast( this.targetBean.getName() );
      // astore_3 // store bean
      code.addAstore( 3 );
      for ( int i = 0; i < getters.length; ++i ) {
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

      code.addAstore( 3 );
      for ( int i = 0; i < getters.length; ++i ) {
        if ( getters[i] != null ) {
          Method getter = getters[i];
          // aload_2 // args
          code.addAload( 2 );
          // iconst_i // continue to aastore
          code.addIconst( i ); // growing stack is 1
          Class returnType = getter.getReturnType();
          int typeIndex = -1;
          if ( returnType.isPrimitive() ) {
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

            // dup
            code.addOpcode( Opcode.DUP );
          }

          // aload_3 // load the raw bean
          code.addAload( 3 );
          String getter_desc = RuntimeSupport.makeDescriptor( getter );
          String getterName = getter.getName();
          if ( this.targetBean.isInterface() ) {
            // invokeinterface
            code.addInvokeinterface( target_type_index, getterName, getter_desc, 1 );
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

      // iconst_0 // i
      code.addIconst( 0 );
      // istore_3 // store i
      code.addIstore( 3 );
      // aload_1 // load the bean
      code.addAload( 1 );
      // checkcast // cast the bean into a raw bean
      code.addCheckcast( this.targetBean.getName() );
      // astore 4 // store the raw bean
      code.addAstore( 4 );
      /* current stack len = 0 */
 
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

            lastIndex = i;
          }
        }
        /* current stack len = 0 */
        // aload 4 // load the raw bean
        code.addAload( 4 );
        // aload_2 // load the args
        code.addAload( 2 );
        // iconst_i
        code.addIconst( i );
        // aaload
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

        }
        /* current stack len = 0 */
        // aload 4 // load the raw bean
        code.addAload( 4 );
        // aload_2 // load the args
        code.addAload( 2 );
        // iconst_i
        code.addIconst( i );
        // aaload
        code.addOpcode( Opcode.AALOAD );
        // checkcast
View Full Code Here

Examples of javassist.bytecode.Bytecode.addAload()

      // new // BulkAccessorException
      code.addNew( BULKEXCEPTION_CLASS_NAME );
      // dup
      code.addOpcode( Opcode.DUP );
      // aload 5 // load exception
      code.addAload( 5 );
      // iload_3 // i
      code.addIload( 3 );
      // invokespecial // BulkAccessorException.<init>
      String cons_desc = "(Ljava/lang/Throwable;I)V";
      code.addInvokespecial( BULKEXCEPTION_CLASS_NAME, MethodInfo.nameInit, cons_desc );
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.