本文整理汇总了Java中org.walkmod.javalang.ast.stmt.ThrowStmt类的典型用法代码示例。如果您正苦于以下问题:Java ThrowStmt类的具体用法?Java ThrowStmt怎么用?Java ThrowStmt使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ThrowStmt类属于org.walkmod.javalang.ast.stmt包,在下文中一共展示了ThrowStmt类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public void visit(ThrowStmt n, VisitorContext ctx) {
Object o = ctx.get(NODE_TO_COMPARE_KEY);
if (o != null && o instanceof ThrowStmt) {
ThrowStmt aux = (ThrowStmt) o;
boolean backup = isUpdated();
setIsUpdated(false);
inferASTChanges(n.getExpr(), aux.getExpr());
if (!isUpdated()) {
increaseUnmodifiedNodes(ThrowStmt.class);
} else {
increaseUpdatedNodes(ThrowStmt.class);
}
setIsUpdated(backup || isUpdated());
} else if (o != null) {
setIsUpdated(true);
applyUpdate(n, (Node) o);
}
}
示例2: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public Boolean visit(ThrowStmt n1, Node arg) {
ThrowStmt n2 = (ThrowStmt) arg;
if (!nodeEquals(n1.getExpr(), n2.getExpr())) {
return Boolean.FALSE;
}
return Boolean.TRUE;
}
示例3: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public void visit(ThrowStmt n, Object arg) {
prepareComments(n);
printPreviousComments(n, arg);
printer.print("throw ");
n.getExpr().accept(this, arg);
printer.print(";");
}
示例4: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public void visit(ThrowStmt n, VisitorContext arg) {
if (preVisitor != null) {
preVisitor.visit(n, arg);
}
super.visit(n, arg);
if (postVisitor != null) {
postVisitor.visit(n, arg);
}
}
示例5: ThrowStatement
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
final public ThrowStmt ThrowStatement() throws ParseException {
Expression expr;
int line;
int column;
jj_consume_token(THROW);
line = token.beginLine;
column = token.beginColumn;
expr = Expression();
jj_consume_token(SEMICOLON);
{
if (true)
return new ThrowStmt(line, column, token.endLine, token.endColumn, expr);
}
throw new Error("Missing return statement in function");
}
示例6: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
@Override
public void visit(ThrowStmt n, A arg) {
n.getExpr().accept(expressionTypeAnalyzer, arg);
n.setSymbolData(null);
}
示例7: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public R visit(ThrowStmt n, A arg) {
n.getExpr().accept(this, arg);
return null;
}
示例8: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
@Override
public Node visit(ThrowStmt _n, Object _arg) {
Expression expr = cloneNodes(_n.getExpr(), _arg);
ThrowStmt r = new ThrowStmt(_n.getBeginLine(), _n.getBeginColumn(), _n.getEndLine(), _n.getEndColumn(), expr);
return r;
}
示例9: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public void visit(ThrowStmt n, A arg) {
n.getExpr().accept(this, arg);
}
示例10: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public Node visit(ThrowStmt n, A arg) {
n.setExpr((Expression) n.getExpr().accept(this, arg));
return n;
}
示例11: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public R visit(ThrowStmt n, A arg);
示例12: visit
import org.walkmod.javalang.ast.stmt.ThrowStmt; //导入依赖的package包/类
public void visit(ThrowStmt n, A arg);