本文整理汇总了C#中Topics.Radical.ChangeTracking.ChangeTrackingService.UnregisterTransient方法的典型用法代码示例。如果您正苦于以下问题:C# ChangeTrackingService.UnregisterTransient方法的具体用法?C# ChangeTrackingService.UnregisterTransient怎么用?C# ChangeTrackingService.UnregisterTransient使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Topics.Radical.ChangeTracking.ChangeTrackingService
的用法示例。
在下文中一共展示了ChangeTrackingService.UnregisterTransient方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: 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 );
}
示例2: service_on_unregisterTransient_raise_trackingServiceStateChanged_event
public void service_on_unregisterTransient_raise_trackingServiceStateChanged_event()
{
Int32 expected = 1;
Int32 actual = 0;
ChangeTrackingService svc = new ChangeTrackingService();
Person p = new Person( svc );
svc.TrackingServiceStateChanged += ( sender, args ) => { actual++; };
svc.UnregisterTransient( p );
Assert.AreEqual<Int32>( expected, actual );
}
示例3: service_unregisterTransient_valid_reference
public void service_unregisterTransient_valid_reference()
{
ChangeTrackingService svc = new ChangeTrackingService();
EntityTrackingStates expected = EntityTrackingStates.None;
Person p = new Person( svc, true );
svc.UnregisterTransient( p );
EntityTrackingStates actual = svc.GetEntityState( p );
Assert.AreEqual<EntityTrackingStates>( expected, actual );
}
示例4: service_unregisterTransient_reference_not_registered_as_transient
public void service_unregisterTransient_reference_not_registered_as_transient()
{
Person p = new Person( null );
ChangeTrackingService svc = new ChangeTrackingService();
svc.UnregisterTransient( p );
}
示例5: service_unregisterTransient_null_reference_argumentNullException
public void service_unregisterTransient_null_reference_argumentNullException()
{
ChangeTrackingService svc = new ChangeTrackingService();
svc.UnregisterTransient( null );
}