﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace BadMishka.DocumentFormat.LuceneIndex.Generated
{
    /// <summary>
    /// Class Token.
    /// </summary>
    public class JavaCcToken
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="JavaCcToken"/> class.
        /// </summary>
        /// <param name="kind">The kind.</param>
        /// <param name="image">The image.</param>
        public JavaCcToken(int kind = 0, string image = null)
        {
            this.Kind = kind;
            this.Image = image;
        }

        /// <summary>
        /// Gets or sets the kind.
        /// </summary>
        /// <value>The kind.</value>
        public virtual int Kind { get; set; }

        /// <summary>
        /// Gets or sets the begin line.
        /// </summary>
        /// <value>The begin line.</value>
        public virtual int BeginLine { get; set; }

        /// <summary>
        /// Gets or sets the begin line.
        /// </summary>
        /// <value>The begin line.</value>
        public virtual int BeginColumn { get; set; }

        /// <summary>
        /// Gets or sets the end line.
        /// </summary>
        /// <value>The end line.</value>
        public virtual int EndLine { get; set; }

        /// <summary>
        /// Gets or sets the end column.
        /// </summary>
        /// <value>The end column.</value>
        public virtual int EndColumn { get; set; }

        /// <summary>
        /// Gets or sets the image.
        /// </summary>
        /// <value>The image.</value>
        public virtual string Image { get; set; }

        /// <summary>
        /// Gets or sets the next.
        /// </summary>
        /// <value>The next.</value>
        public virtual JavaCcToken Next { get; set; }

        /// <summary>
        /// Gets or sets the special token.
        /// </summary>
        /// <value>The special token.</value>
        public virtual JavaCcToken SpecialToken { get; set; }

        /// <summary>
        /// Gets or sets the value.
        /// </summary>
        /// <value>The value.</value>
        public virtual string Value { get; set; }

        /// <summary>
        /// Creates the token.
        /// </summary>
        /// <param name="kind">The kind.</param>
        /// <param name="image">The image.</param>
        /// <returns>A new <see cref="Token"/></returns>
        public static JavaCcToken CreateToken(int kind, string image)
        {
            switch (kind)
            {
                default:
                    return new JavaCcToken(kind, image);
            }
        }

        /// <summary>
        /// Creates the token.
        /// </summary>
        /// <param name="kind">The kind.</param>
        /// <returns>A new <see cref="Token"/></returns>
        public static JavaCcToken CreateToken(int kind)
        {
            return new JavaCcToken(kind, null);
        }

        /// <summary>
        /// Returns a <see cref="System.String" /> that represents this instance.
        /// </summary>
        /// <returns>A <see cref="System.String" /> that represents this instance.</returns>
        public override string ToString()
        {
            return this.Image;
        }
    }
}
