protected override void Store(IObjectContainerAdapter objectContainer) { var holder = new Holder(); holder._values = CreateValues(); holder._arrays = CreateArrays(); objectContainer.Store(holder); }
protected override void Store(IObjectContainerAdapter objectContainer) { HandlerUpdateTestCaseBase.Holder holder = new HandlerUpdateTestCaseBase.Holder(); holder._values = CreateValues(); holder._arrays = CreateArrays(); objectContainer.Store(holder); }
public object Apply(object container) { IObjectContainerAdapter adapter = ObjectContainerAdapterFactory.ForVersion(1, 1); adapter.ForContainer((IExtObjectContainer)((IObjectContainer)container)); adapter.Store(new MigrationHopsTestCase.Item(Sharpen.Runtime.Substring(Db4oFactory .Version(), 5))); return(null); }
protected override void Store(IObjectContainerAdapter objectContainer) { DeletionUponFormatMigrationTestCase.Item item1 = new DeletionUponFormatMigrationTestCase.Item (IdToBeDeleted, new DeletionUponFormatMigrationTestCase.ChildItem(ChildToBeDelete ), ItemsToKeep()); objectContainer.Store(item1, 10); DeletionUponFormatMigrationTestCase.Item item2 = new DeletionUponFormatMigrationTestCase.Item (IdToBeKept, new DeletionUponFormatMigrationTestCase.ChildItem(ChildToBeKept), new DeletionUponFormatMigrationTestCase.Item[] { item1 }); objectContainer.Store(item2, 10); }
protected override void Store(IObjectContainerAdapter objectContainer) { var item1 = new Item (IdToBeDeleted, new ChildItem(ChildToBeDelete ), ItemsToKeep()); objectContainer.Store(item1, 10); var item2 = new Item (IdToBeKept, new ChildItem(ChildToBeKept), new[] { item1 }); objectContainer.Store(item2, 10); }
protected override void Store(IObjectContainerAdapter objectContainer) { for (var i = 0; i < 10; i++) { var cls = new StClass (); var v = new ArrayList(10); v.Add(IntArrayData); v.Add(StringArrayData); cls.SetId(i); cls.SetVect(v); objectContainer.Store(cls); } }
protected override void Store(IObjectContainerAdapter objectContainer) { for (int i = 0; i < 10; i++) { FreespaceManagerMigrationTestCase.StClass cls = new FreespaceManagerMigrationTestCase.StClass (); ArrayList v = new ArrayList(10); v.Add(IntArrayData); v.Add(StringArrayData); cls.SetId(i); cls.SetVect(v); objectContainer.Store(cls); } }
protected override void Store(IObjectContainerAdapter objectContainer) { Item nextItem = null; for (var i = 9; i >= 0; i--) { var storedItem = new Item ("item" + i, nextItem); objectContainer.Store(storedItem); nextItem = storedItem; } objectContainer.Commit(); var item = QueryForItem(objectContainer, 0); for (var i = 0; i < 5; i++) { objectContainer.Delete(item); item = item._next; } objectContainer.Commit(); }
protected override void Store(IObjectContainerAdapter objectContainer) { IxFreespaceMigrationTestCase.Item nextItem = null; for (int i = 9; i >= 0; i--) { IxFreespaceMigrationTestCase.Item storedItem = new IxFreespaceMigrationTestCase.Item ("item" + i, nextItem); objectContainer.Store(storedItem); nextItem = storedItem; } objectContainer.Commit(); IxFreespaceMigrationTestCase.Item item = QueryForItem(objectContainer, 0); for (int i = 0; i < 5; i++) { objectContainer.Delete(item); item = item._next; } objectContainer.Commit(); }
private void CreateDatabase(string file) { if (!IsApplicableForDb4oVersion()) { return; } System.IO.Directory.CreateDirectory(DatabasePath); if (System.IO.File.Exists(file)) { File4.Delete(file); } IExtObjectContainer objectContainer = Db4oFactory.OpenFile(file).Ext(); IObjectContainerAdapter adapter = ObjectContainerAdapterFactory.ForVersion(Db4oMajorVersion (), Db4oMinorVersion()).ForContainer(objectContainer); try { Store(adapter); } finally { objectContainer.Close(); } }
protected override void Store(IObjectContainerAdapter objectContainer) { objectContainer.Store(CascadedDeleteFileFormatUpdateTestCase.ParentItem.NewTestInstance ()); }
protected abstract void Store(IObjectContainerAdapter objectContainer);
private IxFreespaceMigrationTestCase.Item QueryForItem(IObjectContainerAdapter objectContainer , int n) { return(QueryForItem(objectContainer.Query(), n)); }
protected override void Store(IObjectContainerAdapter objectContainer) { objectContainer.Store(ParentItem.NewTestInstance ()); }
protected override void Store(IObjectContainerAdapter objectContainer) { objectContainer.Store(new Item()); }
protected override void Store(IObjectContainerAdapter objectContainer) { objectContainer.Store(new CommitTimestampMigrationTestCase.Item()); }
private IxFreespaceMigrationTestCase.Item QueryForItem(IObjectContainerAdapter objectContainer , int n) { return QueryForItem(objectContainer.Query(), n); }
protected override void Store(IObjectContainerAdapter objectContainer) { objectContainer.Store(NewItem(1971, 5, 1)); }
private Item QueryForItem(IObjectContainerAdapter objectContainer , int n) { return(QueryForItem(objectContainer.Query(), n)); }
private Item QueryForItem(IObjectContainerAdapter objectContainer , int n) { return QueryForItem(objectContainer.Query(), n); }