annotate Implab/Parsing/EndToken.cs @ 133:6c49d02a9a05 v2

sync
author cin
date Mon, 09 Feb 2015 00:28:13 +0300
parents c0bf853aa04f
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
55
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
1 using Implab;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
2 using System;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
3 using System.Collections.Generic;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
4 using System.Linq;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
5 using System.Text;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
6 using System.Threading.Tasks;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
7
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
8 namespace Implab.Parsing {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
9 /// <summary>
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
10 /// Конечный символ расширенного регулярного выражения, при построении ДКА
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
11 /// используется для определения конечных состояний.
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
12 /// </summary>
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
13 public class EndToken: Token {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
14
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
15 int m_tag;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
16
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
17 public EndToken(int tag) {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
18 m_tag = tag;
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
19 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
20
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
21 public EndToken()
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
22 : this(0) {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
23 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
24
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
25 public int Tag {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
26 get { return m_tag; }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
27 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
28
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
29 public override void Accept(IVisitor visitor) {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
30 Safe.ArgumentNotNull(visitor, "visitor");
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
31 visitor.Visit(this);
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
32 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
33 public override string ToString() {
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
34 return "#";
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
35 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
36 }
c0bf853aa04f Added initial JSON support
cin
parents:
diff changeset
37 }