english/libraries/joomla/cache/storage/memcache.php
/**
	 * Store the data to memcache by id and group
	 *
	 * @param   string  $id     The cache data id
	 * @param   string  $group  The cache data group
	 * @param   string  $data   The data to store in cache
	 *
	 * @return  boolean  True on success, false otherwise
	 *
	 * @since   11.1
	 */
Store the data to memcache by id and group
@param   string  $id     The cache data id
@param   string  $group  The cache data group
@param   string  $data   The data to store in cache

@return  boolean  True on success, false otherwise


Store the data to memcache by id and group @param string $id The cache data id @param string $group The cache data group @param string $data The data to store in cache @return boolean True on success false otherwise
public function store($id, $group, $data)
	{
		$cache_id = $this->_getCacheId($id, $group);
		if (!$this->lockindex()) {
			return false;
		}
		$index = self::$_db->get($this->_hash.'-index');
		if ($index === false) {
			$index = array();
		}
		$tmparr = new stdClass;
		$tmparr->name = $cache_id;
		$tmparr->size = strlen($data);
		$index[] = $tmparr;
		self::$_db->replace($this->_hash.'-index', $index , 0, 0);
		$this->unlockindex();
		if (!self::$_db->replace($cache_id, $data, $this->_compress, $this->_lifetime)) {
			self::$_db->set($cache_id, $data, $this->_compress, $this->_lifetime);
		}
		return true;
	}
public function store ( $ id , $ group , $ data ) { $ cache_id = $ this -> _getCacheId ( $ id , $ group ) ; if ( ! $ this -> lockindex ( ) ) { return false ; } $ index = self :: $ _db -> get ( $ this -> _hash . '-index' ) ; if ( $ index === false ) { $ index = array ( ) ; } $ tmparr = new stdClass ; $ tmparr -> name = $ cache_id ; $ tmparr -> size = strlen ( $ data ) ; $ index [ ] = $ tmparr ; self :: $ _db -> replace ( $ this -> _hash . '-index' , $ index , 0 , 0 ) ; $ this -> unlockindex ( ) ; if ( ! self :: $ _db -> replace ( $ cache_id , $ data , $ this -> _compress , $ this -> _lifetime ) ) { self :: $ _db -> set ( $ cache_id , $ data , $ this -> _compress , $ this -> _lifetime ) ; } return true ; }
Store the data to memcache by id and group
 @param   string  $id     The cache data id
 @param   string  $group  The cache data group
 @param   string  $data   The data to store in cache
Store the data to memcache by id and group @param string $id The cache data id @param string $group The cache data group @param string $data The data to store in cache
// prevent double writes, write only if it doesn't exist else replace