Package com.sun.tools.javac.tree.JCTree

Examples of com.sun.tools.javac.tree.JCTree.JCArrayTypeTree


  private void init(JCTree type) {
    if(isSimpleType(type)) {
      name = type.toString();
    } else if(type instanceof JCArrayTypeTree) {
      JCArrayTypeTree at = (JCArrayTypeTree)type;
      name = ARRAY;
      parameters = new ArrayList<VarType>(1);
      parameters.add(new VarType(at.elemtype));
    } else if(isParameterizedType(type)) {
      JCTypeApply pt = (JCTypeApply)type;
View Full Code Here


      entry.astArrayDimensions(extraDims);
      entry.astName(setPos(varDecl, new Identifier().astValue(varDecl.name.toString())));
      entry.rawInitializer(toTree(varDecl.init));
      setPos(varDecl, entry);
      if (extraDims > 0) {
        JCArrayTypeTree arrayType = (JCArrayTypeTree) varDecl.vartype;
        for (int i = 0; i < extraDims; i++) {
          if (arrayType != null) setConversionPositionInfo(entry, "[]" + (extraDims - i - 1), getPosition(arrayType));
          arrayType = arrayType.elemtype instanceof JCArrayTypeTree ? (JCArrayTypeTree) arrayType.elemtype : null;
        }
        }
View Full Code Here

TOP

Related Classes of com.sun.tools.javac.tree.JCTree.JCArrayTypeTree

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.