NAME
Messaging::Message::Queue::NULL - abstraction of a null message queue
SYNOPSIS
use Messaging::Message;
use Messaging::Message::Queue::NULL;
# create a message queue
$mq = Messaging::Message::Queue::NULL->new();
# add a message to the queue
$msg = Messaging::Message->new(body => "hello world");
$mq->add_message($msg);
DESCRIPTION
This module provides an abstraction of a message queue working a bit like /dev/null
: it can be written to but it always appears empty.
METHODS
In addition to the standard Directory::Queue methods, the following methods are available:
- new(OPTIONS)
-
return a new Messaging::Message::Queue::NULL object (class method)
- add_message(MESSAGE)
-
add the given message (a Messaging::Message object) to the queue, this does nothing
- get_message(ELEMENT)
-
get the message from the given element, this generates an error
SEE ALSO
Directory::Queue, Messaging::Message, Messaging::Message::Queue.
AUTHOR
Lionel Cons http://cern.ch/lionel.cons
Copyright (C) CERN 2011-2021