private void BindActivatableToActivator(ObjectEventArgs oea) { object obj = oea.Object; if (obj is IActivatable) { Db4objects.Db4o.Internal.Transaction transaction = (Db4objects.Db4o.Internal.Transaction )oea.Transaction(); ObjectReference objectReference = transaction.ReferenceForObject(obj); Bind(obj, ActivatorForObject(transaction, objectReference)); } }
private void BindActivatableToActivator(ObjectEventArgs oea) { var obj = oea.Object; if (obj is IActivatable) { var transaction = (Transaction ) oea.Transaction(); var objectReference = transaction.ReferenceForObject(obj); Bind(obj, ActivatorForObject(transaction, objectReference)); } }
private static void activationTraker(object sender, ObjectEventArgs args) { activationCount++; }
private void OnActivated(object sender, ObjectEventArgs args) { WeSayDataObject o = args.Object as WeSayDataObject; if (o == null) { return; } //activate all the children _container.Activate(o, int.MaxValue); o.FinishActivation(); _activationCount++; }