Наследование: ICheckGridRowObject
Пример #1
0
        /// ------------------------------------------------------------------------------------
        /// <summary>
        ///
        /// </summary>
        /// ------------------------------------------------------------------------------------
        private void SetupTestList()
        {
            m_list     = new List <ICheckGridRowObject>();
            m_cgSorter = new CheckGridListSorter(m_list);

            DummyListItem item = new DummyListItem();

            item.StrProp  = "item1";
            item.IntProp  = 500;
            item.DateProp = new DateTime(2008, 1, 21);
            item.EnumProp = dummyEnum.One;
            m_list.Add(item);

            item          = new DummyListItem();
            item.StrProp  = "item3";
            item.IntProp  = 100;
            item.DateProp = new DateTime(2008, 1, 23);
            item.EnumProp = dummyEnum.Three;
            m_list.Add(item);

            item          = new DummyListItem();
            item.StrProp  = "item4";
            item.IntProp  = 200;
            item.DateProp = new DateTime(2008, 1, 24);
            item.EnumProp = dummyEnum.One;
            m_list.Add(item);

            item          = new DummyListItem();
            item.StrProp  = "item2";
            item.IntProp  = 800;
            item.DateProp = new DateTime(2008, 1, 24);
            item.EnumProp = dummyEnum.Two;
            m_list.Add(item);

            m_cgSorter.AddComparer("StrProp", StringComparer.Ordinal);
            m_cgSorter.AddComparer("IntProp", m_genericComparer);
            m_cgSorter.AddComparer("DateProp", m_genericComparer);
            m_cgSorter.AddComparer("EnumProp", new DummyEnumComparer());
        }
		/// ------------------------------------------------------------------------------------
		/// <summary>
		///
		/// </summary>
		/// ------------------------------------------------------------------------------------
		private void SetupTestList()
		{
			m_list = new List<ICheckGridRowObject>();
			m_cgSorter = new CheckGridListSorter(m_list);

			DummyListItem item = new DummyListItem();
			item.StrProp = "item1";
			item.IntProp = 500;
			item.DateProp = new DateTime(2008, 1, 21);
			item.EnumProp = dummyEnum.One;
			m_list.Add(item);

			item = new DummyListItem();
			item.StrProp = "item3";
			item.IntProp = 100;
			item.DateProp = new DateTime(2008, 1, 23);
			item.EnumProp = dummyEnum.Three;
			m_list.Add(item);

			item = new DummyListItem();
			item.StrProp = "item4";
			item.IntProp = 200;
			item.DateProp = new DateTime(2008, 1, 24);
			item.EnumProp = dummyEnum.One;
			m_list.Add(item);

			item = new DummyListItem();
			item.StrProp = "item2";
			item.IntProp = 800;
			item.DateProp = new DateTime(2008, 1, 24);
			item.EnumProp = dummyEnum.Two;
			m_list.Add(item);

			m_cgSorter.AddComparer("StrProp", StringComparer.Ordinal);
			m_cgSorter.AddComparer("IntProp", m_genericComparer);
			m_cgSorter.AddComparer("DateProp", m_genericComparer);
			m_cgSorter.AddComparer("EnumProp", new DummyEnumComparer());
		}