public EntityData(Type t) { this.Type = t; this.TypeHashID = EncryptionUtility.MD5_16(t.FullName); ICacheService service = ServiceLocator.GetService <ICacheService>(); //对realTimeCacheHelper进行初始化 if (!service.EnableDistributedCache) { RealTimeCacheHelper helper = this.ParseCacheTimelinessHelper(t); this.realTimeCacheHelper = helper; service.SetAsync(RealTimeCacheHelper.GetCacheKeyOfTimelinessHelper(this.TypeHashID), helper, CachingExpirationType.Invariable).Wait(); } }