Package japa.parser.ast.type

Examples of japa.parser.ast.type.ReferenceType


     * @param arrayCount
     *            number of arrays or <code>0</code> if is not a array.
     * @return instanceof {@link ReferenceType}
     */
    public static ReferenceType createReferenceType(String name, int arrayCount) {
        return new ReferenceType(new ClassOrInterfaceType(name), arrayCount);
    }
View Full Code Here


     * @param arrayCount
     *            number of arrays or <code>0</code> if is not a array.
     * @return instanceof {@link ReferenceType}
     */
    public static ReferenceType createReferenceType(PrimitiveType type, int arrayCount) {
        return new ReferenceType(type, arrayCount);
    }
View Full Code Here

  @Override
  public Node visit(ReferenceType _n, Object _arg) {
    Type type_ = cloneNodes(_n.getType(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    ReferenceType r = new ReferenceType(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        type_, _n.getArrayCount()
    );
    r.setComment(comment);
    return r;
  }
View Full Code Here

    return r;
  }

  @Override
  public Node visit(WildcardType _n, Object _arg) {
    ReferenceType ext = cloneNodes(_n.getExtends(), _arg);
    ReferenceType sup = cloneNodes(_n.getSuper(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    WildcardType r = new WildcardType(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        ext, sup
View Full Code Here

    return Boolean.TRUE;
  }

  @Override public Boolean visit(final ReferenceType n1, final Node arg) {
    final ReferenceType n2 = (ReferenceType) arg;

    if (n1.getArrayCount() != n2.getArrayCount()) {
      return Boolean.FALSE;
    }

    if (!nodeEquals(n1.getType(), n2.getType())) {
      return Boolean.FALSE;
    }

    return Boolean.TRUE;
  }
View Full Code Here

TOP

Related Classes of japa.parser.ast.type.ReferenceType

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.