public static void SetDeviceState(string token, string state)
 {
     if (DeviceStateCache.ExistTokenByKey(token))
     {
         DeviceStateCache.UpdateTokenByKey(token, state);
     }
     else
     {
         DeviceStateCache.AddToken(token, state);
     }
 }
        public static void SetDeviceState(string storeId, string deviceId, string state)
        {
            string key = storeId + "_" + deviceId;

            if (DeviceStateCache.ExistTokenByKey(key))
            {
                DeviceStateCache.UpdateTokenByKey(key, state);
            }
            else
            {
                DeviceStateCache.AddToken(key, state);
            }
        }