Examples of JCTypeApply


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

    // e.g. Ordering
    JCIdent orderingIdent = (JCIdent)
        ((JCFieldAccess) ((JCMethodInvocation) methodInvocation).meth).selected;
    // e.g. Ordering<String>
    JCTypeApply newOrderingType = state.getTreeMaker().TypeApply(orderingIdent,
        ((JCTypeApply) newComparatorInvocation.clazz).arguments);

    // Find the class definition and remove the default constructor (it confuses the pretty printer)
    JCClassDecl def = newComparatorInvocation.def;
View Full Code Here

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

      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;
      name = pt.getType().toString();
      parameters = new ArrayList<VarType>();
     
      for(JCExpression t : pt.getTypeArguments()) {
        parameters.add(new VarType(t));
      }
    } else if(type instanceof JCWildcard) {
      JCWildcard wt = (JCWildcard)type;
      if(null == wt.getBound()) name = "?"; else init(wt.getBound());
View Full Code Here

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

                    List<JCTree> newPath = path.tail;

                    if (((JCTypeApply)frame).clazz == tree) {
                        // generic: RAW; noop
                    } else if (((JCTypeApply)frame).arguments.contains(tree)) {
                        JCTypeApply taframe = (JCTypeApply) frame;
                        int arg = taframe.arguments.indexOf(tree);
                        p.location = p.location.prepend(new TypePathEntry(TypePathEntryKind.TYPE_ARGUMENT, arg));

                        Type typeToUse;
                        if (newPath.tail != null && newPath.tail.head.hasTag(Tag.NEWCLASS)) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.