예제 #1
0
			public void Run()
			{
				for (int i = 0; i < PerformanceTestCase.ListHolderCount; i++)
				{
					SimpleListHolder listHolder = new SimpleListHolder("CreatedHolder");
					for (int j = 0; j < PerformanceTestCase.ObjectCount; j++)
					{
						SimpleItem child = new SimpleItem("CreatedChild");
						SimpleItem parent = new SimpleItem(listHolder, child, "CreatedParent");
						this._enclosing.A().Provider().StoreNew(parent);
						listHolder.Add(parent);
					}
					this._enclosing.A().Provider().StoreNew(listHolder);
					this._enclosing.A().Provider().Commit();
				}
				this._enclosing.A().Provider().Commit();
			}
예제 #2
0
		public virtual SimpleListHolder CreateList()
		{
			// list : {foo, bar, baz, foobar}
			//
			// baz -----+
			//          |
			//         bar --> foo
			//                  ^
			//                  |
			// foobar ----------+
			SimpleListHolder listHolder = new SimpleListHolder("root");
			SimpleItem foo = new SimpleItem(listHolder, "foo");
			SimpleItem bar = new SimpleItem(listHolder, foo, "bar");
			listHolder.Add(foo);
			listHolder.Add(bar);
			listHolder.Add(new SimpleItem(listHolder, bar, "baz"));
			listHolder.Add(new SimpleItem(listHolder, foo, "foobar"));
			return listHolder;
		}