Пример #1
0
        static void Main(string[] args)
        {
            ICacheStore cacheStore = new CacheStore(new System.Collections.Generic.Dictionary <ConfigurationType, object>()
            {
                [ConfigurationType.AppKey] = "APP"
            });

            cacheStore.Init("127.0.0.1:6379");

            AddValues(cacheStore);

            var TestValue  = cacheStore.Get <A>("TEST");
            var TestValues = cacheStore.GetAll <A>();
        }
Пример #2
0
        public JsonResult GetAll()
        {
            List <Tutor> tutors = CacheStore.GetAll <Tutor>();

            return(Json(tutors, JsonRequestBehavior.AllowGet));
        }