class RedisCluster::Future
Future
basically act the same way as Redis::Future with some modification
Attributes
asking[RW]
command[R]
slot[R]
url[RW]
Public Class Methods
new(slot, command, transformation)
click to toggle source
# File lib/redis_cluster/future.rb, line 12 def initialize(slot, command, transformation) @slot = slot @command = command @transformation = transformation @value = Redis::Future::FutureNotReady @asking = false end
Public Instance Methods
value()
click to toggle source
# File lib/redis_cluster/future.rb, line 20 def value raise @value if @value.is_a?(::RuntimeError) @value end
value=(value)
click to toggle source
# File lib/redis_cluster/future.rb, line 25 def value=(value) @value = @transformation.call(value) end