
//namespace SE0085.StCl
namespace FAS_LIB
{
    public class scLevels
    {
        private int _LevelId;
        private int _LevelParentId;
        private string _LevelAbbrv;
        private string _LevelName;
        private byte _LevelValue;
        private byte _LevelActive;

        public int LevelId
        {
            get
            {
                return this._LevelId;
            }
            set
            {
                this._LevelId = value;
            }
        }

        public int LevelParentId
        {
            get
            {
                return this._LevelParentId;
            }
            set
            {
                this._LevelParentId = value;
            }
        }

        public string LevelAbbrv
        {
            get
            {
                return this._LevelAbbrv;
            }
            set
            {
                this._LevelAbbrv = value;
            }
        }

        public string LevelName
        {
            get
            {
                return this._LevelName;
            }
            set
            {
                this._LevelName = value;
            }
        }

        public byte LevelValue
        {
            get
            {
                return this._LevelValue;
            }
            set
            {
                this._LevelValue = value;
            }
        }

        public byte LevelActive
        {
            get
            {
                return this._LevelActive;
            }
            set
            {
                this._LevelActive = value;
            }
        }

        public bool LevelActiveBool
        {
            get
            {
                return (int)this._LevelActive != 0;
            }
            set
            {
                if (value)
                    this._LevelActive = (byte)1;
                else
                    this._LevelActive = (byte)0;
            }
        }

        public scLevels()
        {
            this._LevelId = 0;
            this._LevelParentId = 0;
            this._LevelAbbrv = "";
            this._LevelName = "";
            this._LevelValue = (byte)0;
            this._LevelActive = (byte)0;
        }

        public override string ToString()
        {
            return this._LevelAbbrv + " - " + this._LevelName;
        }
    }
}
