ASTFieldDeclaration extends AbstractJavaAccessTypeNode implements Dimensionable, SignedNode<ASTFieldDeclaration>, Iterable<ASTVariableDeclaratorId> { @Override @Deprecated public int getArrayDepth() { if (!isArray()) { return 0; } return checkType() + checkDecl(); } @InternalApi @Deprecated  ASTFieldDeclaration(int id); @InternalApi @Deprecated  ASTFieldDeclaration(JavaParser p, int id); @Override Object jjtAccept(JavaParserVisitor visitor, Object data); boolean isSyntacticallyPublic(); @Override boolean isPublic(); boolean isSyntacticallyStatic(); @Override boolean isStatic(); boolean isSyntacticallyFinal(); @Override boolean isFinal(); @Override boolean isPrivate(); @Override boolean isPackagePrivate(); @Override boolean isProtected(); boolean isAnnotationMember(); boolean isInterfaceMember(); @Override @Deprecated boolean isArray(); @Override @Deprecated int getArrayDepth(); @Deprecated @DeprecatedAttribute(replaceWith = "VariableDeclaratorId/@Name") String getVariableName(); @Override JavaFieldSignature getSignature(); @Override Iterator<ASTVariableDeclaratorId> iterator(); @Override @Deprecated Class<?> getType(); @Override @Deprecated JavaTypeDefinition getTypeDefinition();  }
@Test public void testMultiDimensionalArray() { ASTCompilationUnit cu = java.parse(TEST2); Dimensionable node = cu.findDescendantsOfType(ASTFieldDeclaration.class).get(0); assertEquals(3, node.getArrayDepth()); }