| de.uka.ilkd.key.java.expression.operator.TypeOperator de.uka.ilkd.key.java.expression.operator.NewArray
NewArray | public class NewArray extends TypeOperator implements Reference,ReferencePrefix(Code) | | The array allocation operator.
There are two variants for NewArray:
- Ordinary array construction
new XYZ[d1]...[dn]
- Initialized array construction
new XYZ[]...[] { a1, ..., an }
Contrary to an ordinary New, a NewArray is no ConstructorReference (since
all ArrayType constructors are predefined) and is not used as a Statement
(since there are no sideeffects in the constructor). No access path is
required for new, since there is no inner class problem.
NewArray has either a list of dimension length expressions, or
a single ArrayInitializer.
|
dimensions | final protected int dimensions(Code) | | Dimensions.
|
NewArray | public NewArray(ExtList children, KeYJavaType keyJavaType, ArrayInitializer init, int dimensions)(Code) | | New array.
Parameters: children - an ExtList with the children of this node (remove the ArrayInitializer out of the list). Parameters: init - the arrayInitializer Parameters: dimensions - an int value. |
NewArray | public NewArray(Expression[] arguments, TypeReference typeRef, KeYJavaType keyJavaType, ArrayInitializer init, int dimensions)(Code) | | New array.
Parameters: arguments - an array of expressions describing thedimensions Parameters: typeRef - a reference to the arraytype Parameters: init - the arrayInitializer Parameters: dimensions - an int value. |
getArity | public int getArity()(Code) | | Get arity.
the int value. |
getArrayInitializer | public ArrayInitializer getArrayInitializer()(Code) | | Get array initializer.
the array initializer. |
getChildAt | public ProgramElement getChildAt(int index)(Code) | | Returns the child at the specified index in this node's "virtual"
child array
Parameters: index - an index into this node's "virtual" child array the program element at the given position exception: ArrayIndexOutOfBoundsException - if index is outof bounds |
getChildCount | public int getChildCount()(Code) | | Returns the number of children of this node.
an int giving the number of children of this node |
getDimensions | public int getDimensions()(Code) | | Get dimensions.
the int value. |
getExpressionCount | public int getExpressionCount()(Code) | | Get the number of expressions in this container.
the number of expressions. |
getNotation | public int getNotation()(Code) | | Get notation.
the int value. |
getPrecedence | public int getPrecedence()(Code) | | Get precedence.
the int value. |
getReferencePrefix | public ReferencePrefix getReferencePrefix()(Code) | | We do not have a prefix, so fake it!
This way we implement ReferencePrefix
author: VK |
visit | public void visit(Visitor v)(Code) | | calls the corresponding method of a visitor in order to
perform some action/transformation on this element
Parameters: v - the Visitor |
|
|