// // Copyright (c) Microsoft. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. // namespace Microsoft.SqlTools.ServiceLayer.BatchParser { internal sealed class Token { /// /// Token class used by the lexer in Batch Parser /// internal Token(LexerTokenType tokenType, PositionStruct begin, PositionStruct end, string text, string filename) { TokenType = tokenType; Begin = begin; End = end; Text = text; Filename = filename; } /// /// Get file name associated with Token /// public string Filename { get; private set; } /// /// Get beginning position for the Token /// public PositionStruct Begin { get; private set; } /// /// Get end position for the Token /// public PositionStruct End { get; private set; } /// /// Get text assocaited with the Token /// public string Text { get; private set; } /// /// Get token type of the Token /// public LexerTokenType TokenType { get; private set; } } }