Package japa.parser.ast.comments

Examples of japa.parser.ast.comments.Comment


  public Node visit(ForStmt _n, Object _arg) {
    List<Expression> init = visit(_n.getInit(), _arg);
    Expression compare = cloneNodes(_n.getCompare(), _arg);
    List<Expression> update = visit(_n.getUpdate(), _arg);
    Statement body = cloneNodes(_n.getBody(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    ForStmt r = new ForStmt(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        init, compare, update, body
    );
View Full Code Here


  }

  @Override
  public Node visit(ThrowStmt _n, Object _arg) {
    Expression expr = cloneNodes(_n.getExpr(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    ThrowStmt r = new ThrowStmt(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        expr
    );
View Full Code Here

  @Override
  public Node visit(SynchronizedStmt _n, Object _arg) {
    Expression expr = cloneNodes(_n.getExpr(), _arg);
    BlockStmt block = cloneNodes(_n.getBlock(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    SynchronizedStmt r = new SynchronizedStmt(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        expr, block
    );
View Full Code Here

  public Node visit(TryStmt _n, Object _arg) {
    List<VariableDeclarationExpr> resources = visit(_n.getResources(),_arg);
    BlockStmt tryBlock = cloneNodes(_n.getTryBlock(), _arg);
    List<CatchClause> catchs = visit(_n.getCatchs(), _arg);
    BlockStmt finallyBlock = cloneNodes(_n.getFinallyBlock(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    TryStmt r = new TryStmt(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        resources, tryBlock, catchs, finallyBlock
    );
View Full Code Here

  @Override
  public Node visit(CatchClause _n, Object _arg) {
    MultiTypeParameter except = cloneNodes(_n.getExcept(), _arg);
    BlockStmt catchBlock = cloneNodes(_n.getCatchBlock(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    CatchClause r = new CatchClause(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        except.getModifiers(), except.getAnnotations(), except.getTypes(), except.getId(), catchBlock
    );
View Full Code Here

  @Override
  public Node visit(PackageDeclaration _n, Object _arg) {
    List<AnnotationExpr> annotations = visit(_n.getAnnotations(), _arg);
    NameExpr name = cloneNodes(_n.getName(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    PackageDeclaration r = new PackageDeclaration(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        annotations, name
    );
View Full Code Here

  }

  @Override
  public Node visit(ImportDeclaration _n, Object _arg) {
    NameExpr name = cloneNodes(_n.getName(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    ImportDeclaration r = new ImportDeclaration(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        name, _n.isStatic(), _n.isAsterisk()
    );
View Full Code Here

  }

  @Override
  public Node visit(TypeParameter _n, Object _arg) {
    List<ClassOrInterfaceType> typeBound = visit(_n.getTypeBound(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    TypeParameter r = new TypeParameter(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        _n.getName(), typeBound
    );
View Full Code Here

    List<AnnotationExpr> annotations = visit(_n.getAnnotations(), _arg);
    List<TypeParameter> typeParameters = visit(_n.getTypeParameters(), _arg);
    List<ClassOrInterfaceType> extendsList = visit(_n.getExtends(), _arg);
    List<ClassOrInterfaceType> implementsList = visit(_n.getImplements(), _arg);
    List<BodyDeclaration> members = visit(_n.getMembers(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    ClassOrInterfaceDeclaration r = new ClassOrInterfaceDeclaration(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
        _n.getModifiers(), annotations, _n.isInterface(), _n.getName(), typeParameters, extendsList, implementsList, members
    );
View Full Code Here

    JavadocComment javaDoc = cloneNodes(_n.getJavaDoc(), _arg);
    List<AnnotationExpr> annotations = visit(_n.getAnnotations(), _arg);
    List<ClassOrInterfaceType> implementsList = visit(_n.getImplements(), _arg);
    List<EnumConstantDeclaration> entries = visit(_n.getEntries(), _arg);
    List<BodyDeclaration> members = visit(_n.getMembers(), _arg);
    Comment comment = cloneNodes(_n.getComment(), _arg);

    EnumDeclaration r = new EnumDeclaration(
        _n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(),
         _n.getModifiers(), annotations, _n.getName(), implementsList, entries, members
    );
View Full Code Here

TOP

Related Classes of japa.parser.ast.comments.Comment

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.