本文整理汇总了C#中Topics.Radical.ChangeTracking.ChangeTrackingService.Suspend方法的典型用法代码示例。如果您正苦于以下问题:C# ChangeTrackingService.Suspend方法的具体用法?C# ChangeTrackingService.Suspend怎么用?C# ChangeTrackingService.Suspend使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Topics.Radical.ChangeTracking.ChangeTrackingService
的用法示例。
在下文中一共展示了ChangeTrackingService.Suspend方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: after_resume_isSuspended_is_false
public void after_resume_isSuspended_is_false()
{
ChangeTrackingService svc = new ChangeTrackingService();
svc.Suspend();
svc.Resume();
Assert.IsFalse( svc.IsSuspended );
}
示例2: after_resume_service_restart_tracking_changes
public void after_resume_service_restart_tracking_changes()
{
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc, false );
svc.Suspend();
svc.Resume();
p.Name = "Mauro";
Assert.IsTrue( svc.IsChanged );
}
示例3: after_suspend_isSuspended_is_true
public void after_suspend_isSuspended_is_true()
{
ChangeTrackingService svc = new ChangeTrackingService();
svc.Suspend();
Assert.IsTrue( svc.IsSuspended );
}
示例4: after_suspend_cannot_call_UnregisterTransient
public void after_suspend_cannot_call_UnregisterTransient()
{
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc );
svc.Suspend();
svc.UnregisterTransient( p );
}
示例5: after_suspend_cannot_call_RejectChanges
public void after_suspend_cannot_call_RejectChanges()
{
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc );
p.Name = "Mauro";
svc.Suspend();
svc.RejectChanges();
}
示例6: after_suspend_cannot_call_RegisterTransient_with_explicit_autoRemove_false
public void after_suspend_cannot_call_RegisterTransient_with_explicit_autoRemove_false()
{
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc, false );
svc.Suspend();
svc.RegisterTransient( p, false );
}
示例7: after_suspend_no_more_changes_can_be_added
public void after_suspend_no_more_changes_can_be_added()
{
RejectCallback<String> cb = cv => { };
Object fakeOwner = new Object();
String change = String.Empty;
PropertyValueChange<String> stub = new PropertyValueChange<string>( fakeOwner, "property-name", change, cb );
ChangeTrackingService svc = new ChangeTrackingService();
svc.Suspend();
svc.Add( stub, AddChangeBehavior.RedoRequest );
}
示例8: using
public void entityMemento_ctor_requesting_transient_registration_using_base_iMemento_to_suspended_memento_do_not_register_entity_as_transient()
{
EntityTrackingStates expected = EntityTrackingStates.None;
using( var svc = new ChangeTrackingService() )
{
svc.Suspend();
var target = this.CreateMock( true );
( ( IMemento )target ).Memento = svc;
EntityTrackingStates actual = svc.GetEntityState( target );
actual.Should().Be.EqualTo( expected );
}
}