Class: RedisClient::BasicMiddleware

Inherits:
Object
  • Object
show all
Defined in:
lib/redis_client/middlewares.rb

Direct Known Subclasses

Middlewares

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ BasicMiddleware

Returns a new instance of BasicMiddleware.



7
8
9
# File 'lib/redis_client/middlewares.rb', line 7

def initialize(client)
  @client = client
end

Instance Attribute Details

#clientObject (readonly)

Returns the value of attribute client.



5
6
7
# File 'lib/redis_client/middlewares.rb', line 5

def client
  @client
end

Instance Method Details

#call(command, _config) {|command| ... } ⇒ Object Also known as: call_pipelined

Yields:

  • (command)


15
16
17
# File 'lib/redis_client/middlewares.rb', line 15

def call(command, _config)
  yield command
end

#connect(_config) ⇒ Object



11
12
13
# File 'lib/redis_client/middlewares.rb', line 11

def connect(_config)
  yield
end