/*
* call-seq:
* mq.receive([buffer, [timeout]]) => [ message, priority ]
*
* Takes the highest priority message off the queue and returns
* an array containing the message as a String and the Integer
* priority of the message.
*
* If the optional +buffer+ is present, then it must be a String
* which will receive the data.
*
* If the optional +timeout+ is present, then it may be a Float
* or Integer specifying the timeout in seconds. Errno::ETIMEDOUT
* will be raised if +timeout+ has elapsed and there are no messages
* in the queue.
*
* On some older systems, the +timeout+ argument is not currently
* supported and may raise NotImplementedError if +timeout+ is used.
*/
static VALUE receive(int argc, VALUE *argv, VALUE self)
{
return _receive(PMQ_WANTARRAY, argc, argv, self);
}