annotate Implab/Parsing/IAlphabetBuilder.cs @ 161:2a8466f0cb8a v2

DFA refactoring
author cin
date Fri, 19 Feb 2016 18:07:17 +0300
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
161
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
1 using System;
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
2 using System.Collections.Generic;
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
3
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
4 namespace Implab.Parsing {
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
5 public interface IAlphabetBuilder<TSymbol> : IAlphabet<TSymbol> {
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
6 /// <summary>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
7 /// Добавляет новый символ в алфавит, если символ уже был добавлен, то
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
8 /// возвращается ранее сопоставленный с символом класс.
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
9 /// </summary>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
10 /// <param name="symbol">Символ для добавления.</param>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
11 /// <returns>Индекс класса, который попоставлен с символом.</returns>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
12 int DefineSymbol(TSymbol symbol);
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
13 /// <summary>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
14 /// Доабвляем класс символов. Множеству указанных исходных символов
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
15 /// будет сопоставлен символ в алфавите.
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
16 /// </summary>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
17 /// <param name="symbols">Множестов исходных символов</param>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
18 /// <returns>Идентификатор символа алфавита.</returns>
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
19 int DefineClass(IEnumerable<TSymbol> symbols);
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
20
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
21
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
22
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
23 }
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
24 }
2a8466f0cb8a DFA refactoring
cin
parents:
diff changeset
25