|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface NewArray
A NewArray represents a new array expression such as new
File[8][] { null }. It consists of an element type (e.g.,
File), a list of dimension expressions (e.g., 8), 0 or more
additional dimensions (e.g., 1 for []), and an array initializer. The
dimensions of the array initializer must equal the number of additional "[]"
dimensions.
| Method Summary | |
|---|---|
int |
additionalDims()
The number of additional dimensions. |
NewArray |
additionalDims(int addDims)
Set the number of additional dimensions. |
TypeNode |
baseType()
The array's base type. |
NewArray |
baseType(TypeNode baseType)
Set the array's base type. |
java.util.List |
dims()
List of dimension expressions. |
NewArray |
dims(java.util.List dims)
Set the list of dimension expressions. |
ArrayInit |
init()
The array initializer, or null. |
NewArray |
init(ArrayInit init)
Set the array initializer. |
int |
numDims()
The number of array dimensions. |
| Methods inherited from interface polyglot.ast.Expr |
|---|
constantValue, isConstant, precedence, printSubExpr, printSubExpr, type |
| Methods inherited from interface polyglot.ast.Node |
|---|
childExpectedType, del, del, dump, ext, ext, ext, ext, position, position, visit, visitChild, visitEdge, visitList |
| Methods inherited from interface polyglot.ast.JL |
|---|
init, node |
| Methods inherited from interface polyglot.ast.NodeOps |
|---|
addDecls, addMembers, addMembersEnter, buildTypes, buildTypesEnter, disambiguate, disambiguateEnter, enterScope, enterScope, exceptionCheck, exceptionCheckEnter, prettyPrint, throwTypes, translate, typeCheck, typeCheckEnter, visitChildren |
| Methods inherited from interface polyglot.util.Copy |
|---|
copy |
| Methods inherited from interface polyglot.ast.Typed |
|---|
type |
| Methods inherited from interface polyglot.ast.Term |
|---|
acceptCFG, entry, exceptions, exceptions, reachable, reachable |
| Method Detail |
|---|
TypeNode baseType()
NewArray baseType(TypeNode baseType)
int numDims()
java.util.List dims()
Expr.NewArray dims(java.util.List dims)
dims - A list of Expr.int additionalDims()
NewArray additionalDims(int addDims)
ArrayInit init()
NewArray init(ArrayInit init)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||