Prado\Caching\TCache::add PHP Method

add() public method

Nothing will be done if the cache already contains the key or if value is empty.
public add ( $id, $value, $expire, $dependency = null ) : boolean
return boolean true if the value is successfully stored into cache, false otherwise
    public function add($id, $value, $expire = 0, $dependency = null)
    {
        if (empty($value) && $expire === 0) {
            return false;
        }
        $data = array($value, $dependency);
        return $this->addValue($this->generateUniqueKey($id), $data, $expire);
    }