/// <exception cref="System.Exception"></exception> public virtual void TestTypedObjectIndex() { SlotDefragmentFixture.ForceIndex(SourceFile(), NewConfiguration()); Db4objects.Db4o.Defragment.Defragment.Defrag(NewDefragmentConfig(SourceFile(), BackupFile ())); IObjectContainer db = Db4oEmbedded.OpenFile(NewConfiguration(), SourceFile()); IQuery query = db.Query(); query.Constrain(typeof(SlotDefragmentFixture.Data)); query.Descend(SlotDefragmentFixture.TypedobjectFieldname).Descend(SlotDefragmentFixture .PrimitiveFieldname).Constrain(SlotDefragmentFixture.Value); IObjectSet result = query.Execute(); Assert.AreEqual(1, result.Count); db.Close(); }
/// <exception cref="System.Exception"></exception> public override void SetUp() { new Sharpen.IO.File(SourceFile()).Delete(); new Sharpen.IO.File(BackupFile()).Delete(); SlotDefragmentFixture.CreateFile(SourceFile(), NewConfiguration()); }
/// <exception cref="System.Exception"></exception> public virtual void TestWrapperIndex() { SlotDefragmentFixture.AssertIndex(SlotDefragmentFixture.WrapperFieldname, SourceFile (), FreshDb4oConfigurationProvider()); }
public Data(int id, SlotDefragmentFixture.Data next) { _id = id; _wrapper = id; _next = next; }