module Paho module Processor class Base TOPIC = '#' def initialize puts "Starting #{self.class.name} processor" end def topic self.class::TOPIC end def __get(t, message) log "Listening on #{topic} got [#{t}] #{message.toString}" get(t, message.toString) end alias_method :messageArrived, :__get private def log(m) puts "[Paho][Processor][#{self.class.name}]: #{m}" end end end end