uk.co.badgersinfoil.metaas.dom
Interface ASDeclarationStatement

All Superinterfaces:
ScriptElement, Statement

public interface ASDeclarationStatement
extends Statement

A statement that declares variables, such as var a = 1;.

A declaration-statement may declare multiple variables, each optionally specifying a type and an initialiser-value.

See Also:
StatementContainer.newDeclaration(Expression)

Method Summary
 Expression getFirstVarInitializer()
           
 java.lang.String getFirstVarName()
           
 java.lang.String getFirstVarTypeName()
           
 java.util.List getVars()
          Returns a list of ASVarDeclarationFragment objects.
 boolean isConstant()
          Returns false if this is a declaration using the var keyword (the default), and true is this is a declaration using the const keyword.
 void setConstant(boolean constant)
          If given true, this declaration will use the const keyword, if given false, this declaration will use the var keyword.
 

Method Detail

isConstant

boolean isConstant()
Returns false if this is a declaration using the var keyword (the default), and true is this is a declaration using the const keyword.


setConstant

void setConstant(boolean constant)
If given true, this declaration will use the const keyword, if given false, this declaration will use the var keyword.


getVars

java.util.List getVars()
Returns a list of ASVarDeclarationFragment objects.


getFirstVarName

java.lang.String getFirstVarName()

getFirstVarTypeName

java.lang.String getFirstVarTypeName()

getFirstVarInitializer

Expression getFirstVarInitializer()


Copyright © 2006-2008 David Holroyd. All Rights Reserved.