Decrement the value of an item in the cache.

@param string $key
@param mixed  $value

@return int|bool
339393
public function decrement($key, $value = 1)
    {
        $decrement = 0;
        if ($integer = $this->get($key)) {
            $decrement = $integer - $value;
            if ($decrement <= 0) {
                $decrement = 0;
            }
            $this->put($key, $decrement, 0);

            return $decrement;
        }

        $this->put($key, $decrement, 0);

        return $decrement;
    }
243
public function decrement($id, $offset = 1)
	{
		$success = FALSE;
		$value = wincache_ucache_dec($id, $offset, $success);

		return ($success === TRUE) ? $value : FALSE;
	}
774212
public function increaseBy($key, $value) {
		$valueOld = $this->get($key, 0);
		if (is_numeric($value) && is_numeric($valueOld)) {
			$this->add($key, $value + $valueOld);
			return $value + $valueOld;
		}
	}
235021
protected function incrementOrDecrement($key, $value, Closure $callback)
    {
        return $this->connection->transaction(function () use ($key, $value, $callback) {
            $prefixed = $this->prefix.$key;

            $cache = $this->table()->where('key', $prefixed)
                        ->lockForUpdate()->first();

            // If there is no value in the cache, we will return false here. Otherwise the
            // value will be decrypted and we will proceed with this function to either
            // increment or decrement this value based on the given action callbacks.
            if (is_null($cache)) {
                return false;
            }

            $cache = is_array($cache) ? (object) $cache : $cache;

            $current = $this->unserialize($cache->value);

            // Here we'll call this callback function that was given to the function which
            // is used to either increment or decrement the function. We use a callback
            // so we do not have to recreate all this logic in each of the functions.
            $new = $callback((int) $current, $value);

            if (! is_numeric($current)) {
                return false;
            }

            // Here we will update the values in the table. We will also encrypt the value
            // since database cache values are encrypted by default with secure storage
            // that can't be easily read. We will return the new value after storing.
            $this->table()->where('key', $prefixed)->update([
                'value' => $this->serialize($new),
            ]);

            return $new;
        });
    }
939288
public function decrement($key, $value = 1)
    {
        $this->store->decrement($this->taggedItemKey($key), $value);
    }
1181340
public function decrement($key, $val = 1)
    {
        return $this->hash($key)->decrBy($key, abs(intval($val)));
    }
772298
def decrement(self, key, value=1):
        
        return self._memcache.decr(self._prefix + key, value)
708999
public function decrement($key, $value, \DatePeriod $period = null)
    {
        if (is_null($period)) {
            $this->repository->decrement($key, $value);
        } else {
            $this->decrementForPeriod($key, $value, $period);
        }
    }
1211480
public function increment($key, $value = 1)
    {
        return $this->connection()->incrby($this->prefix.$key, $value);
    }
1267441
public function decrement($key, $offset = 1)
    {
        return $this->memcached ? $this->memcached->decrement($key, $offset) : false;
    }
1253369
public function increment($key, $value = 1)
    {
        $cached = $this->get($key);

        if (is_numeric($cached)) {
            $cached += $value;
            $this->set($key, $cached);
			return $cached;
		}

        return false;
    }
1262582
public function set($key, $value) {
		
		$previous = $this->get($key);
		
		parent::set($key, $value);
		
		return $previous;
	}
978286
public function decrementMemberCount($value){
        if(!is_integer($value)){
            return $this;
        }
        $new_value = $this->count_members - $value;
        if($new_value < 0){
            $new_value = 0;
        }
        $this->count_members = $new_value;
        return $this;
    }
1215685
public function decrement($key, $value = 1)
    {
        $this->store->decrement($this->itemKey($key), $value);
    }
299374
public function increment($key, $value = 1)
    {
        $this->store->increment($this->taggedItemKey($key), $value);
    }
243699
public function set($key, $value) {

        $keys = \explode('/',$key);

        if (\count($keys)>5) return false;

        switch (\count($keys)){

          case 1:
            $this->registry[$keys[0]] = $value;
            break;

          case 2:
            $this->registry[$keys[0]][$keys[1]] = $value;
            break;

          case 3:
            $this->registry[$keys[0]][$keys[1]][$keys[2]] = $value;
            break;

          case 4:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]] = $value;
            break;

          case 5:
            $this->registry[$keys[0]][$keys[1]][$keys[2]][$keys[3]][$keys[4]] = $value;
            break;
        }

        return $this;
    }
1253801
public function increment($key, $value = 1)
    {
        return $this->redisServer->getHashClient($key)->incrBy($key, $value);
    }