Method: Dalli::Client#replace

Defined in:
lib/dalli/client.rb

#replace(key, value, ttl = nil, req_options = nil) ⇒ Object

Conditionally add a key/value pair, only if the key already exists on the server. Returns truthy if the operation succeeded.



221
222
223
# File 'lib/dalli/client.rb', line 221

def replace(key, value, ttl = nil, req_options = nil)
  replace_cas(key, value, 0, ttl, req_options)
end