vendor/bundle/ruby/1.8/gems/activemessaging-0.9.0/lib/activemessaging/adapters/wmq.rb
def retrieve_message(q)
          WMQ::QueueManager.connect(@connection_options) do |qmgr|
            qmgr.open_queue(:q_name => q.name, :mode => :input) do |queue|

              get_options = q.get_options.dup
              wmq_message = WMQ::Message.new
              
              if queue.get(get_options.merge(:message => wmq_message))
                return Message.new(wmq_message, q.name)
              else 
                return nil
              end
            end
          end
        end
# Retrieve the first available message from the specicied queue
# Return nil if queue is empty
Retrieve the first available message from the specicied queue
Return nil if queue is empty
Retrieve the first available message from the specicied queue Return nil if queue is empty
def retrieve_message(q)
          WMQ::QueueManager.connect(@connection_options) do |qmgr|
            qmgr.open_queue(:q_name => q.name, :mode => :input) do |queue|
              get_options = q.get_options.dup
              wmq_message = WMQ::Message.new
              if queue.get(get_options.merge(:message => wmq_message))
                return Message.new(wmq_message, q.name)
              else 
                return nil
              end
            end
          end
        end
def retrieve_message ( q ) WMQ :: QueueManager . connect ( @connection_options ) do | qmgr | qmgr . open_queue ( :q_name => q . name , :mode => :input ) do | queue | get_options = q . get_options . dup wmq_message = WMQ :: Message . new if queue . get ( get_options . merge ( :message => wmq_message ) ) return Message . new ( wmq_message , q . name ) else return nil end end end end
Retrieve the first available message from the specicied queue
Return nil if queue is empty
Retrieve the first available message from the specicied queue Return nil if queue is empty
q