jjzjj

ITransaction

全部标签

c# 使用 Moq 模拟具体类的接口(interface)成员

我有一个接口(interface)ITransaction如下:publicinterfaceITransaction{DateTimeEntryTime{get;}DateTimeExitTime{get;}}我有一个派生类PaymentTransaction,如下所示:publicclassPaymentTransaction:ITransaction{publicvirtualDateTimeLastPaymentTime{get{returnDateTime.Now;}}#regionITransactionMemberspublicDateTimeEntryTime{get{

.net - 'StackExchange.Redis.ITransaction' 不包含 'StringSetAsync' 的定义

我在Redis上使用事务并使用StackExchange.Redis提供程序。我有一大批用于事务的StringSetAsync操作。我在使用StringSetAsync时遇到错误:RuntimeBinderException被捕获“StackExchange.Redis.ITransaction”不包含“StringSetAsync”的定义堆栈跟踪:在CallSite.Target(闭包,CallSite,ITransaction,字符串,对象)在Repository.RedisDatabaseContextBase.SetRecord(IBasicRedisEntityredisEn