private static void SetDataEngineCommands(InstanceCreatedEventArgs e) { var commands = e.Database.Engines.DataEngine.Commands; commands.GetItemPrototype = new GetItemCommandPrototype(e.Database); commands.GetVersionsPrototype = new GetVersionsCommandPrototype(e.Database); }
private void InstanceCreated(object sender, InstanceCreatedEventArgs e) { var created = (HookTestTable)e.Instance; Assert.AreEqual(InsertedTest, created.Text); created.Text = ReplacedText; }
private static void SetDataEngineCommands(InstanceCreatedEventArgs e) { var commands = e.Database.Engines.DataEngine.Commands; commands.AddFromTemplatePrototype = new AddFromTemplateCommandPrototype(e.Database); commands.AddVersionPrototype = new AddVersionCommandProtoype(e.Database); commands.BlobStreamExistsPrototype = new BlobStreamExistsCommandPrototype(e.Database); commands.CopyItemPrototype = new CopyItemCommandPrototype(e.Database); commands.CreateItemPrototype = new CreateItemCommandPrototype(e.Database); commands.DeletePrototype = new DeleteItemCommandPrototype(e.Database); commands.GetBlobStreamPrototype = new GetBlobStreamCommandPrototype(e.Database); commands.GetChildrenPrototype = new GetChildrenCommandPrototype(e.Database); commands.GetItemPrototype = new GetItemCommandPrototype(e.Database); commands.GetParentPrototype = new GetParentCommandPrototype(e.Database); commands.GetRootItemPrototype = new GetRootItemCommandPrototype(e.Database); commands.GetVersionsPrototype = new GetVersionsCommandPrototype(e.Database); commands.HasChildrenPrototype = new HasChildrenCommandPrototype(e.Database); commands.MoveItemPrototype = new MoveItemCommandPrototype(e.Database); commands.RemoveDataPrototype = new RemoveDataCommandPrototype(e.Database); commands.RemoveVersionPrototype = new RemoveVersionCommandPrototype(e.Database); commands.ResolvePathPrototype = new ResolvePathCommandPrototype(e.Database); commands.SaveItemPrototype = new SaveItemCommandPrototype(e.Database); commands.SetBlobStreamPrototype = new SetBlobStreamCommandPrototype(e.Database); }
private static void DatabaseInstanceCreated(object sender, InstanceCreatedEventArgs e) { SetDataEngineCommands(e); }