SqlTokenConstants.cs
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace SQLFormatter { class SqlTokenConstants { /** * 項目番号:1<br> * 空文字. TAB,CR等も1つの文字列として含む。 */ public static readonly int SPACE = 0; /** * 項目番号:2<br> * 記号. " <="のような2つで1つの記号もある。 */ public static readonly int SYMBOL = 1; /** * 項目番号:3<br> * キーワード. "SELECT", "ORDER"など. */ public static readonly int KEYWORD = 2; /** * 項目番号:4<br> * 名前. テーブル名、列名など。ダブルクォーテーションが付く場合がある。 */ public static readonly int NAME = 3; /** * 項目番号:5<br> * 値. 数値(整数、実数)、文字列など。 */ public static readonly int VALUE = 4; /** * 項目番号:6<br> * コメント. シングルラインコメントとマルチラインコメントがある。 */ public static readonly int COMMENT = 5; /** * 項目番号:7<br> * SQL文の終わり. */ public static readonly int END = 6; /** * 項目番号:8<br> * 解析不可能なトークン. 通常のSQLではありえない。 */ public static readonly int UNKNOWN = 7; } }