/NRefactory/ICSharpCode.NRefactory.VB/Ast/Statements/ForStatement.cs

http://github.com/icsharpcode/ILSpy · C# · 45 lines · 35 code · 8 blank · 2 comment · 0 complexity · 7d7e358f5cb59ce2a13972cd3b1f639d MD5 · raw file

  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)
  3. using System;
  4. using System.IO;
  5. namespace ICSharpCode.NRefactory.VB.Ast
  6. {
  7. public class ForStatement : Statement
  8. {
  9. public static readonly Role<AstNode> VariableRole = new Role<AstNode>("Variable", AstNode.Null);
  10. public static readonly Role<Expression> ToExpressionRole = new Role<Expression>("ToExpression", Expression.Null);
  11. public static readonly Role<Expression> StepExpressionRole = new Role<Expression>("StepExpression", Expression.Null);
  12. public AstNode Variable {
  13. get { return GetChildByRole(VariableRole); }
  14. set { SetChildByRole(VariableRole, value); }
  15. }
  16. public Expression ToExpression {
  17. get { return GetChildByRole(ToExpressionRole); }
  18. set { SetChildByRole(ToExpressionRole, value); }
  19. }
  20. public Expression StepExpression {
  21. get { return GetChildByRole(StepExpressionRole); }
  22. set { SetChildByRole(StepExpressionRole, value); }
  23. }
  24. public BlockStatement Body {
  25. get { return GetChildByRole(Roles.Body); }
  26. set { SetChildByRole(Roles.Body, value); }
  27. }
  28. protected internal override bool DoMatch(AstNode other, ICSharpCode.NRefactory.PatternMatching.Match match)
  29. {
  30. throw new NotImplementedException();
  31. }
  32. public override S AcceptVisitor<T, S>(IAstVisitor<T, S> visitor, T data)
  33. {
  34. return visitor.VisitForStatement(this, data);
  35. }
  36. }
  37. }