Module: Valkey::PubSubCallback
- Included in:
- Valkey
- Defined in:
- lib/valkey/pubsub_callback.rb
Instance Method Summary collapse
- #pubsub_callback(_client_ptr, kind, msg_ptr, msg_len, chan_ptr, chan_len, pat_ptr, pat_len) ⇒ Object
Instance Method Details
#pubsub_callback(_client_ptr, kind, msg_ptr, msg_len, chan_ptr, chan_len, pat_ptr, pat_len) ⇒ Object
5 6 7 8 |
# File 'lib/valkey/pubsub_callback.rb', line 5 def pubsub_callback(_client_ptr, kind, msg_ptr, msg_len, chan_ptr, chan_len, pat_ptr, pat_len) puts "PubSub received kind=#{kind}, message=#{msg_ptr.read_string(msg_len)}"\ ", channel=#{chan_ptr.read_string(chan_len)}, pattern=#{pat_ptr.read_string(pat_len)}" end |