using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace ryCommon.Pram
{
    /// <summary>
    /// 控件信息
    /// </summary>
    public class Control_Info
    {
        /// <summary>
        /// id
        /// </summary>
        public string id = "";
        /// <summary>
        /// 控件对象
        /// </summary>
        public Control control;
        /// <summary>
        /// 控件值类型
        /// </summary>
        public CValueType value_type = CValueType.Default;
        /// <summary>
        /// 默认值
        /// </summary>
        public object defValue;
    }
    /// <summary>
    /// 值类型
    /// </summary>
    public enum CValueType
    {
        /// <summary>
        /// 默认
        /// </summary>
        Default,
        /// <summary>
        /// 取列表顺序值
        /// </summary>
        ItemIndex,
        /// <summary>
        /// 取当前选择的列表值
        /// </summary>
        ItemText,
        /// <summary>
        /// 取对象值
        /// </summary>
        ObjectItem
    }
    /// <summary>
    /// 保存的设置类型
    /// </summary>
    public enum SettingType
    {
        /// <summary>
        /// Ini
        /// </summary>
        Ini,
        /// <summary>
        /// XML
        /// </summary>
        XML
    }
    /// <summary>
    ///对象值
    /// </summary>
    public class ObjectItem
    {
        /// <summary>
        /// 显示的文本
        /// </summary>
        public string Text = "";
        /// <summary>
        /// 图片序号
        /// </summary>
        public int ImageIndex = -1;
        /// <summary>
        /// id
        /// </summary>
        public string Id = "";
        /// <summary>
        /// Tag值
        /// </summary>
        public object Tag = null;
        /// <summary>
        /// 显示文本值
        /// </summary>
        /// <returns></returns>
        public override string ToString()
        {
            return Text;
        }
    }
    /// <summary>
    /// 星期数据
    /// </summary>
    public class WeekInfo
    {
        /// <summary>
        /// 一周的开始时间
        /// </summary>
        public DateTime startDate;
        /// <summary>
        /// 一周的结束时间
        /// </summary>
        public DateTime endDate;
    }
}
