com.sun.codemodel
Class JForEach

java.lang.Object
  extended by com.sun.codemodel.JForEach
All Implemented Interfaces:
JStatement

public final class JForEach
extends java.lang.Object
implements JStatement

ForEach Statement This will generate the code for statement based on the new j2se 1.5 j.l.s.

Author:
Bhakti

Constructor Summary
JForEach(JType vartype, java.lang.String variable, JExpression collection)
           
 
Method Summary
 JBlock body()
           
 void state(JFormatter f)
           
 JVar var()
          Returns a reference to the loop variable.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JForEach

public JForEach(JType vartype,
                java.lang.String variable,
                JExpression collection)
Method Detail

var

public JVar var()
Returns a reference to the loop variable.


body

public JBlock body()

state

public void state(JFormatter f)
Specified by:
state in interface JStatement


Copyright © 2005-2011 Sun Microsystems. All Rights Reserved.