1
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
2
// This code is distributed under MIT X11 license (for details please see \doc\license.txt)
7
namespace ICSharpCode.NRefactory.VB.Ast
12
public class ThrowStatement : Statement
14
public VBTokenNode ThrowToken {
15
get { return GetChildByRole (Roles.Keyword); }
18
public Expression Expression {
19
get { return GetChildByRole(Roles.Expression); }
20
set { SetChildByRole(Roles.Expression, value); }
23
public ThrowStatement()
27
public ThrowStatement(Expression expression)
29
AddChild (expression, Roles.Expression);
32
public override S AcceptVisitor<T, S>(IAstVisitor<T, S> visitor, T data)
34
return visitor.VisitThrowStatement(this, data);
37
protected internal override bool DoMatch(AstNode other, PatternMatching.Match match)
39
ThrowStatement o = other as ThrowStatement;
40
return o != null && this.Expression.DoMatch(o.Expression, match);