Examples of GETFIELD


Examples of org.apache.bcel.generic.GETFIELD

           Util.getJCRefType(DOM_INTF_SIG),
           null, null);
  final String className = classGen.getClassName();
  il.append(filterGen.loadTranslet());
  il.append(new CHECKCAST(cpg.addClass(className)));
  il.append(new GETFIELD(cpg.addFieldref(className,
                 DOM_FIELD, DOM_INTF_SIG)));
  il.append(new ASTORE(local.getIndex()));

  // Store the dom index in the test generator
  testGen.setDomIndex(local.getIndex());
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

      }

      // Use getfield if in an inner class
      if (variableClosure != null) {
    il.append(ALOAD_0);
    il.append(new GETFIELD(
        cpg.addFieldref(variableClosure.getInnerClassName(),
      var.getVariable(), varType.toSignature())));
      }
      else {
    // Use a load of instruction if in translet class
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

     
      il.append(DUP);

      // Get field from factory class
      il.append(ALOAD_0);
      il.append(new GETFIELD(
    cpg.addFieldref(className,
        var.getEscapedName(), varType.toSignature())));

      // Put field in record class
      il.append(new PUTFIELD(
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

                 "topLevel",
                 topLevelSig);
      // Push all parameters on the stack and call topLevel()
      il.append(classGen.loadTranslet()); // The 'this' pointer
      il.append(classGen.loadTranslet());
      il.append(new GETFIELD(domField))// The DOM reference
      il.append(transf.loadIterator());
      il.append(transf.loadHandler());    // The output handler
      il.append(new INVOKEVIRTUAL(topLevelIdx));
 

  // start document
  il.append(transf.loadHandler());
  il.append(transf.startDocument());

  // push first arg for applyTemplates
  il.append(classGen.loadTranslet());
  // push translet for GETFIELD to get DOM arg
  il.append(classGen.loadTranslet());
  il.append(new GETFIELD(domField));
  // push remaining 2 args
  il.append(transf.loadIterator());
  il.append(transf.loadHandler());
  il.append(new INVOKEVIRTUAL(applyTemplates));
  // endDocument
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

                                // method to copy the value from a field in
                                // CopyLocals to the new local in the outlined
                                // method
                                newMethCopyInIL.append(
                                        InstructionConstants.ALOAD_1);
                                newMethCopyInIL.append(new GETFIELD(fieldRef));
                                newMethCopyInIL.append(
                                        storeLocal(newLocalVarIndex, varType));
                            }

                            if (copyOutLocalValue) {
                                // Generate code for the end of the outlined
                                // method to copy the value from the new local
                                // variable into a field in CopyLocals
                                // method
                                newMethCopyOutIL.append(
                                        InstructionConstants.ALOAD_1);
                                newMethCopyOutIL.append(
                                        loadLocal(newLocalVarIndex, varType));
                                newMethCopyOutIL.append(new PUTFIELD(fieldRef));

                                // Generate code to copy the value from a field
                                // in CopyLocals into a local in the original
                                // method following invocation of the outlined
                                // method.
                                oldMethCopyOutIL.append(
                                        InstructionConstants.DUP);
                                oldMethCopyOutIL.append(new GETFIELD(fieldRef));
                                InstructionHandle copyOutStore =
                                    oldMethCopyOutIL.append(
                                        storeLocal(oldLocalVarIndex, varType));

                                // If the start of the live range of the old
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

    il.append(new INVOKESPECIAL(index));
      }
      else {
    // Push name arrays on the stack
    il.append(ALOAD_0);
    il.append(new GETFIELD(cpg.addFieldref(TRANSLET_CLASS,
             NAMES_INDEX,
             NAMES_INDEX_SIG)));
    il.append(ALOAD_0);
    il.append(new GETFIELD(cpg.addFieldref(TRANSLET_CLASS,
             URIS_INDEX,
             URIS_INDEX_SIG)));
    il.append(ALOAD_0);
    il.append(new GETFIELD(cpg.addFieldref(TRANSLET_CLASS,
             TYPES_INDEX,
             TYPES_INDEX_SIG)));
    il.append(ALOAD_0);
    il.append(new GETFIELD(cpg.addFieldref(TRANSLET_CLASS,
             NAMESPACE_INDEX,
             NAMESPACE_INDEX_SIG)));

    // Initialized DOM adapter
    il.append(new INVOKESPECIAL(index));
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

               DOM_INTF_SIG);

  buildKeys.addException("org.apache.xalan.xsltc.TransletException");

  il.append(classGen.loadTranslet());
  il.append(new GETFIELD(domField))// The DOM reference
  il.append(new ASTORE(1));
 
  final Enumeration elements = elements();
  // Compile code for other top-level elements
  while (elements.hasMoreElements()) {
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

  final String keySig = compileBuildKeys(classGen);
  final int    keyIdx = cpg.addMethodref(getClassName(),
                 "buildKeys", keySig);
  il.append(classGen.loadTranslet());     // The 'this' pointer
  il.append(classGen.loadTranslet());
  il.append(new GETFIELD(domField));      // The DOM reference
  il.append(transf.loadIterator());       // Not really used, but...
  il.append(transf.loadHandler());        // The output handler
  il.append(new PUSH(cpg, DOM.ROOTNODE)); // Start with the root node
  il.append(new INVOKEVIRTUAL(keyIdx));

  // Look for top-level elements that need handling
  final Enumeration toplevel = elements();
  if ((_globals.size() > 0) || (toplevel.hasMoreElements())) {
      // Compile method for handling top-level elements
      final String topLevelSig = compileTopLevel(classGen, toplevel);
      // Get a reference to that method
      final int topLevelIdx = cpg.addMethodref(getClassName(),
                 "topLevel",
                 topLevelSig);
      // Push all parameters on the stack and call topLevel()
      il.append(classGen.loadTranslet()); // The 'this' pointer
      il.append(classGen.loadTranslet());
      il.append(new GETFIELD(domField))// The DOM reference
      il.append(transf.loadIterator());
      il.append(transf.loadHandler());    // The output handler
      il.append(new INVOKEVIRTUAL(topLevelIdx));
  }
 
  // start document
  il.append(transf.loadHandler());
  il.append(transf.startDocument());

  // push first arg for applyTemplates
  il.append(classGen.loadTranslet());
  // push translet for GETFIELD to get DOM arg
  il.append(classGen.loadTranslet());
  il.append(new GETFIELD(domField));
  // push remaining 2 args
  il.append(transf.loadIterator());
  il.append(transf.loadHandler());
  il.append(new INVOKEVIRTUAL(applyTemplates));
  // endDocument
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

                          fi = (FieldInstruction)iS.current();
                          if((fi instanceof GETFIELD) && (fi.getClassName(cpg)+'.'+fi.getFieldName(cpg)).equals(character.className+'.'+anim)){
                            count++;
                            if(count==2){
                              while(iS.nextGETFIELD() != null){
                                GETFIELD gf = ((GETFIELD)iS.current());
                                if(gf.getClassName(cpg).equals(character.className)){
                                  character.addField("Motion", gf.getFieldName(cpg));
                                  return SearchResult.Success;
                                }
                              }
                            }
                          }
View Full Code Here

Examples of org.apache.bcel.generic.GETFIELD

     
      il.append(DUP);

      // Get field from factory class
      il.append(ALOAD_0);
      il.append(new GETFIELD(
    cpg.addFieldref(className,
        var.getEscapedName(), varType.toSignature())));

      // Put field in record class
      il.append(new PUTFIELD(
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.