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)
5
using System.Collections.Generic;
7
namespace ICSharpCode.NRefactory.VB.Ast
10
/// Represents a named argument passed to a method or attribute.
12
public class NamedArgumentExpression : Expression
14
public Identifier Identifier {
15
get { return GetChildByRole(Roles.Identifier); }
16
set { SetChildByRole(Roles.Identifier, value); }
19
public VBTokenNode AssignToken {
20
get { return GetChildByRole (Roles.Assign); }
23
public Expression Expression {
24
get { return GetChildByRole (Roles.Expression); }
25
set { SetChildByRole (Roles.Expression, value); }
28
public override S AcceptVisitor<T, S>(IAstVisitor<T, S> visitor, T data)
30
return visitor.VisitNamedArgumentExpression(this, data);
33
protected internal override bool DoMatch(AstNode other, PatternMatching.Match match)
35
NamedArgumentExpression o = other as NamedArgumentExpression;
36
return o != null && this.Identifier.DoMatch(o.Identifier, match) && this.Expression.DoMatch(o.Expression, match);