Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

nice.tools.code
Class IncrementProc  view IncrementProc download IncrementProc.java

java.lang.Object
  extended bygnu.mapping.Procedure
      extended bygnu.mapping.Procedure1
          extended bynice.tools.code.IncrementProc
All Implemented Interfaces:
gnu.expr.Inlineable, gnu.mapping.Named

public class IncrementProc
extends gnu.mapping.Procedure1
implements gnu.expr.Inlineable

Increment the value of an object field. Returns either the old or the new value.


Field Summary
private  gnu.expr.Declaration fieldDecl
           
private  boolean increment
           
private  boolean returnOld
           
 
Fields inherited from class gnu.mapping.Procedure
 
Constructor Summary
IncrementProc(gnu.expr.Declaration field, boolean returnOld, boolean increment)
           
 
Method Summary
 java.lang.Object apply1(java.lang.Object arg1)
           
 void compile(gnu.expr.ApplyExp exp, gnu.expr.Compilation comp, gnu.expr.Target target)
           
 gnu.bytecode.Type getReturnType(gnu.expr.Expression[] args)
           
 
Methods inherited from class gnu.mapping.Procedure1
apply0, apply2, apply3, apply4, applyN, numArgs
 
Methods inherited from class gnu.mapping.Procedure
apply, checkArgCount, getName, getProperty, getSetter, maxArgs, minArgs, name, removeProperty, set0, set1, setN, setName, setProperty, setProperty, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

fieldDecl

private gnu.expr.Declaration fieldDecl

increment

private boolean increment

returnOld

private boolean returnOld
Constructor Detail

IncrementProc

public IncrementProc(gnu.expr.Declaration field,
                     boolean returnOld,
                     boolean increment)
Method Detail

compile

public void compile(gnu.expr.ApplyExp exp,
                    gnu.expr.Compilation comp,
                    gnu.expr.Target target)
Specified by:
compile in interface gnu.expr.Inlineable

getReturnType

public gnu.bytecode.Type getReturnType(gnu.expr.Expression[] args)
Specified by:
getReturnType in interface gnu.expr.Inlineable

apply1

public java.lang.Object apply1(java.lang.Object arg1)