Пример #1
0
        public void SaveObject(Object obj)
        {
            var key = new Keys("test", "1");

            using (var client=this.Factory.GetNativeClient())
            {
                var objectvalue = new Translator();
                client.LPush(key,objectvalue.ObjectToByteArray(obj));
            }
        }
Пример #2
0
        public object RetriveObject()
        {
            var key = new Keys("T.F.L", "MessageLog");

            using (var client = this.Factory.GetNativeClient())
            {
                var objectvalue = new Translator();
                var byteValue= client.RPop(key);
                return objectvalue.ByteArrayToObject(byteValue);
            }
        }