using System.Collections.ObjectModel;

namespace TriStateModeInDeep
{
	public class SampleViewModel : ObservableCollection<SampleBusinessObject>
	{
		public SampleViewModel()
		{
			SampleBusinessObject item;
			item = new SampleBusinessObject("Data 1") { IsChecked = true };
			item.Items.Add(new SampleBusinessObject("Data 1.1"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 1.1.1"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 1.1.2"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 1.1.3"));
			item.Items.Add(new SampleBusinessObject("Data 1.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 1.2.1"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 1.2.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 1.2.3"));
			item.Items.Add(new SampleBusinessObject("Data 1.3"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 1.3.1"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 1.3.2"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 1.3.3"));
			this.Add(item);

			item = new SampleBusinessObject("Data 2");
			item.Items.Add(new SampleBusinessObject("Data 2.1") { IsChecked = true });
			item.Items[0].Items.Add(new SampleBusinessObject("Item 2.1.1"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 2.1.2"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 2.1.3"));
			item.Items.Add(new SampleBusinessObject("Data 2.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 2.2.1"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 2.2.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 2.2.3"));
			item.Items.Add(new SampleBusinessObject("Data 2.3"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 2.3.1"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 2.3.2"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 2.3.3"));
			this.Add(item);

			item = new SampleBusinessObject("Data 3");
			item.Items.Add(new SampleBusinessObject("Data 3.1"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 3.1.1") { IsChecked = true });
			item.Items[0].Items.Add(new SampleBusinessObject("Item 3.1.2"));
			item.Items[0].Items.Add(new SampleBusinessObject("Item 3.1.3"));
			item.Items.Add(new SampleBusinessObject("Data 3.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 3.2.1"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 3.2.2"));
			item.Items[1].Items.Add(new SampleBusinessObject("Item 3.2.3"));
			item.Items.Add(new SampleBusinessObject("Data 3.3"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 3.3.1"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 3.3.2"));
			item.Items[2].Items.Add(new SampleBusinessObject("Item 3.3.3"));
			this.Add(item);
		}
	}
}